[llvm-commits] Fixes to tsan allocator64 (issue 6478053)

Dmitry Vyukov dvyukov at google.com
Fri Aug 24 08:54:26 PDT 2012


On Fri, Aug 24, 2012 at 12:17 PM, <kcc at google.com> wrote:

> LGTM++
> My fault that I left the FIXME unfixed.
>
>
> http://codereview.appspot.com/**6478053/diff/1/sanitizer_**
> common/sanitizer_allocator64.h<http://codereview.appspot.com/6478053/diff/1/sanitizer_common/sanitizer_allocator64.h>
> File sanitizer_common/sanitizer_**allocator64.h (right):
>
> http://codereview.appspot.com/**6478053/diff/1/sanitizer_**
> common/sanitizer_allocator64.**h#newcode151<http://codereview.appspot.com/6478053/diff/1/sanitizer_common/sanitizer_allocator64.h#newcode151>
> sanitizer_common/sanitizer_**allocator64.h:151: for (uptr i = 0; i < count
> && !region->free_list.empty(); i++) {
> region->free list has a size, so you don't need to empty() on every
> iteration.
> Also, if region->free_list has less than count chunks we want to
> preserve the old behavior.
> This can be done in a separate CL if you wish
>

Done in r162561.



>
> http://codereview.appspot.com/**6478053/diff/1/sanitizer_**
> common/tests/sanitizer_**allocator64_test.cc<http://codereview.appspot.com/6478053/diff/1/sanitizer_common/tests/sanitizer_allocator64_test.cc>
> File sanitizer_common/tests/**sanitizer_allocator64_test.cc (right):
>
> http://codereview.appspot.com/**6478053/diff/1/sanitizer_**
> common/tests/sanitizer_**allocator64_test.cc#newcode31<http://codereview.appspot.com/6478053/diff/1/sanitizer_common/tests/sanitizer_allocator64_test.cc#newcode31>
> sanitizer_common/tests/**sanitizer_allocator64_test.cc:**31:
> SCMap::MaxCached(i));
> please don't remove the old debug code, just append the new one.
>
> http://codereview.appspot.com/**6478053/<http://codereview.appspot.com/6478053/>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120824/511e9333/attachment.html>


More information about the llvm-commits mailing list