1 ; RUN: split-file %s %t
2 ; RUN: not llvm-as < %t/missing-args.ll 2>&1 | FileCheck %s --check-prefix=MISSING-ARGS
3 ; RUN: not llvm-as < %t/empty.ll 2>&1 | FileCheck %s --check-prefix=EMPTY
4 ; RUN: not llvm-as < %t/unterminated.ll 2>&1 | FileCheck %s --check-prefix=UNTERMINATED
5 ; RUN: not llvm-as < %t/invalid-kind.ll 2>&1 | FileCheck %s --check-prefix=INVALID-KIND
6 ; RUN: not llvm-as < %t/other.ll 2>&1 | FileCheck %s --check-prefix=OTHER
7 ; RUN: not llvm-as < %t/missing-colon.ll 2>&1 | FileCheck %s --check-prefix=MISSING-COLON
8 ; RUN: not llvm-as < %t/invalid-access-kind.ll 2>&1 | FileCheck %s --check-prefix=INVALID-ACCESS-KIND
9 ; RUN: not llvm-as < %t/default-after-loc.ll 2>&1 | FileCheck %s --check-prefix=DEFAULT-AFTER-LOC
12 ; MISSING-ARGS: error: expected '('
13 declare void @fn() memory
15 ; EMPTY: error: expected memory location (argmem, inaccessiblemem) or access kind (none, read, write, readwrite)
16 declare void @fn() memory()
18 ; UNTERMINATED: error: unterminated memory attribute
19 declare void @fn() memory(read
21 ; INVALID-KIND: error: expected memory location (argmem, inaccessiblemem) or access kind (none, read, write, readwrite)
22 declare void @fn() memory(foo)
24 ; OTHER: error: expected memory location (argmem, inaccessiblemem) or access kind (none, read, write, readwrite)
25 declare void @fn() memory(other: read)
27 ; MISSING-COLON: error: expected ':' after location
28 declare void @fn() memory(argmem)
29 ;--- invalid-access-kind.ll
30 ; INVALID-ACCESS-KIND: error: expected access kind (none, read, write, readwrite)
31 declare void @fn() memory(argmem: foo)
32 ;--- default-after-loc.ll
33 ; DEFAULT-AFTER-LOC: error: default access kind must be specified first
34 declare void @fn() memory(argmem: read, write)