[PATCH] Enable -fsanitize-recover for KASan
Fri Sep 5 09:28:00 GMT 2014
On Fri, Sep 05, 2014 at 12:33:54PM +0400, Yury Gribov wrote:
> On 09/05/2014 12:23 PM, Dmitry Vyukov wrote:
> >>I didn't find a good way to achieve this. See, normal asan reporting
> >>have a noreturn attribute (defined in sanitizer.def) which can't be changed
> >>depending on cmdline flag.
> >I have not looked at the code in detail. But it looks weird to me that
> >in a general-purpose programming language we can't alter an attribute
> >of an in-memory object.
> Well, builtins are described by metadata in .def files
> (those are not written in general purpose language).
> Post-hacking generated trees sounds ugly...
Note, in ubsan you also have __ubsan_something and __ubsan_something_abort
entrypoints, the latter is noreturn and terminates program, the former
is not and is used for -fsanitize-recover.
Though, for that option the default is yes for ubsan purposes, while asan
wants a default to no, so it is unclear how to solve that. Either different
option for asan recovery, or tristate option etc.
More information about the Gcc-patches