1 ; RUN: not llc < %s -asm-verbose=false 2>&1 | FileCheck %s
3 target datalayout = "e-m:e-p:32:32-i64:64-n32:64-S128"
4 target triple = "wasm32-unknown-unknown"
6 ; This tests the implementation of __builtin_return_address on the unknown OS.
7 ; Since this is not implemented, it should fail.
9 ; CHECK: Non-Emscripten WebAssembly hasn't implemented __builtin_return_address
10 define i8* @test_returnaddress() {
11 %r = call i8* @llvm.returnaddress(i32 0)
15 ; LLVM represents __builtin_return_address as call to this function in IR.
16 declare i8* @llvm.returnaddress(i32 immarg)