[LLVMdev] TableGen Type Inference

David Greene dag at cray.com
Thu Jun 4 13:06:03 PDT 2009

Can someone explain why TableGen can't figure this out?

VCVTDQ2PS128rm: 	(set:isVoid VR128:v4f32:$dst, (sint_to_fp:v4f32 
(bitconvert:isInt (ld:v4i32 addr:iPTR:$src)<<P:Predicate_memop>>)))
llvm/tblgen: In VCVTDQ2PS128rm: Could not infer all types in pattern!

The pattern as written looks like this:

[(set VR128:$dst, (v4f32 (sint_to_fp (bc_memopv4i32 addr:$src))))]

I'm trying to unify AVX/SSE converts in a reasonable way.  Right now,
X86InstrSSE.td doesn't have patterns for sint_to_fp and fp_to_sint
with memory operands.  I guess this is why, but I don't understand
why it's illegal.


More information about the llvm-dev mailing list