Chromium Code Reviews| Index: tests_lit/parse_errs/nacl-fake-intrinsic.ll |
| diff --git a/tests_lit/parse_errs/nacl-fake-intrinsic.ll b/tests_lit/parse_errs/nacl-fake-intrinsic.ll |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..4d5d9eb01fa09a1f0aea22966e9e78ae1b439ded |
| --- /dev/null |
| +++ b/tests_lit/parse_errs/nacl-fake-intrinsic.ll |
| @@ -0,0 +1,34 @@ |
| +; Tests that we don't get fooled by a fake NaCl intrinsic. |
| + |
| +; TODO(kschimpf) Find way to run this through p2i. Note: Can't do this |
| +; currently because run-llvm2ice.py raises exception on error, |
| +; and output is lost. |
| +; RUN: %if --need=allow_dump --command llvm-as < %s \ |
| +; RUN: | %if --need=allow_dump --command pnacl-freeze \ |
| +; RUN -allow-local-symbol-tables \ |
| +; RUN: | %if --need=allow_dump --command not %llvm2ice -notranslate \ |
| +; RUN: -verbose=inst -build-on-read \ |
| +; RUN: -allow-pnacl-reader-error-recovery \ |
| +; RUN: -allow-local-symbol-tables \ |
| +; RUN: | %if --need=allow_dump --command FileCheck %s |
| + |
| +; RUN: %if --need=no_dump --command llvm-as < %s \ |
| +; RUN: | %if --need=no_dump --command pnacl-freeze \ |
| +; RUN -allow-local-symbol-tables \ |
| +; RUN: | %if --need=no_dump --command not %llvm2ice -notranslate \ |
| +; RUN: -verbose=inst -build-on-read \ |
| +; RUN: -allow-pnacl-reader-error-recovery \ |
| +; RUN: -allow-local-symbol-tables \ |
| +; RUN: | %if --need=no_dump --command FileCheck %s --check-prefix=MIN |
| + |
| +declare i32 @llvm.fake.i32(i32) |
| + |
| +define i32 @testFake(i32 %v) { |
| + %r = call i32 @llvm.fake.i32(i32 %v) |
| + ret i32 %r |
| +} |
| + |
| +; CHECK: Error: ({{.*}}) Invalid PNaCl intrinsic call to llvm.fake.i32 |
| +; MIN: Error: ({{.*}}) Invalid function record: <34 0 3 1> |
| + |
|
Jim Stichnoth
2014/11/19 19:21:00
Git is unhappy with extra blank lines at the end o
Karl
2014/11/20 17:32:09
Done.
|
| + |