[clang] [clang modules] Setting `DebugCompilationDir` when it is safe to ignore current working directory (PR #128446)
Qiongsi Wu via cfe-commits
cfe-commits at lists.llvm.org
Sun Feb 23 17:00:58 PST 2025
qiongsiwu wrote:
Note to reviewers:
This fixes rdar://145249881, but I'd like to get some input on two things.
1. I am not sure if it is a good idea to always set `DebugCompilationDir` to root. I chose it because I think it is safe and all systems should have the root directory. I am all ears for a different choice.
2. I have not figured out a good way to test this. For some reason, I cannot get the module compilation command to produce debug information in the test (through `-g`, or `-dwarf-version` options). I don't think we _always_ want to hardcode `DebugCompilationDir` to `root`, so I think we want to set it only if dwarf info is needed. May I get some pointers to get the compiler to generate debug info when compiling the pcm?
Thanks!
https://github.com/llvm/llvm-project/pull/128446
More information about the cfe-commits
mailing list