aboutsummaryrefslogtreecommitdiffstats
path: root/test/Object
diff options
context:
space:
mode:
authorAhmed Bougacha <ahmed.bougacha@gmail.com>2013-08-21 19:40:28 +0000
committerAhmed Bougacha <ahmed.bougacha@gmail.com>2013-08-21 19:40:28 +0000
commitb2fdd9ee45e72eeca011a7f24c8d0ed44aba28a1 (patch)
treedd0b384b98fe5f195fd3174cdb71d6c6b9a9e43e /test/Object
parent2172767491242a77866583baf8b777683c84b3c2 (diff)
downloadexternal_llvm-b2fdd9ee45e72eeca011a7f24c8d0ed44aba28a1.zip
external_llvm-b2fdd9ee45e72eeca011a7f24c8d0ed44aba28a1.tar.gz
external_llvm-b2fdd9ee45e72eeca011a7f24c8d0ed44aba28a1.tar.bz2
MC CFG: Remap enough for data too, analoguous to r188873.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188925 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Object')
-rw-r--r--test/Object/X86/objdump-cfg-invalid-opcode.yaml48
1 files changed, 48 insertions, 0 deletions
diff --git a/test/Object/X86/objdump-cfg-invalid-opcode.yaml b/test/Object/X86/objdump-cfg-invalid-opcode.yaml
new file mode 100644
index 0000000..ad2de84
--- /dev/null
+++ b/test/Object/X86/objdump-cfg-invalid-opcode.yaml
@@ -0,0 +1,48 @@
+# RUN: yaml2obj -format=elf %s | llvm-objdump -d -yaml-cfg=%t - && FileCheck --check-prefix=CFG < %t %s
+# REQUIRES: shell
+#
+# Generated from:
+# main:
+# .LBL0_1:
+# movq 8(%rsi), %rax
+# <invalid opcode: 06>
+
+!ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATA2LSB
+ Type: ET_REL
+ Machine: EM_X86_64
+Sections:
+ - Name: .text
+ Type: SHT_PROGBITS
+ Flags: [ SHF_ALLOC, SHF_EXECINSTR ]
+ Content: "488B460806"
+
+## 0000000000000000 <main>:
+
+#CFG: Atoms:
+#CFG: - StartAddress: 0x0000000000000000
+#CFG: Size: 4
+#CFG: Type: Text
+
+## 0: 48 8b 46 08 mov 0x8(%rsi),%rax
+#CFG: - Inst: MOV64rm
+#CFG: Size: 4
+#CFG: Ops: [ RRAX, RRSI, I1, R, I8, R ]
+
+
+#CFG: - StartAddress: 0x0000000000000004
+#CFG: Size: 1
+#CFG: Type: Data
+
+## 4: 06 (bad)
+#CFG: Content: 06
+
+Symbols:
+ Global:
+ - Name: main
+ Type: STT_FUNC
+ Section: .text
+ Value: 0x0
+ Size: 5