[llvm-bugs] [Bug 42924] New: Address Sanitizer compilation time regression
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Aug 7 14:47:43 PDT 2019
https://bugs.llvm.org/show_bug.cgi?id=42924
Bug ID: 42924
Summary: Address Sanitizer compilation time regression
Product: new-bugs
Version: 9.0
Hardware: PC
OS: Linux
Status: NEW
Severity: release blocker
Priority: P
Component: new bugs
Assignee: unassignedbugs at nondot.org
Reporter: chris at detrino.org
CC: htmldeveloper at gmail.com, llvm-bugs at lists.llvm.org
I have a large TU that used to take 8 minutes to compile with Clang 8.0 and now
takes 1 hour and 20 minutes with Clang 9.0 RC1 when using -fsanitize=address.
Using the new -ftime-trace flag showed that most of the time was going towards
AddressSanitizerFunctionPass which is taking ~40ms for each function. As this
is being compiled with -O1 nothing is being inlined and that 40ms times number
of functions is adding up to more than an hour.
Further profiling showed that all the time is being spent in memmove for
copying a GlobalsMetadata type on the following line:
https://github.com/llvm/llvm-project/blob/7f7ef0208b57a4d253cd8b07053460f40ad7cbc8/llvm/lib/Transforms/Instrumentation/AddressSanitizer.cpp#L581
Git blame on that line points to https://reviews.llvm.org/D56470 and it has
some discussion on copying the GlobalsMD struct.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20190807/3c95208f/attachment.html>
More information about the llvm-bugs
mailing list