[PATCH] D101775: Fix for Bug 50033 - -fno-temp-file is not respected when creating a pch in clang 12

Duncan P. N. Exon Smith via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon May 3 11:45:58 PDT 2021


dexonsmith added a comment.

Yep, this fixes a regression (https://bugs.llvm.org/show_bug.cgi?id=50033) caused by ad7aaa475e5e632242b07380ec47d2f35d077209 <https://reviews.llvm.org/rGad7aaa475e5e632242b07380ec47d2f35d077209>, where I somehow missed that modules and PCHs had different actual behaviour around `-fno-temp-file` despite sharing the same comments.

The code LGTM. Ideally there would be a test, but it's a bit hard to add a test for this, given that temp files aren't currently observable. Can you think of something? (Maybe it's worth adding a remark for debugging purposes when a temp file is used? With or without the filename in it? Although that could be awkward to thread through LLVM when the output backends get virtualized... What do others think?)

If no one has ideas in the next few days, I'll "accept" and commit for you. (Feel free to ping me; there's a good chance I'll lose track of this otherwise; usual ping rate is 1x/week, but happy for you to ping me sooner on this...)


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D101775/new/

https://reviews.llvm.org/D101775



More information about the cfe-commits mailing list