File: driver.s

package info (click to toggle)
llvm-toolchain-15 1%3A15.0.6-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,554,644 kB
  • sloc: cpp: 5,922,452; ansic: 1,012,136; asm: 674,362; python: 191,568; objc: 73,855; f90: 42,327; lisp: 31,913; pascal: 11,973; javascript: 10,144; sh: 9,421; perl: 7,447; ml: 5,527; awk: 3,523; makefile: 2,520; xml: 885; cs: 573; fortran: 567
file content (42 lines) | stat: -rw-r--r-- 1,659 bytes parent folder | download | duplicates (20)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# RUN: llvm-mc -filetype=obj -triple=wasm32-unknown-unknown -o %t.o %s

.globl  _start
_start:
  .functype _start () -> ()
  end_function

# RUN: not wasm-ld %t -o 2>&1 | FileCheck --check-prefix=NO_O_VAL %s
# NO_O_VAL: error: -o: missing argument

# RUN: not wasm-ld -o %t.exe 2>&1 | FileCheck -check-prefix=IN %s
# IN: error: no input files

# RUN: not wasm-ld %t.o 2>&1 | FileCheck -check-prefix=OUT %s
# OUT: error: no output file specified

# RUN: not wasm-ld 2>&1 | FileCheck -check-prefix=BOTH %s
# BOTH:     error: no input files
# BOTH-NOT: error: no output file specified

# RUN: not wasm-ld --export-table --import-table %t.o 2>&1 \
# RUN:   | FileCheck -check-prefix=TABLE %s
# TABLE: error: --import-table and --export-table may not be used together

# RUN: not wasm-ld --relocatable --shared-memory %t.o 2>&1 \
# RUN:   | FileCheck -check-prefix=SHARED-MEM %s
# SHARED-MEM: error: -r and --shared-memory may not be used together

# RUN: wasm-ld %t.o -z foo -o /dev/null 2>&1 | FileCheck -check-prefix=ERR10 %s
# RUN: wasm-ld %t.o -z foo -o /dev/null --version 2>&1 | FileCheck -check-prefix=ERR10 %s
# ERR10: warning: unknown -z value: foo

## Check we report "unknown -z value" error even with -v.
# RUN: wasm-ld %t.o -z foo -o /dev/null -v 2>&1 | FileCheck -check-prefix=ERR10 %s

## Note: in GNU ld, --fatal-warning still leads to a warning.
# RUN: not wasm-ld %t.o -z foo --fatal-warnings 2>&1 | FileCheck --check-prefix=ERR10-FATAL %s
# ERR10-FATAL: error: unknown -z value: foo

## stack-size without an = is also an error
# RUN: not wasm-ld %t.o -z stack-size 2>&1 | FileCheck -check-prefix=ERR11 %s
# ERR11: unknown -z value: stack-size