[PATCH] D69778: Make -fmodules-codegen and -fmodules-debuginfo work also with precompiled headers

Luboš Luňák via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Dec 6 02:00:58 PST 2019


llunak added a comment.

In D69778#1771799 <https://reviews.llvm.org/D69778#1771799>, @rsmith wrote:

> It's a bit weird for this to be controlled by a `-fmodules` flag, but it's only a `-cc1` flag, so I'm OK with that; we can rename it if/when we expose it from the driver.


It's a bit weird, but I didn't want to add -fpch-codegen and then duplicate the checks everywhere. And the -building-pch-with-obj part requires a non-trivial build setup anyway. But I can create another patch that maps it all to some common flag, if wanted.

In D69778#1772125 <https://reviews.llvm.org/D69778#1772125>, @dblaikie wrote:

> I was/am still wondering whether there's a way to coalesce these codepaths between PCH and the existing modular code generation support?


In what way could this be united more? The way I understand it, the code paths are pretty much the same, they just need to account for being invoked in different contexts. This patch is tiny compared to what it was originally before I made it reuse all the codegen code.


Repository:
  rC Clang

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

https://reviews.llvm.org/D69778





More information about the cfe-commits mailing list