forked from OSchip/llvm-project
543036a447
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. llvm-svn: 154204 |
||
---|---|---|
.. | ||
Builtins.cpp | ||
CMakeLists.txt | ||
ConvertUTF.c | ||
Diagnostic.cpp | ||
DiagnosticIDs.cpp | ||
FileManager.cpp | ||
FileSystemStatCache.cpp | ||
IdentifierTable.cpp | ||
LangOptions.cpp | ||
Makefile | ||
Module.cpp | ||
SourceLocation.cpp | ||
SourceManager.cpp | ||
TargetInfo.cpp | ||
Targets.cpp | ||
TokenKinds.cpp | ||
Version.cpp | ||
VersionTuple.cpp |