forked from llvm/llvm-project
-
Notifications
You must be signed in to change notification settings - Fork 75
merge main into amd-staging #358
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
ronlieb
merged 64 commits into
amd-staging
from
amd/merge/upstream_merge_20251023055114
Oct 23, 2025
Merged
merge main into amd-staging #358
ronlieb
merged 64 commits into
amd-staging
from
amd/merge/upstream_merge_20251023055114
Oct 23, 2025
Conversation
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
…164025) Add MIR2Vec support to the llvm-ir2vec tool, enabling embedding generation for Machine IR alongside the existing LLVM IR functionality. (This is an initial integration; Other entity/triplet gen for vocab generation would follow as separate patches)
…4712) `mapInfoOp.getMembers()` on line 258 is use-after-free, because cloneModifyAndErase (line 255) erased `mapInfoOp`. Fix the issue by replacing subsequent `mapInfoOp` usages with `clonedOp`. Similarly, update `memberMapInfoOp` to avoid subsequent use-after-free.
This migrates some code that was calling the now-deprecated form of the MLIR builder create function.
This adds support for handling exact dynamic casts when optimizations are enabled.
Fixes the build issue in `openmp-offload-amdgpu-runtime-2` caused by llvm#164025
…lvm#164032) Standardize error message formatting in llvm-ir2vec tool using WithColor for consistent error reporting.
…lvm#164518) This adds support for calling functions via class member access expressions.
…4508) This adds handling for generating constant initializers in the case where a value we are emitting overlaps with a previous constant, such as can happen when initializing a structure with bitfields.
We were checking for cbuffers where the global was removed, but if the buffer is completely unused the whole thing can be null. --------- Co-authored-by: Helena Kotas <hekotas@microsoft.com>
This patch moves llvm::identity to IndexedMap for two reasons: - llvm::identity is used only IndexedMap. - llvm::identity is not suitable for general use as it is not quite the same as std::identity despite the comments in identity.h. Also, this patch renames the class to IdentityIndex and places it in the "detail" namespace.
) Replace two StringRefs with One StringRef + 2 x size_t. Prepare for: * llvm#164512
…to improve code quality (llvm#164219)
…rided_metadata(x) (llvm#164585)
…164211) Not all the paths appear to be implemented for GlobalISel
Post cleanup for llvm#164534.
This patch does two things: 1) The branches for `sizeof(_Dp) == sizeof(int32_t)` and `sizeof(_Dp) == sizeof(int64_t)` are merged, since these are basically identical. 2) The branch where `numeric_limits<_Dp>::radix != 2` is removed, since no platform we support (nor any I'm aware of) have a floating point type with `radix != 2`. This means that the branch is basically dead code.
…llvm#164366) Add codegen support for fpround and fpextend for zvfbfa. resolve llvm#164324
When rematting we create a new virtual register with the original def's register class. However the use may have a different register class if the interval is split, which means we end up with an invalid register class. This fixes llvm#164181 by constraining the newly created register to the use's register class. The test case is reduced as far as it goes. Because this test requires us to reach a certain amount of register pressure in certain conditions I'm not sure if there's an easy way to handwrite this scenario.
Check whether AArch64 function code padding is valid, and add an option to treat invalid code padding as error.
Finds longest (almost) plain substring in the pattern. Implementation is conservative to avoid false positives. The result is not used to optimize `GlobPattern::match()` so it's calculated on request. For * llvm#164545 --------- Co-authored-by: Luke Lau <luke@igalia.com>
For the sake of consistency.
…lvm#164388) Previously, cross-lane operations were disallowed here, but they are only problematic if the `select` condition is a vector, as the input of the operation is not simply one of the arms of the phi/select.
Post cleanup for llvm#164534.
…x-based patterns over v4f32 and v2f64 (llvm#164486) Related to llvm#55932
…tin_elementwise_int_binop callbacks (llvm#164679) Related to the discussion in llvm#162346, this PR is to remove the trailing type from the 'interp__builtin_elementwise_int_binop' callbacks.
…lvm#162734) Fixes issue with double precision sinh when using OpenMP offloading with AMD GPUs. The machinery to convert the op to a ROCDL call is already in place. llvm#162733
…lvm#164575) Fix the crash because in `ConstRecordBuilder::build` we cast to TypedAttr then we check if it null, but in case that the result from emitter is nullptr, that cast crash, In this PR I fixed the order to check first if it not null, then casting to the TypedAttr
Implement a global initializer for ComplexType Issue llvm#141365
The `--nl` flag, originally for Non-LBR mode, is deprecated and will be replaced by `--basic-events` (alias `--ba`). `--nl` remains as a deprecated alias for backward compatibility.
Refactor the logic for inferring allocated types out of `CodeGen` and into a new reusable component in `clang/AST/InferAlloc.h`. This is a preparatory step for implementing `__builtin_infer_alloc_token`. By moving the type inference heuristics into a common place, it can be shared between the existing allocation-call instrumentation and the new builtin's implementation.
We forgot to handle those in e9972de, hence the inconsistency across multiple instantiations. This is a regression on trunk, so no release note. Fixes llvm#164750
Spotted by Shafik.
… (llvm#164709) Falling through a defaultless switch statement has well defined behavior. Fixes llvm#164699. Credit for noticing this problem goes to user "pozz" on comp.lang.c, Message-ID: <10da67g$3q59f$1@dont-email.me>
Use `std::move` for shared_ptr in `lazyDeserialize` call to avoid extra refcount ops
Add assert to `StableFunctionMap::at` to verify `FunctionHash` exists.
…lvm#164428) This adds support for folding `ptrtoaddr(p2) - ptrtoaddr(p)` pointer subtractions. We can treat ptrtoaddr the same as ptrtoint as the transform is truncation safe anyway (and in fact supports explicit truncation as well). The only interesting case is the subtraction of zext of ptrtoaddr. For this transform it's important that the address bits are not truncated -- and if any pointer bits are truncated, that the truncation is consistent for both operands. I've explicitly spelled out the three different cases for this, which also fixes a miscompile in the existing ptrtoint fold.
…tic checks (llvm#163638) Introduce the `__builtin_infer_alloc_token()` builtin declaration and adds the necessary semantic checks in Sema.
dpalermo
approved these changes
Oct 23, 2025
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.
No description provided.