This is the mail archive of the gcc-bugs@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]

[Bug fortran/47175] no predefined macros __amd64, __amd64__, __x86_64 __x86_64__ in prepocessor


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47175

--- Comment #3 from H.J. Lu <hjl.tools at gmail dot com> 2011-01-05 14:28:51 UTC ---
(In reply to comment #2)
> (In reply to comment #1)
> > Checking __amd64, __amd64__, __x86_64 __x86_64__ for
> > pointer size is wrong since pointer size may be
> > 32bit on x86-64.
> No, it can't be. The macros are set in dependence of the target platform (m32
> or m64). That means, if m32 is given the macro __i686 is set instead of
> __amd64. On the other hand, if m64 is given the macro __amd64 is set. I don't
> want to know the really underlying platform. I (or Matlab) want to know the
> target platform. So it is right to check the __amd64 macro. You can try it with
> the gcc-4.4. Only with gfortran-4.4 the macro is missed.

See

http://www.kernel.org/pub/linux/devel/binutils/ilp32/abi.pdf

where pointer size is 32bit.


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