From patchwork Sat Mar 28 02:02:54 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Chen Gang X-Patchwork-Id: 455610 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 338731400B6 for ; Sat, 28 Mar 2015 13:03:11 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=pass reason="1024-bit key; unprotected key" header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=Ct+EI91S; dkim-adsp=none (unprotected policy); dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :message-id:date:from:mime-version:to:cc:subject:content-type :content-transfer-encoding; q=dns; s=default; b=PC7RXkqPsLSmKuMZ cAb24g+/MB4pyFMTO/pWX4VhCwXEez4eYIK62q2fVYbyflVIN3zOWam/cm5f1m7p W9GIv1j4Lb1ZBWqhjII/D4xgb+N/OvIEtOIvi4oEumwkTZzOaaZpQCRsSfjNAQFz YsQv7OmtXIgix0gwVAFQw9Pr1jg= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :message-id:date:from:mime-version:to:cc:subject:content-type :content-transfer-encoding; s=default; bh=qZxfheGFeA8CBUWQyRSJo5 tde+M=; b=Ct+EI91SyHUP+LD7Iz2tjATyFSSQBgW/FlLSWttwPzcOnypanIV8yw 0jJx2b+LTU0KEuMCcRuFrfHqIkdDTg8yfmHeSwYWiQn6qoMgkYAaUs2JMd2igD2u DKiTkALCrLa7LPlQJXx+o91Inf2bH73/GcAZevPKwGbagvOFC8vwY= Received: (qmail 94933 invoked by alias); 28 Mar 2015 02:03:03 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 94916 invoked by uid 89); 28 Mar 2015 02:03:03 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: Yes, score=5.7 required=5.0 tests=AWL, BAYES_00, FREEMAIL_ENVFROM_END_DIGIT, FREEMAIL_FROM, KAM_FROM_URIBL_PCCC, RCVD_IN_DNSWL_NONE, RCVD_IN_JMF_BL, SPF_PASS, T_RP_MATCHES_RCVD autolearn=no version=3.3.2 X-HELO: BLU004-OMC2S36.hotmail.com Received: from blu004-omc2s36.hotmail.com (HELO BLU004-OMC2S36.hotmail.com) (65.55.111.111) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA256 encrypted) ESMTPS; Sat, 28 Mar 2015 02:03:01 +0000 Received: from BLU436-SMTP150 ([65.55.111.72]) by BLU004-OMC2S36.hotmail.com over TLS secured channel with Microsoft SMTPSVC(7.5.7601.22751); Fri, 27 Mar 2015 19:02:59 -0700 X-TMN: [rfhwGs9XPe9Ao4yPyD5hRFb1YQuUW+xW] Message-ID: Date: Sat, 28 Mar 2015 10:02:54 +0800 From: Chen Gang User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: Bernd Schmidt , Jeff Law CC: gcc-patches List Subject: [PATCH] gcc/config/c6x/c6x.h: Handle default case for switch statement in TARGET_CPU_CPP_BUILTINS(). The related warning: g++ -c -DIN_GCC_FRONTEND -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -fno-common -DHAVE_CONFIG_H -I. -Ic-family -I../../gcc-c6x/gcc -I../../gcc-c6x/gcc/c-family -I../../gcc-c6x/gcc/../include -I../../gcc-c6x/gcc/../libcpp/include -I../../gcc-c6x/gcc/../libdecnumber -I../../gcc-c6x/gcc/../libdecnumber/dpd -I../libdecnumber -I../../gcc-c6x/gcc/../libbacktrace -o c-family/c-cppbuiltin.o -MT c-family/c-cppbuiltin.o -MMD -MP -MF c-family/.deps/c-cppbuiltin.TPo ../../gcc-c6x/gcc/c-family/c-cppbuiltin.c In file included from ./tm.h:16:0, from ../../gcc-c6x/gcc/c-family/c-cppbuiltin.c:23: ../../gcc-c6x/gcc/c-family/c-cppbuiltin.c: In function ‘void c_cpp_builtins(cpp_reader*)’: ../../gcc-c6x/gcc/config/c6x/c6x.h:85:14: warning: enumeration value ‘unk_isa’ not handled in switch [-Wswitch] switch (c6x_arch) \ ^../../gcc-c6x/gcc/c-family/c-cppbuiltin.c:1243:3: note: in expansion of macro ‘TARGET_CPU_CPP_BUILTINS’ TARGET_CPU_CPP_BUILTINS (); ^ 2015-03-28 Chen Gang * config/c6x/c6x.h (TARGET_CPU_CPP_BUILTINS): Handle default case for switch statement. --- gcc/config/c6x/c6x.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/gcc/config/c6x/c6x.h b/gcc/config/c6x/c6x.h index 58a7ac6..b4810be 100644 --- a/gcc/config/c6x/c6x.h +++ b/gcc/config/c6x/c6x.h @@ -109,6 +109,9 @@ extern c6x_cpu_t c6x_arch; builtin_define ("_TMS320C6400_PLUS"); \ builtin_define ("_TMS320C6400"); \ break; \ + \ + default: \ + break; \ } \ } while (0)