[llvm] r219899 - TRE: make TRE a bit more aggressive

Rafael EspĂ­ndola rafael.espindola at gmail.com
Fri Oct 17 14:08:41 PDT 2014


On 17 October 2014 16:50, Rafael EspĂ­ndola <rafael.espindola at gmail.com> wrote:
>> It is not so much the backend, it is also the language spec:
>>
>> It says "Both markers imply that the callee does not access allocas or
>> varargs from the caller." and I think that is what -dse was using in
>> pr7272 to break the code even before codegen.
>
> Running
>
> ./bin/opt ~/llvm/llvm/test/Transforms/Inline/byval-tail-call.ll -S
> -basicaa -inline -tailcallelim -dse
>
> I now get
>
> define void @frob(i32* %x) {
>   %x1 = alloca i32, align 4
>   %1 = bitcast i32* %x1 to i8*
>   call void @llvm.lifetime.start(i64 4, i8* %1)
>   tail call void @ext(i32* %x1)
>   tail call void @ext(i32* null)
>   %2 = bitcast i32* %x1 to i8*
>   call void @llvm.lifetime.end(i64 4, i8* %2)
>   ret void
> }
>
> Note how %x1 is passed uninitialized to ext.

The attached patch reverts the commit but updates this test to use
FileCheck variables to make it more obvious what the problem caused by
the patch was.

OK?

Cheers,
Rafael
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t.patch
Type: text/x-patch
Size: 3960 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20141017/639b87bc/attachment.bin>


More information about the llvm-commits mailing list