[llvm-commits] [llvm] r108118 - /llvm/trunk/lib/CodeGen/RegAllocPBQP.cpp

Rafael Espindola espindola at google.com
Sun Jul 18 18:40:38 PDT 2010


> Correct, except the value types don't matter. For instance, it is possible to coalesce two registers of classes RFP32 and RFP64. The resulting register will be RFP64 because that class has the larger spill size.
>
> TableGen says that RFP64 is a subclass of RFP32 so this will work.
>
>> I wonder what would it take to be able to coalesce, for example, a
>> vector and a fp virtual register. Just moving the value type out of
>> the register class and into the individual operations?
>
> It already is.
>
> The CoalescerPair class in RegisterCoalescing.cpp has all the gory details determining if a copy can be coalesced and what the resulting register class should be.

Ah, not using the value type after instruction selection (other than
for spilling) makes thing a lot clear. I was never sure when it was
used and when not. Thanks!

Cheers,
-- 
Rafael Ávila de Espíndola




More information about the llvm-commits mailing list