[LLVMdev] How to define macros in a tablegen file?

Sebastian Pop spop at codeaurora.org
Wed Jun 20 10:34:26 PDT 2012


On Wed, Jun 20, 2012 at 12:26 PM, Sebastian Pop <spop at codeaurora.org> wrote:
> For reference, here is how the SPU port is using code and pattern fragments:
>
> // Holder of code fragments (you'd think this'd already be in
> // a td file somewhere... :-)

And this comment makes me think, shouldn't this class CodeFrag be
included in the same place where PatFrag is declared:

./include/llvm/Target/TargetSelectionDAG.td:544:class PatFrag<dag ops,
dag frag, code pred = [{}],

such that we get it included through "llvm/Target/Target.td"?

I will prepare a patch for this.

Sebastian
-- 
Qualcomm Innovation Center, Inc is a member of Code Aurora Forum



More information about the llvm-dev mailing list