File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change @@ -45,17 +45,13 @@ function irgen(@nospecialize(job::CompilerJob); ctx::JuliaContextType)
45
45
end
46
46
47
47
# sanitize function names
48
- # FIXME : Julia should do this, but apparently fails (see maleadt/LLVM.jl#201)
48
+ # FIXME : Julia should do this, but sometimes fails (see maleadt/LLVM.jl#201)
49
49
for f in functions (mod)
50
- LLVM . isintrinsic (f) && continue
50
+ isdeclaration (f) && continue
51
51
llvmfn = LLVM. name (f)
52
- # XXX : simplify this by only renaming definitions, not declarations?
53
- startswith (llvmfn, " julia." ) && continue # Julia intrinsics
54
- startswith (llvmfn, " llvm." ) && continue # unofficial LLVM intrinsics
55
- startswith (llvmfn, " air." ) && continue # Metal AIR intrinsics
56
52
llvmfn′ = safe_name (llvmfn)
57
53
if llvmfn != llvmfn′
58
- @assert ! haskey (functions (mod), llvmfn′)
54
+ @assert ! haskey (functions (mod), llvmfn′) " Cannot rename $llvmfn to $llvmfn′ , already exists "
59
55
LLVM. name! (f, llvmfn′)
60
56
end
61
57
end
You can’t perform that action at this time.
0 commit comments