[PATCH, rs6000] Enable ASAN build on powerpc*-linux

Peter Bergner bergner@vnet.ibm.com
Thu Dec 6 14:46:00 GMT 2012

On Thu, 2012-12-06 at 09:39 -0500, David Edelsohn wrote:
> On Wed, Dec 5, 2012 at 5:34 PM, Peter Bergner <bergner@vnet.ibm.com> wrote:
> >         * config/rs6000/rs6000.c (TARGET_ASAN_SHADOW_OFFSET): Define.
> >         (rs6000_asan_shadow_offset): New function.
> >         * config/rs6000/rs6000.h (FRAME_GROWS_DOWNWARD): Define to
> >         flag_stack_protect != 0 || flag_asan != 0.
> The definition of TARGET_ASAN_SHADOW_OFFSET and
> rs6000_asan_shadow_offset need to be limited to TARGET_ELF or !
> TARGET_XCOFF (Does it work on PPC BSD or PPC Darwin?).

That's a good question.  Having no way to test that myself, I
think limiting it to TARGET_ELF for now is the right solution
and if someone wants it to work on BSD or Darwin, they can
make the requisite changes and test it.

> That macro determines if GCC thinks -fsanitze=address is supported,
> which it is not on AIX.  The macro probably should be defined in sysv4.h,
> not rs6000.c, and the function should not be defined appropriately.

Ok, I can move the macro there.  And by the function being defined
appropriately, do you mean wrapping it in a:


or ???


More information about the Gcc-patches mailing list