1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-01-31 20:51:52 +01:00

Move and add comments to the top for tailcall-string-rvo.ll

Differential Revision: http://reviews.llvm.org/D20311

llvm-svn: 270722
This commit is contained in:
Tim Shen 2016-05-25 17:01:09 +00:00
parent c1f6823ee0
commit 198e5cb8a0

View File

@ -1,5 +1,13 @@
; RUN: llc -O2 < %s | FileCheck %s
; The call to function TestBar should be a tail call, when in C++ the string
; `ret` is RVO returned.
; string TestFoo() {
; string ret = undef;
; TestBar(&ret); // tail call optimized
; return ret;
; }
target triple = "powerpc64le-linux-gnu"
%class.basic_string.11.42.73 = type { %"class.__gnu_cxx::__versa_string.10.41.72" }
@ -16,11 +24,6 @@ bb:
ret void
}
; string TestFoo() {
; string ret = undef;
; TestBar(&ret); // tail call optimized
; return ret;
; }
define void @TestFoo(%class.basic_string.11.42.73* noalias sret %arg) {
; CHECK-LABEL: TestFoo:
; CHECK: #TC_RETURNd8 TestBar 0