[all-commits] [llvm/llvm-project] 3be0d8: accept 'clang++ -c a.pch -o a.o' to create PCH's o...

Luboš Luňák via All-commits all-commits at lists.llvm.org
Thu Jul 23 05:58:24 PDT 2020


  Branch: refs/heads/release/11.x
  Home:   https://github.com/llvm/llvm-project
  Commit: 3be0d8669f9a7e43cf909cdb29dc2cf087a4292d
      https://github.com/llvm/llvm-project/commit/3be0d8669f9a7e43cf909cdb29dc2cf087a4292d
  Author: Luboš Luňák <l.lunak at centrum.cz>
  Date:   2020-07-23 (Thu, 23 Jul 2020)

  Changed paths:
    M clang/lib/Driver/Types.cpp
    M clang/lib/Frontend/CompilerInvocation.cpp
    A clang/test/Driver/pch-codegen.cpp
    M clang/test/PCH/codegen.cpp

  Log Message:
  -----------
  accept 'clang++ -c a.pch -o a.o' to create PCH's object file

This way should be the same like with a.pcm for modules.
An alternative way is 'clang++ -c empty.cpp -include-pch a.pch -o a.o
-Xclang -building-pch-with-obj', which is what clang-cl's /Yc does
internally.

Differential Revision: https://reviews.llvm.org/D83716

(cherry picked from commit 3895466e2c336c0797710ae35150ba1ce6bc0b96)


  Commit: 2f1aff8325387b8ca1c9a1a14e2065827e9b1c15
      https://github.com/llvm/llvm-project/commit/2f1aff8325387b8ca1c9a1a14e2065827e9b1c15
  Author: Luboš Luňák <l.lunak at centrum.cz>
  Date:   2020-07-23 (Thu, 23 Jul 2020)

  Changed paths:
    M clang/docs/ReleaseNotes.rst
    M clang/include/clang/Driver/Options.td
    M clang/lib/Driver/ToolChains/Clang.cpp
    M clang/test/Driver/pch-codegen.cpp

  Log Message:
  -----------
  add -fpch-codegen/debuginfo mapping to -fmodules-codegen/debuginfo

Using -fmodules-* options for PCHs is a bit confusing, so add -fpch-*
variants. Having extra options also makes it simple to do a configure
check for the feature.
Also document the options in the release notes.

Differential Revision: https://reviews.llvm.org/D83623

(cherry picked from commit 54eea6127c4d77db03787b7c55765632fb9a6f1c)


Compare: https://github.com/llvm/llvm-project/compare/c522fd02da1b...2f1aff832538


More information about the All-commits mailing list