[llvm-commits] [llvm] r133443 - in /llvm/trunk/lib/Target/PTX: PTXAsmPrinter.cpp PTXInstrInfo.cpp PTXInstrInfo.h PTXInstrInfo.td
Justin Holewinski
justin.holewinski at gmail.com
Mon Jun 20 10:15:48 PDT 2011
On Jun 20, 2011, at 12:59 PM, Jakob Stoklund Olesen wrote:
>
> On Jun 20, 2011, at 8:56 AM, Justin Holewinski wrote:
>
>> + int OpCode;
>> +
>> + // Select the appropriate opcode based on the register class
>> + if (RC == PTX::RegI16RegisterClass) {
>> + OpCode = PTX::STACKSTOREI16;
>> + }
>> + else if (RC == PTX::RegI32RegisterClass) {
>> + OpCode = PTX::STACKSTOREI32;
>> + }
>> + else if (RC == PTX::RegI64RegisterClass) {
>> + OpCode = PTX::STACKSTOREI32;
>> + }
>> + else if (RC == PTX::RegF32RegisterClass) {
>> + OpCode = PTX::STACKSTOREF32;
>> + }
>> + else if (RC == PTX::RegF64RegisterClass) {
>> + OpCode = PTX::STACKSTOREF64;
>> + }
>
> Please add an assertion for the unknown register class case.
>
> Also, format your else-ifs like so:
>
> } else if (..) {
Fixed in r133447.
>
> /jakob
>
Thanks,
Justin Holewinski
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110620/f4e15541/attachment.html>
More information about the llvm-commits
mailing list