brintos

brintos / llvm-project-archived public Read only

0
0
Text · 760 B · f6ec530 Raw
21 lines · plain
1; Check that we error out if tail is not possible but call is marked as mustail.2 3; RUN: not --crash llc -mtriple riscv32-unknown-linux-gnu -o - %s \4; RUN: 2>&1 | FileCheck %s5; RUN: not --crash llc -mtriple riscv32-unknown-elf -o - %s \6; RUN: 2>&1 | FileCheck %s7; RUN: not --crash llc -mtriple riscv64-unknown-linux-gnu -o - %s \8; RUN: 2>&1 | FileCheck %s9; RUN: not --crash llc -mtriple riscv64-unknown-elf -o - %s \10; RUN: 2>&1 | FileCheck %s11 12%struct.A = type { i32 }13 14declare void @callee_musttail(ptr sret(%struct.A) %a)15define void @caller_musttail(ptr sret(%struct.A) %a) {16; CHECK: LLVM ERROR: failed to perform tail call elimination on a call site marked musttail17entry:18  musttail call void @callee_musttail(ptr sret(%struct.A) %a)19  ret void20}21