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: Darwin bootstrap failure following wide int merge (was: we are starting the wide int merge)


On Wed, May 28, 2014 at 12:07:41PM +0200, Richard Biener wrote:
> >>  #ifndef GCC_VERSION
> >> +/* Some compilers pretend to be GCC, even when they are not.  */
> >> +#if defined(__clang__) || defined(__INTEL_COMPILER)
> >> +#define GCC_VERSION 0
> >> +#else
> >>  #define GCC_VERSION (__GNUC__ * 1000 + __GNUC_MINOR__)
> >> +#endif
> >>  #endif /* GCC_VERSION */
> >>
> >> so that we really can trust the GCC_VERSION macro, casts in lhs of inline
> >> asm isn't the only incompatibility clang has.
> >>
> >> Any other compilers that define __GNUC__?
> >
> > Every one I guess.  ICC 9 has it defined to 4, __GNUC_MINOR__ to 0.

ICC is included in the above check, that is the __INTEL_COMPILER check.

> So if we want to go down that route I'd rather change the configury that
> checks whether we are using GCC to be more pedantic and for example
> parse $CC --version output (not for the actual version but for whether
> $CC is GCC).

include/ is shared among many GCC/binutils/GDB uses, using autoconf macros
there would be nightmare, since you'd need to replicate those tests
everywhere you'd use the header, plus lots of people customize the gcc
--version output and it has changed over the years.

	Jakub


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