[PATCH 0/7] Libsanitizer merge from upstream r285547.

Maxim Ostapenko m.ostapenko@samsung.com
Mon Nov 7 09:38:00 GMT 2016


On 07/11/16 12:28, Yuri Gribov wrote:
> On Mon, Nov 7, 2016 at 9:20 AM, Jakub Jelinek <jakub@redhat.com> wrote:
>> On Mon, Nov 07, 2016 at 12:14:39PM +0300, Maxim Ostapenko wrote:
>>> libubsan is definitely compatible.
>> Nice.
>>
>>> For libtsan we have several changes:
>>>
>>> 1) Several interceptors (34 of them) were added and __interceptor_lstat{64}
>>> were removed.
>> That is bad, I think we need to readd those and perhaps just do what
>> lstat*/stat* do.  Weren't we solving the same thing a year ago on some other
>> symbol?
>>
>>> 2) __interceptor_strchr has change in its parameters type:
>>> __interceptor_strchr(char*, int) -> __interceptor_strchr(const char*, int)
>> That is not a big deal, the function is extern "C".
>>
>>> 3) tsan's internal type __tsan::ReportDesc has several changes, but it seems
>>> that this doesn't introduce ABI incompatibility with compiler side.
>> If __tsan::ReportDesc is not defined in publicly installed headers, I think
>> we are fine.
> As a side note, why is it in the list of exported symbols?

Because it appears as a type of parameter of exported __tsan::OnReport 
function:

// Can be overriden by an application/test to intercept reports.
#ifdef TSAN_EXTERNAL_HOOKS
bool OnReport(const ReportDesc *rep, bool suppressed);
#else
SANITIZER_WEAK_CXX_DEFAULT_IMPL
bool OnReport(const ReportDesc *rep, bool suppressed) {
   (void)rep;
   return suppressed;
}
#endif

This function can be overridden by application for debugging purpose though.

>
> -I
>
>
>



More information about the Gcc-patches mailing list