diff --git a/llvm/test/CodeGen/WebAssembly/table-copy.ll b/llvm/test/CodeGen/WebAssembly/table-copy.ll --- a/llvm/test/CodeGen/WebAssembly/table-copy.ll +++ b/llvm/test/CodeGen/WebAssembly/table-copy.ll @@ -15,9 +15,7 @@ ; CHECK-NEXT: local.get 2 ; CHECK-NEXT: table.copy externref_table1, externref_table2 ; CHECK-NEXT: end_function - %tableptr1 = getelementptr [0 x %externref], ptr addrspace(1) @externref_table1, i32 0, i32 0 - %tableptr2 = getelementptr [0 x %externref], ptr addrspace(1) @externref_table2, i32 0, i32 0 - call void @llvm.wasm.table.copy(ptr addrspace(1) %tableptr1, ptr addrspace(1) %tableptr2, i32 %dst, i32 %src, i32 %len) + call void @llvm.wasm.table.copy(ptr addrspace(1) @externref_table1, ptr addrspace(1) @externref_table2, i32 %dst, i32 %src, i32 %len) ret void } @@ -34,7 +32,6 @@ ; CHECK-NEXT: table.copy externref_table1, externref_table1 ; CHECK-NEXT: end_function %dst = add nsw i32 %src, %off - %tableptr1 = getelementptr [0 x %externref], ptr addrspace(1) @externref_table1, i32 0, i32 0 - call void @llvm.wasm.table.copy(ptr addrspace(1) %tableptr1, ptr addrspace(1) %tableptr1, i32 %dst, i32 %src, i32 %len) + call void @llvm.wasm.table.copy(ptr addrspace(1) @externref_table1, ptr addrspace(1) @externref_table1, i32 %dst, i32 %src, i32 %len) ret void } diff --git a/llvm/test/CodeGen/WebAssembly/table-fill.ll b/llvm/test/CodeGen/WebAssembly/table-fill.ll --- a/llvm/test/CodeGen/WebAssembly/table-fill.ll +++ b/llvm/test/CodeGen/WebAssembly/table-fill.ll @@ -14,7 +14,6 @@ ; CHECK-NEXT: local.get 1 ; CHECK-NEXT: table.fill externref_table ; CHECK-NEXT: end_function - %tableptr = getelementptr [0 x %externref], ptr addrspace(1) @externref_table, i32 0, i32 0 - call void @llvm.wasm.table.fill.externref(ptr addrspace(1) %tableptr, i32 %start, %externref %val, i32 %len) + call void @llvm.wasm.table.fill.externref(ptr addrspace(1) @externref_table, i32 %start, %externref %val, i32 %len) ret void } diff --git a/llvm/test/CodeGen/WebAssembly/table-grow.ll b/llvm/test/CodeGen/WebAssembly/table-grow.ll --- a/llvm/test/CodeGen/WebAssembly/table-grow.ll +++ b/llvm/test/CodeGen/WebAssembly/table-grow.ll @@ -15,7 +15,6 @@ ; CHECK-NEXT: table.grow externref_table ; CHECK-NEXT: end_function %null = call %externref @llvm.wasm.ref.null.extern() - %tableptr = getelementptr [0 x %externref], ptr addrspace(1) @externref_table, i32 0, i32 0 - %newsz = call i32 @llvm.wasm.table.grow.externref(ptr addrspace(1) %tableptr, %externref %null, i32 %sz) + %newsz = call i32 @llvm.wasm.table.grow.externref(ptr addrspace(1) @externref_table, %externref %null, i32 %sz) ret i32 %newsz } diff --git a/llvm/test/CodeGen/WebAssembly/table-size.ll b/llvm/test/CodeGen/WebAssembly/table-size.ll --- a/llvm/test/CodeGen/WebAssembly/table-size.ll +++ b/llvm/test/CodeGen/WebAssembly/table-size.ll @@ -11,7 +11,6 @@ ; CHECK-NEXT: .functype table_size () -> (i32) ; CHECK-NEXT: table.size externref_table ; CHECK-NEXT: end_function - %tableptr = getelementptr [0 x %externref], ptr addrspace(1) @externref_table, i32 0, i32 0 - %sz = call i32 @llvm.wasm.table.size(ptr addrspace(1) %tableptr) + %sz = call i32 @llvm.wasm.table.size(ptr addrspace(1) @externref_table) ret i32 %sz }