[LLVMdev] help with tablegen
nicholas at mxc.ca
Tue Jun 16 22:02:26 PDT 2009
In order to make metadata useful to the backend, I'd like to permit
intrinsics to be written that take metadata-typed objects. To allow
this, I decided to try adding a new machine value type right next to isVoid.
I updated both ValueTypes.td and ValueTypes.h as well as
TableGen/IntrinsicEmitter.cpp and TableGen/CodeGenTarget.cpp where they
have switch(mvt). The actual patch is attached.
This runs into trouble with the X86 backend where the SSE2 forms of ADD
llvm: Building X86.td DAG instruction selector implementation with tblgen
ADDPDrm: (set:isVoid VR128:isFP:$dst, (fadd:isFP
Included from X86.td:128:
Included from X86InstrInfo.td:3964:
Parsing X86InstrSSE.td:1320: In ADDPDrm: Could not infer all types in
defm ADD : basic_sse2_fp_binop_rm<0x58, "add", fadd,
I'm hoping someone with backend experience understands why this would
happen. I've looked over the definition of basic_sse2_fp_binop_rm and
can't see any way in which adding MVT::isMetadata should impact it or
the type inference step.
I'm stumped. Does anyone have any suggestions?
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 7893 bytes
Desc: not available
More information about the llvm-dev