[LLVMdev] apparent mistake in several ports register td file ???
Jakob Stoklund Olesen
stoklund at 2pi.dk
Thu Mar 29 08:54:03 PDT 2012
On Mar 21, 2012, at 2:58 PM, reed kotler wrote:
> The field Num seems to have no meaning. It is not recognized by the
> backend tools. It does not hurt anything but should not be there.
>
> class ARMReg<bits<4> num, string n, list<Register> subregs = []> :
> Register<n> {
> field bits<4> Num;
> let Namespace = "ARM";
> let SubRegs = subregs;
> // All bits of ARM registers with sub-registers are covered by
> sub-registers.
> let CoveredBySubRegs = 1;
> }
You are right, the field is not used currently. Instead, we have large switch statements like getARMRegisterNumbering().
Actually, I think it might be useful to have TableGen handle the register encoding numbering, just like it does for DWARF register numbers.
/jakob
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120329/96518955/attachment.html>
More information about the llvm-dev
mailing list