brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.5 KiB · 3122337 Raw
46 lines · plain
1; RUN: llc < %s -mtriple=thumbv7s-apple-ios6.0.0 -verify-machineinstrs2 3; Check to make sure the tail-call return at the end doesn't use a4; callee-saved register. Register hinting from t2LDRDri was getting this5; wrong. The intervening call will force allocation to try a high register6; first, so the hint will attempt to fire, but must be rejected due to7; not being in the allocation order for the tcGPR register class.8; The machine instruction verifier will make sure that all actually worked9; out the way it's supposed to.10 11%"myclass" = type { %struct.foo }12%struct.foo = type { i32, [40 x i8] }13 14define hidden void @func(ptr %Data) nounwind ssp {15  %1 = getelementptr inbounds i8, ptr %Data, i32 1216  tail call void @abc(ptr %1) nounwind17  tail call void @def(ptr %1) nounwind18  %2 = getelementptr inbounds i8, ptr %Data, i32 819  %3 = load ptr, ptr %2, align 420  tail call void @ghi(ptr %3) nounwind21  %4 = load ptr, ptr %Data, align 422  %5 = getelementptr inbounds i8, ptr %Data, i32 423  %6 = load ptr, ptr %5, align 424  %7 = icmp eq ptr %Data, null25  br i1 %7, label %10, label %826 27; <label>:12                                      ; preds = %028  %9 = tail call ptr @jkl(ptr %1) nounwind29  tail call void @mno(ptr %Data) nounwind30  br label %1031 32; <label>:14                                      ; preds = %8, %033  tail call void %4(ptr %6) nounwind34  ret void35}36 37declare void @mno(ptr)38 39declare void @def(ptr)40 41declare void @abc(ptr)42 43declare void @ghi(ptr)44 45declare ptr @jkl(ptr) nounwind46