llvm-project/clang/lib/Frontend
Saleem Abdulrasool 436256a713 Support Debug Info path remapping
Add support for the `-fdebug-prefix-map=` option as in GCC.  The syntax is
`-fdebug-prefix-map=OLD=NEW`.  When compiling files from a path beginning with
OLD, change the debug info to indicate the path as start with NEW.  This is
particularly helpful if you are preprocessing in one path and compiling in
another (e.g. for a build cluster with distcc).

Note that the linearity of the implementation is not as terrible as it may seem.
This is normally done once per file with an expectation that the map will be
small (1-2) entries, making this roughly linear in the number of input paths.

Addresses PR24619.

llvm-svn: 250094
2015-10-12 20:21:08 +00:00
..
Rewrite Replace double-negated !SourceLocation.isInvalid() with SourceLocation.isValid(). 2015-10-03 05:15:57 +00:00
ASTConsumers.cpp Revert r240270 ("Fixed/added namespace ending comments using clang-tidy"). 2015-06-22 23:07:51 +00:00
ASTMerge.cpp Initialize the AST consumer as soon as we have both an ASTConsumer and an 2015-08-18 20:39:29 +00:00
ASTUnit.cpp Fix Clang-tidy modernize-use-nullptr warnings in source directories; other minor cleanups 2015-10-06 23:40:43 +00:00
CMakeLists.txt Introduce a PCHContainerOperations interface (NFC). 2015-06-20 18:53:08 +00:00
CacheTokens.cpp Use raw_pwrite_stream in clang. 2015-04-14 15:15:49 +00:00
ChainedDiagnosticConsumer.cpp Remove spurious mode marker from .cpp file. 2012-10-29 06:05:01 +00:00
ChainedIncludesSource.cpp Rename the non-coding style conformant functions in namespace Builtins 2015-08-06 01:01:12 +00:00
CodeGenOptions.cpp [cleanup] Re-sort *all* #include lines with llvm/utils/sort_includes.py 2015-01-14 11:29:14 +00:00
CompilerInstance.cpp Use llvm::errc instead of std::errc. 2015-10-05 11:49:35 +00:00
CompilerInvocation.cpp Support Debug Info path remapping 2015-10-12 20:21:08 +00:00
CreateInvocationFromCommandLine.cpp [cuda] Driver changes to compile and stitch together host and device-side CUDA code. 2015-07-13 23:27:56 +00:00
DependencyFile.cpp Use new utility function to clean leading junk from pathnames. NFC 2015-09-02 21:14:53 +00:00
DependencyGraph.cpp Revert r240270 ("Fixed/added namespace ending comments using clang-tidy"). 2015-06-22 23:07:51 +00:00
DiagnosticRenderer.cpp Replace double-negated !SourceLocation.isInvalid() with SourceLocation.isValid(). 2015-10-03 05:15:57 +00:00
FrontendAction.cpp Fix crash on invalid if we can't find a suitable PCH file in a specified 2015-09-04 21:44:32 +00:00
FrontendActions.cpp Further simplify the interface of PCHContainerGenerator 2015-09-19 21:42:52 +00:00
FrontendOptions.cpp Ensure that we still parse preprocessed CUDA files as CUDA when we use 2015-03-19 17:32:06 +00:00
HeaderIncludeGen.cpp Add sanitizer blacklists to the rules generated with -M/-MM/-MD/-MMD. 2015-08-13 04:04:37 +00:00
InitHeaderSearch.cpp C++11 rangify for loops, NFC. 2015-10-01 11:19:28 +00:00
InitPreprocessor.cpp [CUDA] Allow parsing of host and device code simultaneously. 2015-09-22 17:23:22 +00:00
LangStandards.cpp [C++11] Use 'nullptr'. Frontend edition. 2014-05-22 04:46:25 +00:00
LayoutOverrideSource.cpp Excise <cctype> from Clang (except clang-tblgen) in favor of CharInfo.h. 2013-02-08 22:30:41 +00:00
LogDiagnosticPrinter.cpp Replace double negation of !FileID.isInvalid() with FileID.isValid(). 2015-10-03 10:46:20 +00:00
Makefile Make clang's rewrite engine a core feature 2014-07-16 16:48:33 +00:00
ModuleDependencyCollector.cpp [modules] Change the way we deal with .d output for explicitly-specified module 2015-08-13 17:57:10 +00:00
MultiplexConsumer.cpp [ObjC] Add NSValue support for objc_boxed_expressions 2015-06-26 05:28:36 +00:00
PCHContainerOperations.cpp Further simplify the interface of PCHContainerGenerator 2015-09-19 21:42:52 +00:00
PrintPreprocessedOutput.cpp According to the OpenMP spec, all the preprocessor macros should be 2015-06-15 23:44:27 +00:00
SerializedDiagnosticPrinter.cpp EmitRecord* API change: accepts ArrayRef instead of a SmallVector (NFC) 2015-09-10 01:46:39 +00:00
SerializedDiagnosticReader.cpp Revert r240270 ("Fixed/added namespace ending comments using clang-tidy"). 2015-06-22 23:07:51 +00:00
TextDiagnostic.cpp Replace double negation of !FileID.isInvalid() with FileID.isValid(). 2015-10-03 10:46:20 +00:00
TextDiagnosticBuffer.cpp Replace push_back(Constructor(foo)) with emplace_back(foo) for non-trivial types 2015-05-29 19:42:19 +00:00
TextDiagnosticPrinter.cpp Remove uses of the redundant ".reset(nullptr)" of unique_ptr, in favor of ".reset()" 2014-07-19 01:06:45 +00:00
VerifyDiagnosticConsumer.cpp Revert r240270 ("Fixed/added namespace ending comments using clang-tidy"). 2015-06-22 23:07:51 +00:00