summaryrefslogtreecommitdiffstats
path: root/llvm/test/tools/yaml2obj/ELF/header-elfdatanone.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/test/tools/yaml2obj/ELF/header-elfdatanone.yaml')
-rw-r--r--llvm/test/tools/yaml2obj/ELF/header-elfdatanone.yaml15
1 files changed, 15 insertions, 0 deletions
diff --git a/llvm/test/tools/yaml2obj/ELF/header-elfdatanone.yaml b/llvm/test/tools/yaml2obj/ELF/header-elfdatanone.yaml
new file mode 100644
index 00000000000..0e1d065ddcf
--- /dev/null
+++ b/llvm/test/tools/yaml2obj/ELF/header-elfdatanone.yaml
@@ -0,0 +1,15 @@
+## We have a YAML file describing an invalid data type.
+## Check we are able to produce the invalid binary.
+
+# RUN: yaml2obj %s -o %t.o
+
+## Check that EI_DATA field is ELFDATANONE(0)
+# RUN: od -b %t.o +5 | FileCheck %s
+# CHECK: 0000005 000
+
+--- !ELF
+FileHeader:
+ Class: ELFCLASS64
+ Data: ELFDATANONE
+ Type: ET_REL
+ Machine: EM_X86_64
OpenPOWER on IntegriCloud