[llvm] r253820 - Avoid dependency between TableGen and CodeGen

Krzysztof Parzyszek via llvm-commits llvm-commits at lists.llvm.org
Sun Nov 22 07:40:45 PST 2015


On 11/22/2015 9:31 AM, Yaron Keren wrote:
> Instead of copy&paste duplication, wouldn't it be better to introduce a
> .h or .inc file shared by both cpp sources?

Yes. See my reply to Takumi's email.

The problem is that if I put the common definitions in some file in 
include/llvm/CodeGen, then that violates layering.  I didn't want to put 
it in include/llvm/Support, and there isn't really any other obvious 
place for that common file.
As a matter of fact, the file that this commit deletes 
(DFAPacketizerDefs.h) was my initial attempt to solve the hard cycle by 
extracting the minimal set of common definitions into its own file.

If you have suggestions on how to address this in a more elegant way, 
let me know.

-Krzysztof


-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, 
hosted by The Linux Foundation


More information about the llvm-commits mailing list