1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-22 12:33:33 +02:00
llvm-mirror/test/CodeGen/MIR/AArch64/cfi-def-cfa.mir
Justin Lebar 975bf7a977 When printing MIR, output to errs() rather than outs().
Summary:
Without this, this command

  $ llvm-run llc -stop-after machine-cp -o - <( echo '' )

outputs an error, because we close stdout twice -- once when closing the
file opened for "-o", and again when closing outs().

Also clarify in the outs() definition that you can't ever call it if you
want to open your own raw_fd_ostream on stdout.

Reviewers: jroelofs, tstellarAMD

Subscribers: jholewinski, qcolombet, dsanders, llvm-commits

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

llvm-svn: 261286
2016-02-19 00:18:46 +00:00

32 lines
884 B
YAML

# RUN: llc -mtriple=aarch64-none-linux-gnu -start-after branch-folder -stop-after branch-folder -o /dev/null %s 2>&1 | FileCheck %s
# This test ensures that the MIR parser parses the .cfi_def_cfa operands
# correctly.
--- |
declare void @foo()
define void @trivial_fp_func() {
entry:
call void @foo()
ret void
}
...
---
name: trivial_fp_func
body: |
bb.0.entry:
liveins: %lr, %fp, %lr, %fp
%sp = frame-setup STPXpre killed %fp, killed %lr, %sp, -2
%fp = frame-setup ADDXri %sp, 0, 0
; CHECK: CFI_INSTRUCTION .cfi_def_cfa %w29, 16
frame-setup CFI_INSTRUCTION .cfi_def_cfa %w29, 16
frame-setup CFI_INSTRUCTION .cfi_offset %w30, -8
frame-setup CFI_INSTRUCTION .cfi_offset %w29, -16
BL @foo, csr_aarch64_aapcs, implicit-def dead %lr, implicit %sp, implicit-def %sp
%sp, %fp, %lr = LDPXpost %sp, 2
RET_ReallyLR
...