[PATCH][TableGen] Allow shift operators to take bits<n>
anemet at apple.com
Wed Jul 16 17:51:42 PDT 2014
Convert the operand to int if possible, i.e. if the value is properly
initialized. (I suppose there is further room for improvement here to also
perform the shift if the uninitialized bits are shifted out.)
With this little change we can now compute the scaling factor for compressed
displacement with pure tablegen code in the X86 backend. This is useful
because both the X86-disassembler-specific part of tablegen and the assembler
need this and TD is the natural sharing place.
The patch also adds the missing documentation for the shift and add operator.
Does this look good?
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 1768 bytes
Desc: not available
More information about the llvm-commits