[LLVMdev] Accessing InstrFormat.td fields

Villmow, Micah Micah.Villmow at amd.com
Tue Oct 28 09:18:47 PDT 2008


When I setup my InstrFormat fields, I added some custom fields specific
for my backend. How do I access these from inside LLVM?

 

For example:

class InstrFormat<dag outs, dag ins, string asmstr, list<dag> pattern> 

        : Instruction {

    let Namespace = "AMD";

    dag OutOperandList = outs;

    dag InOperandList = ins;

    let Pattern = pattern;

    let AsmString = asmstr;

    OpCodeModifier ocmod;

}

 

How do I set/read the ocmod struct from either SelectCode or a separate
phase? Is there an example of this?

 

Micah Villmow

Systems Engineer

Advanced Technology & Performance

Advanced Micro Devices Inc.

4555 Great America Pkwy,

Santa Clara, CA. 95054

P: 408-572-6219

F: 408-572-6596

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20081028/e8932a29/attachment.html>


More information about the llvm-dev mailing list