This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH v2 9/10] Tilera (and Linux asm-generic) support for glibc
- From: Chris Metcalf <cmetcalf at tilera dot com>
- To: Roland McGrath <roland at hack dot frob dot com>
- Cc: <libc-alpha at sourceware dot org>, Arnd Bergmann <arnd at arndb dot de>, Linas Vepstas <linas at codeaurora dot org>, Guan Xuetao <gxt at mprc dot pku dot edu dot cn>, Jonas Bonn <jonas at southpole dot se>, Chen Liqin <liqin dot chen at gmail dot com>, GCC Development <gcc at gcc dot gnu dot org>, "Joseph S. Myers" <joseph at codesourcery dot com>
- Date: Fri, 11 Nov 2011 15:13:30 -0500
- Subject: Re: [PATCH v2 9/10] Tilera (and Linux asm-generic) support for glibc
- References: <201111100054.pAA0sf6u025585@farm-0002.internal.tilera.com> <201111100056.pAA0uKcv025809@farm-0002.internal.tilera.com> <20111111180905.A02A22C0F8@topped-with-meat.com>
On 11/11/2011 1:09 PM, Roland McGrath wrote:
2011-11-09 Chris Metcalf<cmetcalf@tilera.com>
* bits/byteswap.h (__bswap*): Use __builtin_bswap for gcc 4.3 and
above. Improves code generation for gcc 4.3 and 4.4 compilers
without bswap pattern detection.
This seems reasonable if some GCC folks can confirm that 4.3 and later
produce optimal code for __builtin_bswap{32,64} on all machines.
I'm cc'ing the gcc mailing list with this reply, so if someone there
can provide an authoritative statement, that would be great. It looks
like right now the i386/x86_64, ia64, and s390 architecture don't use
this header anyway, so it's less important for them. But powerpc and
sparc do use the header (in the core glibc), and most of the
architectures in the "ports" part of glibc do as well.
Roland, Joseph, if we don't hear something definitive from the gcc
folks, I'm inclined to revert this piece back to what I had in the v1
patch, where I provide a tile-specific byteswap.h using
__builtin_bswapNN(), so our gcc 4.4 will generate good code.
--
Chris Metcalf, Tilera Corp.
http://www.tilera.com