We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 6301d41 + e288329 commit 7951274Copy full SHA for 7951274
src/rtlib.jl
@@ -131,7 +131,10 @@ function build_runtime(@nospecialize(job::CompilerJob); ctx)
131
emit_function!(mod, job, def, method)
132
end
133
134
- optimize!(job, mod)
+ # we cannot optimize the runtime library, because the code would then be optimized again
135
+ # during main compilation (and optimizing twice isn't safe). for example, optimization
136
+ # removes Julia address spaces, which would then lead to type mismatches when using
137
+ # functions from the runtime library from IR that has not been stripped of AS info.
138
139
mod
140
0 commit comments