[llvm-commits] [llvm] r52537 - /llvm/trunk/lib/Transforms/IPO/DeadArgumentElimination.cpp

Dale Johannesen dalej at apple.com
Wed Jul 2 10:08:58 PDT 2008


On Jul 2, 2008, at 10:05 AMPDT, Devang Patel wrote:

>
> On Jul 2, 2008, at 9:58 AM, Dale Johannesen wrote:
>
>> On Jul 2, 2008, at 9:50 AMPDT, Chris Lattner wrote:
>>> On Jul 2, 2008, at 9:16 AM, Matthijs Kooijman wrote:
>>>> Hi Chris,
>>>>
>>>>>> Don't let DeadArgElimination change the return type ({} into void
>>>>>> and {T}
>>>>>> into T) when no return values are actually dead.
>>>>> Out of curiosity, why not?  {x} -> x would eliminate extractvalue
>>>>> instructions, so it seems that it would reduce the size of the IR.
>>
>> Maybe I'm missing something, but wouldn't this assume call i32 and
>> call {i32} use the same calling convention?  I don't think we can
>> assume
>> that in general.
>
> This is not for externally visible functions.

OK, that's what I'm missing, we can safely change the calling convention
of static functions...provided all calls are changed, and caller and  
callee
are changed in sync...




More information about the llvm-commits mailing list