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 target/77267] MPX does not work in a presence of "-Wl,-as-needed" option (Ubuntu default)


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77267

--- Comment #8 from Alexander Ivchenko <aivchenk at gmail dot com> ---
Thanks, Matthias, that's a valid point about changing linker on a runtime. In
my defense, I see that right now MPX does not work with '-fuse-ld=bfd' anyways:

>gcc test.c -fcheck-pointer-bounds -mmpx -fuse-ld=gold
/usr/bin/ld.gold: bndplt: unknown -z option
/usr/bin/ld.gold: use the --help option for usage information

That's not a surprise, because the check for '--push-state' is done exactly
like the check for '-z bndplt'.

Would it be possible to probe the 'other' linker (the one that is not the
default one) during a configure time? If so we may end up with something like
HAVE_BFD_PUSHPOPSTATE_SUPPORT/HAVE_GOLD_PUSHPOPSTATE_SUPPORT

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