Skip to content

Commit 5f92e8d

Browse files
authored
Fix llvmpasses
1 parent 6d01bb3 commit 5f92e8d

File tree

2 files changed

+6
-18
lines changed

2 files changed

+6
-18
lines changed

test/llvmpasses/late-lower-gc.ll

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -134,10 +134,11 @@ top:
134134
%pgcstack = call {}*** @julia.get_pgcstack()
135135
%1 = bitcast {}*** %pgcstack to {}**
136136
%current_task = getelementptr inbounds {}*, {}** %1, i64 -12
137-
138-
; CHECK: %current_task = getelementptr inbounds ptr, ptr %1, i64 -12
139-
%2 = load float, ptr addrspace(1) %0, align 4, !invariant.load !1
140-
; CHECK-NEXT: %2 = load float, ptr addrspace(1) %0, align 4, !invariant.load
137+
; TYPED: %current_task = %current_task = getelementptr inbounds {}*, {}** %1, i64 -12
138+
; OPAQUE: %current_task = getelementptr inbounds ptr, ptr %1, i64 -12
139+
%2 = load float, float addrspace(1)* %0, align 4, !invariant.load !1
140+
; TYPED-NEXT: %2 = load float, float addrspace(1)* %0, align 4, !invariant.load
141+
; OPAQUE-NEXT: %2 = load float, ptr addrspace(1) %0, align 4, !invariant.load
141142
ret void
142143
}
143144

@@ -207,7 +208,7 @@ define void @decayar([2 x {} addrspace(10)* addrspace(11)*] %ar) {
207208
%l0 = load {} addrspace(10)*, {} addrspace(10)* addrspace(11)* %e0
208209
%e1 = extractvalue [2 x {} addrspace(10)* addrspace(11)*] %ar, 1
209210
%l1 = load {} addrspace(10)*, {} addrspace(10)* addrspace(11)* %e1
210-
%r = call i32 @callee_root({} addrspace(10)* %l0, {} addrspace(10)* %l1)
211+
%r = call i32 @callee_root({} addrspace(10)* %l0, {} addrspace(10)* %l1)
211212
ret void
212213
}
213214

test/llvmpasses/remove-addrspaces.ll

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
; RUN: opt -enable-new-pm=0 --opaque-pointers=0 -load libjulia-codegen%shlibext -RemoveJuliaAddrspaces -S %s | FileCheck %s --check-prefixes=CHECK,TYPED
44
; RUN: opt -enable-new-pm=1 --opaque-pointers=0 --load-pass-plugin=libjulia-codegen%shlibext -passes='RemoveJuliaAddrspaces' -S %s | FileCheck %s --check-prefixes=CHECK,TYPED
55

6-
; RUN: opt -enable-new-pm=0 --opaque-pointers=1 -load libjulia-codegen%shlibext -RemoveJuliaAddrspaces -S %s | FileCheck %s --check-prefixes=CHECK,OPAQUE
7-
; RUN: opt -enable-new-pm=1 --opaque-pointers=1 --load-pass-plugin=libjulia-codegen%shlibext -passes='RemoveJuliaAddrspaces' -S %s | FileCheck %s --check-prefixes=CHECK,OPAQUE
86

97
; COM: check that the addrspace of the global itself is removed
108
; OPAQUE: @ejl_enz_runtime_exc = external global {}
@@ -16,10 +14,6 @@
1614
; TYPED-SAME: {}* ({}***, {}*, [1 x i64]*)* null
1715
; OPAQUE-SAME: ptr null
1816

19-
; COM: check that the addrspace of the global itself is removed
20-
; OPAQUE: @ejl_enz_runtime_exc = external global {}
21-
@ejl_enz_runtime_exc = external addrspace(10) global {}
22-
2317
define i64 @getindex({} addrspace(10)* nonnull align 16 dereferenceable(40)) {
2418
; CHECK-LABEL: @getindex
2519
top:
@@ -137,13 +131,6 @@ L6:
137131
unreachable
138132
}
139133

140-
define private fastcc void @diffejulia__mapreduce_97() {
141-
L6:
142-
; OPAQUE: store atomic ptr @ejl_enz_runtime_exc, ptr null unordered
143-
store atomic {} addrspace(10)* @ejl_enz_runtime_exc, {} addrspace(10)* addrspace(10)* null unordered, align 8
144-
unreachable
145-
}
146-
147134
; COM: check that function attributes are preserved on declarations too
148135
declare void @convergent_function() #0
149136
attributes #0 = { convergent }

0 commit comments

Comments
 (0)