From bc496677d0ecc24e4372b714849b5ecc8636b3a8 Mon Sep 17 00:00:00 2001 From: Steven Wu Date: Tue, 5 Nov 2019 08:57:34 -0800 Subject: [PATCH] [Object][MachO] Rewrite macho-invalid-fat-arch-size into YAML Rewrite one of the invalid macho test input file with YAML file. The original invalid macho is breaking our internal test infrastusture because it is too broken to be copy around. rdar://problem/56879982 --- llvm/test/Object/Inputs/macho-invalid-fat-arch-size | Bin 56 -> 0 bytes llvm/test/Object/Inputs/macho-invalid-fat-arch-size.yaml | 12 ++++++++++++ llvm/test/Object/macho-invalid.test | 4 ++-- 3 files changed, 14 insertions(+), 2 deletions(-) delete mode 100644 llvm/test/Object/Inputs/macho-invalid-fat-arch-size create mode 100644 llvm/test/Object/Inputs/macho-invalid-fat-arch-size.yaml diff --git a/llvm/test/Object/Inputs/macho-invalid-fat-arch-size b/llvm/test/Object/Inputs/macho-invalid-fat-arch-size deleted file mode 100644 index dfd154c88e3884e3df4612a95668de9ee0747f8b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 56 ncmX^0Z`VEs1_nkTW(Q(sAeI4Q1t4ZR_v`IHm>?5S02u%P9&1 | FileCheck -check-prefix INVALID-FAT-HEADER %s INVALID-FAT-HEADER: macho-invalid-fat-header': truncated or malformed fat file (contains zero architecture types) -RUN: not llvm-objdump --macho --universal-headers %p/Inputs/macho-invalid-fat-arch-size 2>&1 | FileCheck -check-prefix INVALID-FAT-ARCH-SIZE %s -INVALID-FAT-ARCH-SIZE: macho-invalid-fat-arch-size': truncated or malformed fat file (offset plus size of cputype (7) cpusubtype (3) extends past the end of the file) +RUN: yaml2obj %p/Inputs/macho-invalid-fat-arch-size.yaml -o - | not llvm-objdump --macho --universal-headers - 2>&1 | FileCheck -check-prefix INVALID-FAT-ARCH-SIZE %s +INVALID-FAT-ARCH-SIZE: '-': truncated or malformed fat file (offset plus size of cputype (7) cpusubtype (3) extends past the end of the file) RUN: not llvm-objdump --macho --universal-headers %p/Inputs/macho-invalid-fat-arch-bigalign 2>&1 | FileCheck -check-prefix INVALID-FAT-ARCH-BIGALIGN %s INVALID-FAT-ARCH-BIGALIGN: macho-invalid-fat-arch-bigalign': truncated or malformed fat file (align (2^212) too large for cputype (7) cpusubtype (3) (maximum 2^15)) -- 2.7.4