[llvm-commits] [llvm] r118640 - /llvm/trunk/lib/Target/ARM/AsmParser/ARMAsmParser.cpp

Jim Grosbach grosbach at apple.com
Tue Nov 9 15:49:30 PST 2010


On Nov 9, 2010, at 3:32 PM, Bill Wendling wrote:

>> Also, no need for the struct container.
>> 
> No, but containers are used in all of the other structures in this union, even if they have only one field. At least it's consistent. :-)


Ah, Ok. Would it be better then to keep them as separate operands rather than bundling them up as a list? That's how the MCInst will expect them anyway, so it seems to make sense. The encoder methods can then pack them up into a bitmask, start+length pair, or whatever else is needed. I think that'll make is easier for you to construct the MCInsts from the parsed operand list. Having a non-trivial destructor on ARMOperand worries me. Making the reglist not a pointer will increase the size of ARMOperand quite a bit, which isn't good either.

-Jim



More information about the llvm-commits mailing list