llvm-project/lld/test/wasm/undefined-entry.test
Sam Clegg 65d6380cd6 [WebAssembly] Allow signautre of entry function to be flexible
Since we a no longer using this function for the wasm start
section we don't actually care what its signature is.

Differential Revision: https://reviews.llvm.org/D46594

llvm-svn: 332308
2018-05-14 23:01:16 +00:00

12 lines
527 B
Plaintext

RUN: llc -filetype=obj %p/Inputs/ret32.ll -o %t.ret32.o
RUN: not wasm-ld -o %t.wasm %t.ret32.o 2>&1 | FileCheck %s
RUN: not wasm-ld -entry=foo -o %t.wasm %t.ret32.o 2>&1 | FileCheck %s -check-prefix=CHECK-CUSTOM
RUN: not wasm-ld --allow-undefined -o %t.wasm %t.ret32.o 2>&1 | FileCheck %s -check-prefix=CHECK-ALLOW
CHECK: error: undefined symbol: _start
CHECK-CUSTOM: error: undefined symbol: foo
CHECK-ALLOW: error: entry symbol not defined (pass --no-entry to supress):
_start
RUN: wasm-ld --no-entry -o %t.wasm %t.ret32.o