[PATCH] D29432: Modular Codegen: Emit inline asm into users, not modular objects
David Blaikie via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Feb 13 13:07:31 PST 2017
dblaikie added a comment.
+rsmith we chatted about a bit of this offline & some things came out of it, not entirely resolved:
1. Is this the right thing for inline asm or similar things (static functions? static variables?) - I was mirroring the choice already made for static variables (motivated by the iostreams initializer) sort of broadening that idea to "you can put internal linkage things in headers so long as you don't actually violate the ODR by referring to them in linkage-having entities in the header". But that may be impractically aggressive. Practically speaking maybe static locals get a special exemption and everything else goes everywhere it's used, modular object or not?
2. The refactoring of DeclMustBeEmitted to take an (in)out parameter seemed good, but there was some discussion around whether it should instead return a more complex value rather than an optional inout parameter. Did you have any further thoughts on that? I think we talked about it possibly being a bit complicated for existing callers because they want to treat two different states as "false" (both Never and Always map to "it doesn't /have/ to be emitted").
https://reviews.llvm.org/D29432
More information about the cfe-commits
mailing list