This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch] gcc.dg/compare1.c: Add -fno-short-enums.


Hi Gabym

I do not understand.  Why don't you add a new separate testcase for
the kind of thing you would like to test?  If this specific testcase
is expected to fail on arm*-*-eabi* and arm*-*-symbianelf* then you
should mark it as XFAIL for those targets.

The problem with XFAILing is that we would throw away the first three tests in gcc.dg/compare1.c, which are actually useful on
arm*-*-eabi* and arm*-*-symbianelf*.


I thought about separating the testcase like so

http://gcc.gnu.org/ml/gcc-patches/2005-06/msg01899.html

but Paul Brook suggested to use -fno-short-enum.

http://gcc.gnu.org/ml/gcc-patches/2005-07/msg00092.html

As yet another alternative, what about something like the following?

/* { dg-options "-Wsign-compare" } */
/* { dg-options "-Wsign-compare" { target arm*-*-eabi* and arm*-*-symbianelf* } } */


We would have to explicitly mention those targets with short enums, which I think is a bit uglier than use of -fno-short-enums, but other targets are subject to exactly the same options as before, namely -Wsign-compare without -fno-short-enums.

Kazu Hirata


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]