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: Patch ping


DJ Delorie wrote:
>This is for the host libiberty only, and only when gcc is configured
>a certain way.  The intent is to have libiberty that is going to be
>linked into all the build and host tools instrumented, so that we
>actually catch bugs in libiberty or bugs in host/build tools calling
>libiberty functions as much as possible, but for the lto-plugin,
>which is dlopened by the linker which we don't have a control on, we
>need host libiberty without the address sanitization because
>otherwise it would only work properly if the linker itself has been
>address sanitized.

So, if libiberty isn't built with sanitization, it would still*work*
but not be instrumented?

That's my understanding. However, currently, without the patch the sanitizer is also used with the LTO plugin, which breaks the build with --with-build-config=bootstrap-ubsan,bootstrap-asan.

Always building libiberty without UBSAN/ASAN even when the bootstrap-asan/ubsan option has been used, would be an option. However, if one also sanitizes libiberty, one has the chance to find bugs also in that library.

Tobias

PS: I found the out-of-bounds checking of ASAN and the integer overflow checks of UBSAN very helpful for the program I use at work.


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