-
Notifications
You must be signed in to change notification settings - Fork 345
[IncludeTree] Do not pass compilation directories #11034
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[IncludeTree] Do not pass compilation directories #11034
Conversation
3f1d9a9
to
a1a7393
Compare
@swift-ci please test llvm |
1 similar comment
@swift-ci please test llvm |
ping |
1 similar comment
ping |
@adrian-prantl can you confirm this is okay? It's fine from my perspective. |
This is a follow up for llvm#150112 to avoid passing compilation directory for modules (and for include-tree, that is everything) |
When using include-tree, all the relative paths references should be turned into absolute path already. There is no need to pass options like `-fdebug-compilation-dir` for debug info generation as it makes cache hit less likely when two identical compilations where performed with different compilation directories.
a1a7393
to
5f0e8d7
Compare
@swift-ci please test llvm |
@@ -21,7 +23,9 @@ | |||
// RUN: %clang @%t/tu.rsp | |||
|
|||
// RUN: cat %t/tu.ll | FileCheck %s -check-prefix=LLVMIR -DPREFIX=%/t | |||
// LLVMIR: !DICompileUnit({{.*}}, splitDebugFilename: "prefix.pch" | |||
// LLVMIR: !DIFile(filename: "[[PREFIX]]/tu.c", directory: "") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where is the PREFIX FileCheck variable initialized?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would have expected [[PREFIX:.*]]
here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RUN: cat %t/tu.ll | FileCheck %s -check-prefix=LLVMIR -DPREFIX=%/t
It is initialized from the command-line.
When using include-tree, all the relative paths references should be turned into absolute path already. There is no need to pass options like
-fdebug-compilation-dir
for debug info generation as it makes cache hit less likely when two identical compilations where performed with different compilation directories.