[llvm-commits] [llvm] r81115 - in /llvm/trunk/lib: CodeGen/RegAllocPBQP.cpp CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp CodeGen/SelectionDAG/SelectionDAGBuild.cpp CodeGen/StackSlotColoring.cpp Support/regengine.inc System/Unix/Program.inc Target/ARM/Thumb2SizeReduction.cpp Target/PowerPC/PPCISelLowering.cpp Target/X86/AsmPrinter/X86MCInstLower.cpp Target/X86/X86ISelLowering.cpp Target/XCore/XCoreRegisterInfo.cpp Transforms/Scalar/CondPropagate.cpp

Duncan Sands baldrick at free.fr
Sun Sep 6 22:58:29 PDT 2009


Hi Benjamin,

>>   MachineFunction::iterator BBI = CR.CaseBB;
>>
>> -  if (++BBI != FuncInfo.MF->end())
>> -    NextBlock = BBI;
>> +  if (++BBI != FuncInfo.MF->end()) {}
> 
> This looks weird. I think it can be reduced to
> MachineFunction::iterator BBI = CR.CaseBB + 1;

that turns out to not be equivalent.  I changed it to
   MachineFunction::iterator BBI = CR.CaseBB + 1;
   ++BBI;
instead.

>>             if (slow(m, sp, rest, ssub, esub) != NULL) {
>> -                dp = dissect(m, sp, rest, ssub, esub);
>> +                char *dp = dissect(m, sp, rest, ssub, esub);
>>                 assert(dp == rest);
> 
> this change will probably cause "unused variable" warnings in -Asserts 
> build

They were unused before too :)  However you are right that gcc
understands this now.  I have fixed it.

>> --- llvm/trunk/lib/System/Unix/Program.inc (original)
>> +++ llvm/trunk/lib/System/Unix/Program.inc Sun Sep  6 07:41:19 2009
>> @@ -116,9 +116,7 @@
>>   return false;
>> }
>>
>> -static bool Timeout = false;
>> static void TimeOutHandler(int Sig) {
>> -  Timeout = true;
>> }
> 
> It looks like this function can be removed entirely

Now done.

Thanks for thinking about this!

Best wishes,

Duncan.



More information about the llvm-commits mailing list