llvm_passes: adapt to LLVM 24 API removals - #1418
Draft
pvelesko wants to merge 1 commit into
Draft
Conversation
LLVM 24 removes four interfaces the passes still used: - PointerType::get(Type *, unsigned) - the typed-pointer form is gone, only PointerType::get(LLVMContext &, unsigned) remains. - Type::getPointerTo() - same reason. - CallInst::Create(FunctionCallee, ...) - callers must pass the function type and the callee separately. - Implicit conversion from Instruction * to InsertPosition - an iterator is required. All four replacements exist in LLVM 21 through 23 as well, so no version guards are needed and older toolchains are unaffected. Verified by building chipStar against llvm/llvm-project main (24.0.0git).
pvelesko
marked this pull request as draft
August 3, 2026 10:07
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
LLVM 24 removes four interfaces the passes still used:
All four replacements exist in LLVM 21 through 23 as well, so there are no version guards and older toolchains are unaffected. Seven files, one migration family.
Verified by building chipStar against llvm/llvm-project main (24.0.0git): the tree configures, builds and installs cleanly with zero errors.
Independent of the LLVM 23 work in #1194; this only makes the passes compile against 24.