diff mbox

[bfin] handle BFIN_CPU_UNKNOWN in TARGET_CPU_CPP_BUILTINS

Message ID CAC1BbcSviH0u38QbDzvnzq+S14PvJwYRt+39cfsLoffWoSeN8Q@mail.gmail.com
State New
Headers show

Commit Message

Bernhard Reutner-Fischer April 1, 2015, 9:34 p.m. UTC
Hi,

gcc/c-family/c-cppbuiltin.c
In file included from ./tm.h:21:0,
                 from
../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:23:
../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:
In function ‘void c_cpp_builtins(cpp_reader*)’:
../../../../../../home/me/src/gcc-5.0.mine/gcc/config/bfin/bfin.h:43:14:
error: enumeration value ‘BFIN_CPU_UNKNOWN’ not handled in switch
[-Werror=switch]
       switch (bfin_cpu_type)   \
              ^
../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:1243:3:
note: in expansion of macro ‘TARGET_CPU_CPP_BUILTINS’
   TARGET_CPU_CPP_BUILTINS ();
   ^
cc1plus: all warnings being treated as errors
make[2]: *** [c-family/c-cppbuiltin.o] Error 1

gcc/ChangeLog:

2015-04-01  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>

      * config/bfin/bfin.h (TARGET_CPU_CPP_BUILTINS): Add BFIN_CPU_UNKNOWN.

Comments

Bernhard Reutner-Fischer April 1, 2015, 9:37 p.m. UTC | #1
Bernd,

same for c6x for unk_isa, fwiw.

thanks,

On 1 April 2015 at 23:34, Bernhard Reutner-Fischer
<rep.dot.nop@gmail.com> wrote:
> Hi,
>
> gcc/c-family/c-cppbuiltin.c
> In file included from ./tm.h:21:0,
>                  from
> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:23:
> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:
> In function ‘void c_cpp_builtins(cpp_reader*)’:
> ../../../../../../home/me/src/gcc-5.0.mine/gcc/config/bfin/bfin.h:43:14:
> error: enumeration value ‘BFIN_CPU_UNKNOWN’ not handled in switch
> [-Werror=switch]
>        switch (bfin_cpu_type)   \
>               ^
> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:1243:3:
> note: in expansion of macro ‘TARGET_CPU_CPP_BUILTINS’
>    TARGET_CPU_CPP_BUILTINS ();
>    ^
> cc1plus: all warnings being treated as errors
> make[2]: *** [c-family/c-cppbuiltin.o] Error 1
>
> gcc/ChangeLog:
>
> 2015-04-01  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
>
>       * config/bfin/bfin.h (TARGET_CPU_CPP_BUILTINS): Add BFIN_CPU_UNKNOWN.
Bernhard Reutner-Fischer April 8, 2015, 8:12 p.m. UTC | #2
ping

On 1 April 2015 at 23:34, Bernhard Reutner-Fischer
<rep.dot.nop@gmail.com> wrote:
> Hi,
>
> gcc/c-family/c-cppbuiltin.c
> In file included from ./tm.h:21:0,
>                  from
> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:23:
> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:
> In function ‘void c_cpp_builtins(cpp_reader*)’:
> ../../../../../../home/me/src/gcc-5.0.mine/gcc/config/bfin/bfin.h:43:14:
> error: enumeration value ‘BFIN_CPU_UNKNOWN’ not handled in switch
> [-Werror=switch]
>        switch (bfin_cpu_type)   \
>               ^
> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:1243:3:
> note: in expansion of macro ‘TARGET_CPU_CPP_BUILTINS’
>    TARGET_CPU_CPP_BUILTINS ();
>    ^
> cc1plus: all warnings being treated as errors
> make[2]: *** [c-family/c-cppbuiltin.o] Error 1
>
> gcc/ChangeLog:
>
> 2015-04-01  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
>
>       * config/bfin/bfin.h (TARGET_CPU_CPP_BUILTINS): Add BFIN_CPU_UNKNOWN.
Bernhard Reutner-Fischer April 22, 2015, 8:11 a.m. UTC | #3
On 8 April 2015 at 22:12, Bernhard Reutner-Fischer
<rep.dot.nop@gmail.com> wrote:
> ping

This was OK'ed by Jeff and committed to trunk as r222307.
thanks,
>
> On 1 April 2015 at 23:34, Bernhard Reutner-Fischer
> <rep.dot.nop@gmail.com> wrote:
>> Hi,
>>
>> gcc/c-family/c-cppbuiltin.c
>> In file included from ./tm.h:21:0,
>>                  from
>> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:23:
>> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:
>> In function ‘void c_cpp_builtins(cpp_reader*)’:
>> ../../../../../../home/me/src/gcc-5.0.mine/gcc/config/bfin/bfin.h:43:14:
>> error: enumeration value ‘BFIN_CPU_UNKNOWN’ not handled in switch
>> [-Werror=switch]
>>        switch (bfin_cpu_type)   \
>>               ^
>> ../../../../../../home/me/src/gcc-5.0.mine/gcc/c-family/c-cppbuiltin.c:1243:3:
>> note: in expansion of macro ‘TARGET_CPU_CPP_BUILTINS’
>>    TARGET_CPU_CPP_BUILTINS ();
>>    ^
>> cc1plus: all warnings being treated as errors
>> make[2]: *** [c-family/c-cppbuiltin.o] Error 1
>>
>> gcc/ChangeLog:
>>
>> 2015-04-01  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
>>
>>       * config/bfin/bfin.h (TARGET_CPU_CPP_BUILTINS): Add BFIN_CPU_UNKNOWN.
diff mbox

Patch

diff --git a/gcc/config/bfin/bfin.h b/gcc/config/bfin/bfin.h
index fd90199..49cc741 100644
--- a/gcc/config/bfin/bfin.h
+++ b/gcc/config/bfin/bfin.h
@@ -42,6 +42,8 @@ 
 						\
       switch (bfin_cpu_type)			\
 	{					\
+	case BFIN_CPU_UNKNOWN:			\
+	  break;				\
 	case BFIN_CPU_BF512:			\
 	  builtin_define ("__ADSPBF512__");	\
 	  builtin_define ("__ADSPBF51x__");	\