From patchwork Mon Dec 14 09:54:49 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Stefan Weil X-Patchwork-Id: 41077 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id B8947B6EF4 for ; Mon, 14 Dec 2009 20:58:06 +1100 (EST) Received: from localhost ([127.0.0.1]:34214 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NK7gp-0004kp-4v for incoming@patchwork.ozlabs.org; Mon, 14 Dec 2009 04:58:03 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NK7dt-0003P5-Ca for qemu-devel@nongnu.org; Mon, 14 Dec 2009 04:55:01 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NK7do-0003Lj-GW for qemu-devel@nongnu.org; Mon, 14 Dec 2009 04:55:00 -0500 Received: from [199.232.76.173] (port=45448 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NK7do-0003Lf-AJ for qemu-devel@nongnu.org; Mon, 14 Dec 2009 04:54:56 -0500 Received: from moutng.kundenserver.de ([212.227.126.186]:49831) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NK7dn-0001XL-QQ for qemu-devel@nongnu.org; Mon, 14 Dec 2009 04:54:56 -0500 Received: from flocke.weilnetz.de (p54ADF777.dip.t-dialin.net [84.173.247.119]) by mrelayeu.kundenserver.de (node=mreu1) with ESMTP (Nemesis) id 0MgaVX-1Nepgq31ct-00O7wc; Mon, 14 Dec 2009 10:54:52 +0100 Received: from stefan by flocke.weilnetz.de with local (Exim 4.69) (envelope-from ) id 1NK7di-00046z-Qz; Mon, 14 Dec 2009 10:54:50 +0100 From: Stefan Weil To: Richard Henderson , Aurelien Jarno , QEMU Developers Date: Mon, 14 Dec 2009 10:54:49 +0100 Message-Id: <1260784489-15773-1-git-send-email-weil@mail.berlios.de> X-Mailer: git-send-email 1.6.5 MIME-Version: 1.0 X-Provags-ID: V01U2FsdGVkX18rWMiepr01Yx7oULFqbgJX4ajrIYyAOjVUK4Y 8IKVv6mu3xgHHmUR61C5HACgyvpmvoDyGn/kVeZ9uz4VffPMT+ vQgFDHmSpMhGoff2huh6DE3Ra1aMVNMRflGEyUlN6FCf0AOLsD yZg== X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Cc: Subject: [Qemu-devel] [PATCH] target-alpha: Fix compiler warning for gcc-4.3 (and older) X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org "Old" compilers obviously are not able to recognise that all cases are handled here: qemu/target-alpha/helper.c:70: error: ‘round_mode’ may be used uninitialized in this function A small modification helps the compiler to do its jobs. gcc-4.4 does not need this, but is still not standard on all platforms. Signed-off-by: Stefan Weil Acked-by: Laurent Desnogues --- target-alpha/helper.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/target-alpha/helper.c b/target-alpha/helper.c index a658f97..be7d37b 100644 --- a/target-alpha/helper.c +++ b/target-alpha/helper.c @@ -95,6 +95,7 @@ void cpu_alpha_store_fpcr (CPUState *env, uint64_t val) round_mode = float_round_nearest_even; break; case 3: + default: /* this avoids a gcc (< 4.4) warning */ round_mode = float_round_up; break; }