[pull] main from llvm:main - #1704
Merged
Merged
Conversation
Add a lane-level XeGPU operation that re-distributes a subgroup's fragments across its lanes without changing the element type. The op takes a 1D vector — the fragment held by one lane — and returns a fragment of the same type. A pack/unpack mode selects the direction: viewing the subgroup as an S x N element grid (S = subgroup size, N = elements per lane), pack moves element j of lane i from logical position j*S + i to i*N + j, so a lane's elements end up at consecutive positions; unpack is the reverse. This implements xegpu.convert_layout semantics at the lane level when lane_layout is unchanged but lane_data differs. assisted-by-claude --------- Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Previously, trying to compile libm with LIBC_COPT_PUBLIC_PACKAGING
defined failed on 32-bit Windows with
error: alias must point to a defined variable or function
This is because 32-bit Windows adds a leading underscore to __cdecl C
functions, making the alias declaration not find its target symbol name.
The same problem exists on Apple platforms, which as solution don't emit
the alias for the C++ LIBC_NAMESPACE:: symbol.
Do the same on 32-bit Windows as on Apple platforms: Emit only
the underscore-prefixed symbol, not the LIBC_NAMESPACE:: alias.
Defer to ConstantFolding on all-constant operands, in llvm::simplifyIntrinsic. The patch adds a context-function argument to ConstantFoldIntrinsic for strictfp information, which is used by a new canConstantFoldIntrinsic under canConstantFoldCallTo: it was necessitated by exposing the constant-folder via llvm::simplifyIntrinsic. The patch only has impact on passes that use simplifyIntrinsic via InstSimplifyFolder, other than InstCombine, which already constant-folds intrinsics.
…ring ICF (#213339) `ConcatInputSection::foldIdentical()` clears the folded functions `originalUnwindEntry`. However, it cleared every symbol: with N members, the repeated clearing is **O(N²)**. This is redundant: we should only remove the incoming `copy->symbols`. This patch moves the removing loop ahead and adds more clear comments on why we need to skip the first element. Also added a new `lld/test/MachO/icf-scale-same-class.s` with 500K identical functions as a stress test, which would've taken minutes to link, and less than a second with the patch. Testing on real-world app (IRPGO instrumentation + ICF) find that we achieved a 19x speed up (1:14:42 -> 3:55)
Exposes `OperationEquivalence` through the MLIR C API so callers can compare operations structurally rather than by handle identity. Assisted by: Claude
This fixes 350089d (#213456). Buildkite error link: https://buildkite.com/llvm-project/upstream-bazel/builds?commit=350089d0cb1652e6ff44888f46d6487db5e696e6 Co-authored-by: Google Bazel Bot <google-bazel-bot@google.com>
Reverts #213157 Reverting to fix build bots.
…n code (#213378) `b05a5d0a` added an arity-trimming step to the shared `ScriptedPythonInterface::Dispatch`: extensions are now allowed to define methods with trailing parameters as optional (`num_children(self)` vs. `num_children(self, max_count)`), so before calling into a method, `Dispatch` needs to know how many positional arguments it actually accepts and drop any trailing ones we'd otherwise pass. That check calls `PythonCallable::GetArgInfo`, which ran a whole embedded Python script through `inspect.signature` on every call, since every scripted-extension dispatch goes through it. For the common case `GetArgInfo()` actually needs to handle fast (plain Python functions/methods, classes used as constructors, and callable instances defining `__call__`, i.e. everything `Dispatch<T>()` and `CreatePluginObject()` ever pass it), the answer is available as plain data attributes, with no Python bytecode execution required: `__func__`/`__self__` to unwrap bound methods, and `__code__`'s `co_argcount`/`co_flags` for the actual positional-argument count and varargs bit. For a class, that means `__init__` -- except a class may customize `__new__` instead and leave `__init__` untouched, in which case `object.__init__` becomes lenient about extra arguments. Anything else still lacking `__code__` can fall back to the original `inspect.signature()`-based implementation, now exposed as `PythonCallable::GetArgInfoFromInspectSignature()` so it can be used separately. rdar://183776556 --------- Signed-off-by: Med Ismail Bennani <ismail@bennani.ma>
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )