Skip to content

Switch to CompilerCaching.jl.#3185

Draft
maleadt wants to merge 3 commits into
mainfrom
tb/compilercaching
Draft

Switch to CompilerCaching.jl.#3185
maleadt wants to merge 3 commits into
mainfrom
tb/compilercaching

Conversation

@maleadt

@maleadt maleadt commented Jul 3, 2026

Copy link
Copy Markdown
Member

No description provided.

maleadt added a commit to maleadt/CompilerCaching.jl that referenced this pull request Jul 3, 2026
The callee walk in `typeinf!` re-infers callees via `typeinf_code` on the
same interpreter that ran the root inference cascade. The interpreter-local
cache can still hold tombstoned (LimitedAccuracy) const-prop results from
that deeper context, suppressing const-prop that would succeed in the
standalone entry and storing under-optimized source (e.g. unfolded Symbol
dispatch, failing GPU IR validation; JuliaGPU/CUDA.jl#3185). Clear the cache
before each re-inference, matching the runtime's fresh-interpreter-per-entry
behavior.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
maleadt added a commit to JuliaGPU/GPUCompiler.jl that referenced this pull request Jul 10, 2026
Julia object references (julia.constgv globals) are kept session-portable by
stripping their initializers after codegen, with relocate_gvs! baking in the
absolute addresses at the toplevel link step. Leaving them behind as internal
globals with a null initializer made them fair game for optimization passes
that run before relocation -- notably the GlobalOpt run in the PTX back-end's
finish_module! -- which folded loads of them to inline nulls and deleted the
globals, constant-folding e.g. device-side comparisons against Symbol literals
(JuliaGPU/CUDA.jl#3185). Demote them to external declarations instead, which
no pass can fold, and have relocate_gvs! restore initializer and linkage.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
@maleadt maleadt force-pushed the tb/compilercaching branch from c108625 to 94ab1ce Compare July 10, 2026 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant