aboutsummaryrefslogtreecommitdiff
path: root/lib/StaticAnalyzer/Core/ExprEngine.cpp
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2012-04-06 20:49:55 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2012-04-06 20:49:55 +0000
commitd2953ce57a4f1b0a6884b3d6b35266ab4f79fa7f (patch)
tree7ef83a608ce2aecb27d26b808ba00b5da7820a25 /lib/StaticAnalyzer/Core/ExprEngine.cpp
parent8491cb245f7fccfb049f860444467130f68189d3 (diff)
SourceManager: Vectorize ComputeLineNumbers for SSE2.
This method is very hot, it is called when emitting diagnostics, in -E mode and for many #pragma handlers. It scans through the whole source file to count newlines, records and caches them in a vector. The speedup from vectorization isn't very large, as we fall back to bytewise scanning when we hit a newline. There might be a way to avoid leaving the sse loop but everything I tried didn't work out because a call to push_back clobbers xmm registers. About 2% speedup on average on "clang -E > /dev/null" of all .cpp files in clang's lib/Sema. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@154204 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/StaticAnalyzer/Core/ExprEngine.cpp')
0 files changed, 0 insertions, 0 deletions