[compiler-rt] r281679 - [asan] fix window build

Kostya Serebryany via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 16 16:36:57 PDT 2016


I wonder if we can completely eliminate this dll export list...

On Fri, Sep 16, 2016 at 10:50 AM, Reid Kleckner <rnk at google.com> wrote:

> I removed all these functions from the Windows DLL export list in r281747.
>
> We don't really need weak definitions if the user provides their own,
> right? So, on Linux, if the user enables this coverage mode and doesn't
> implement one of these hooks, everything works, but nothing happens. On
> Windows, they'll get a link error for now.
>
> That's probably going to be OK for a while. We can just tell users to
> define these hooks if they want to enable these coverage mdoes.
>
> On Thu, Sep 15, 2016 at 4:17 PM, Kostya Serebryany via llvm-commits <
> llvm-commits at lists.llvm.org> wrote:
>
>> Author: kcc
>> Date: Thu Sep 15 18:17:02 2016
>> New Revision: 281679
>>
>> URL: http://llvm.org/viewvc/llvm-project?rev=281679&view=rev
>> Log:
>> [asan] fix window build
>>
>> Modified:
>>     compiler-rt/trunk/lib/sanitizer_common/sanitizer_coverage_libcdep.cc
>>
>> Modified: compiler-rt/trunk/lib/sanitizer_common/sanitizer_coverage_
>> libcdep.cc
>> URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/sa
>> nitizer_common/sanitizer_coverage_libcdep.cc?rev=281679&r1=
>> 281678&r2=281679&view=diff
>> ============================================================
>> ==================
>> --- compiler-rt/trunk/lib/sanitizer_common/sanitizer_coverage_libcdep.cc
>> (original)
>> +++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_coverage_libcdep.cc
>> Thu Sep 15 18:17:02 2016
>> @@ -1040,6 +1040,7 @@ uptr __sanitizer_update_counter_bitset_a
>>    return coverage_data.Update8bitCounterBitsetAndClearCounters(bitset);
>>  }
>>  // Default empty implementations (weak). Users should redefine them.
>> +#if !SANITIZER_WINDOWS  // weak does not work on Windows.
>>  SANITIZER_INTERFACE_ATTRIBUTE SANITIZER_WEAK_ATTRIBUTE
>>  void __sanitizer_cov_trace_cmp() {}
>>  SANITIZER_INTERFACE_ATTRIBUTE SANITIZER_WEAK_ATTRIBUTE
>> @@ -1064,4 +1065,5 @@ SANITIZER_INTERFACE_ATTRIBUTE SANITIZER_
>>  void __sanitizer_cov_trace_pc_indir() {}
>>  SANITIZER_INTERFACE_ATTRIBUTE SANITIZER_WEAK_ATTRIBUTE
>>  void __sanitizer_cov_trace_pc_guard_init() {}
>> +#endif  // !SANITIZER_WINDOWS
>>  } // extern "C"
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-commits
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160916/64b5739c/attachment.html>


More information about the llvm-commits mailing list