[llvm-branch-commits] MachineInstrBuilder: Introduce copyMIMetadata() function. (PR #133535)

2025-07-31 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/133535 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] MachineInstrBuilder: Introduce copyMIMetadata() function. (PR #133535)

2025-07-31 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic commented: LGTM Something I don't entirely like is that MIMetadata holds DebugLoc, but copyMIMetadata does not copy it -- instead, it needs to be passed to CreateMachineInstr. But given how this is used it's not really a problem... https://github.com/llvm/llvm-project

[llvm-branch-commits] [llvm] [DataLayout][LangRef] Split non-integral and unstable pointer properties (PR #105735)

2025-07-31 Thread Nikita Popov via llvm-branch-commits
nikic wrote: > I'm not actively aware of any cases where the non-integrality is being used > to block invalid optimizations ... but I do know that, for example, > SeparateConstOffsetFromGEP has a mode (which I think Nvidia uses) that turns > pointer arithmetic into ptrtoint/inttoptr pairs. Th

[llvm-branch-commits] [clang] release/21.x: [CMake][Release] Build with -ffat-lto-objects (#140381) (PR #151245)

2025-07-30 Thread Nikita Popov via llvm-branch-commits
nikic wrote: Looks like the release binaries jobs are failing. https://github.com/llvm/llvm-project/pull/151245 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] [DataLayout][LangRef] Split non-integral and unstable pointer properties (PR #105735)

2025-07-30 Thread Nikita Popov via llvm-branch-commits
nikic wrote: > I would be happy to change this to just unstable and external state. I'm not > particularly happy with this name but I can't come up with something better. I think we should do that. https://github.com/llvm/llvm-project/pull/105735 ___

[llvm-branch-commits] [clang] [llvm] release/21.x [ObjCARC] Delete empty autoreleasepools with no autoreleases in them and remove ObjCARCAPElimPass (PR #150771)

2025-07-29 Thread Nikita Popov via llvm-branch-commits
nikic wrote: Yes, I feel strongly that this should not be backported. This patch is both unimportant and risky. https://github.com/llvm/llvm-project/pull/150771 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm

[llvm-branch-commits] [llvm] a268b61 - Add test

2025-07-28 Thread Nikita Popov via llvm-branch-commits
Author: Nikita Popov Date: 2025-07-28T10:02:10+02:00 New Revision: a268b616a622b20056c908c53aa762d1fc5402f1 URL: https://github.com/llvm/llvm-project/commit/a268b616a622b20056c908c53aa762d1fc5402f1 DIFF: https://github.com/llvm/llvm-project/commit/a268b616a622b20056c908c53aa762d1fc5402f1.diff

[llvm-branch-commits] [llvm] 4a2a360 - Revert "[MIPS]Fix QNaNs in the MIPS legacy NaN encodings (#139829)"

2025-07-28 Thread Nikita Popov via llvm-branch-commits
Author: Nikita Popov Date: 2025-07-28T09:52:06+02:00 New Revision: 4a2a3608513404b7005f96c1b4476f91d34f01de URL: https://github.com/llvm/llvm-project/commit/4a2a3608513404b7005f96c1b4476f91d34f01de DIFF: https://github.com/llvm/llvm-project/commit/4a2a3608513404b7005f96c1b4476f91d34f01de.diff

[llvm-branch-commits] [llvm] release/21.x: Align f128 and i128 to 16 bytes when passing on x86-32 (PR #150746)

2025-07-26 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/150746 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/21.x: Align f128 and i128 to 16 bytes when passing on x86-32 (PR #150746)

2025-07-26 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/150746 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [clang] [llvm] release/21.x [ObjCARC] Delete empty autoreleasepools with no autoreleases in them and remove ObjCARCAPElimPass (PR #150771)

2025-07-26 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic requested changes to this pull request. I don't think this should be backported. https://github.com/llvm/llvm-project/pull/150771 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cg

[llvm-branch-commits] [clang] [llvm] release/21.x [ObjCARC] Delete empty autoreleasepools with no autoreleases in them and remove ObjCARCAPElimPass (PR #150771)

2025-07-26 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/150771 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/21.x: [CodeGenPrepare] Make sure that `AddOffset` is also a loop invariant (#150625) (PR #150646)

2025-07-25 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/150646 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] TableGen: Emit perfect hash function for runtime libcalls (PR #150192)

2025-07-25 Thread Nikita Popov via llvm-branch-commits
nikic wrote: @vvereschaka That issue only needs the change to the sort predicate, not this whole PR. https://github.com/llvm/llvm-project/pull/150192 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bi

[llvm-branch-commits] [llvm] [DAG] visitFREEZE - limit freezing of multiple operands (PR #150425)

2025-07-25 Thread Nikita Popov via llvm-branch-commits
nikic wrote: Do we need all of those? For the release branch, can we revert the change fully? Or is other stuff already based on it? https://github.com/llvm/llvm-project/pull/150425 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.o

[llvm-branch-commits] [llvm] [IR] Introduce the `ptrtoaddr` instruction (PR #139357)

2025-07-23 Thread Nikita Popov via llvm-branch-commits
nikic wrote: > If we're going to add this, it would be good to add the other one of the > pair—the set-address instruction—at the same time. > > The Rust strict provenance model (and, hopefully, C++29) and CHERI both have > these as parts of the provenance model: an instruction / function that

[llvm-branch-commits] [llvm] release/21.x: [WebAssembly] Unstackify registers with no uses in ExplicitLocals (#149626) (PR #150187)

2025-07-23 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/150187 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] [DataLayout][LangRef] Split non-integral and unstable pointer properties (PR #105735)

2025-07-23 Thread Nikita Popov via llvm-branch-commits
nikic wrote: @davidchisnall See https://github.com/llvm/llvm-project/pull/139357. https://github.com/llvm/llvm-project/pull/105735 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/l

[llvm-branch-commits] [llvm] release/21.x: [LoopSimplifyCFG] Add check for missing loop preheader (#149743) (PR #150026)

2025-07-22 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/150026 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/21.x: [AArch64, TTI] Disable RealUse check for vector insert/extract costs and Apple CPUs. (#146526) (PR #149815)

2025-07-22 Thread Nikita Popov via llvm-branch-commits
nikic wrote: Is this mitigating a regression? If not, I don't think we should backport optimization improvements. https://github.com/llvm/llvm-project/pull/149815 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.ll

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-07-18 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/87573 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-07-18 Thread Nikita Popov via llvm-branch-commits
@@ -3156,6 +3157,20 @@ static void combineMetadata(Instruction *K, const Instruction *J, MDNode::getMergedCallsiteMetadata(KCallSite, JCallSite)); } + // Merge callee_type metadata. + if (!AAOnly) { +auto *JCalleeType = J->getMetadata(LLVMContext::M

[llvm-branch-commits] [llvm] [libcxx] Switch to release branch runners (PR #149385)

2025-07-18 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/149385 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-07-18 Thread Nikita Popov via llvm-branch-commits
@@ -3423,6 +3424,17 @@ static void combineMetadata(Instruction *K, const Instruction *J, MDNode::getMergedCallsiteMetadata(KCallSite, JCallSite)); } + // Merge callee_type metadata. + // Handle separately to support cases where only one instruction has

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-07-18 Thread Nikita Popov via llvm-branch-commits
@@ -5193,6 +5194,34 @@ void Verifier::visitCallsiteMetadata(Instruction &I, MDNode *MD) { visitCallStackMetadata(MD); } +static inline bool isConstantIntMetadataOperand(const Metadata *MD) { + if (auto *VAL = dyn_cast(MD)) { nikic wrote: No braces for sin

[llvm-branch-commits] [llvm] release/21.x: [Support][BLAKE3] Restore static on blake3_hash4_neon (#149046) (PR #149126)

2025-07-17 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/149126 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/21.x: [Support][BLAKE3] Prefix more blake3 methods (#149007) (PR #149048)

2025-07-16 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/149048 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] TableGen: Avoid emitting trailing whitespace in StringToOffsetTable (PR #148840)

2025-07-15 Thread Nikita Popov via llvm-branch-commits
@@ -38,7 +38,7 @@ void StringToOffsetTable::EmitStringTableDef(raw_ostream &OS, #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Woverlength-strings" #endif -{} constexpr char {}{}Storage[] = )", +{} constexpr char {}{}Storage[] =)", nikic wrote: I

[llvm-branch-commits] [llvm] TableGen: Avoid emitting trailing whitespace in StringToOffsetTable (PR #148840)

2025-07-15 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/148840 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] TableGen: Avoid emitting trailing whitespace in StringToOffsetTable (PR #148840)

2025-07-15 Thread Nikita Popov via llvm-branch-commits
@@ -38,7 +38,7 @@ void StringToOffsetTable::EmitStringTableDef(raw_ostream &OS, #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Woverlength-strings" #endif -{} constexpr char {}{}Storage[] = )", +{} constexpr char {}{}Storage[] =)", nikic wrote: I

[llvm-branch-commits] [llvm] RuntimeLibcalls: Invert handling of 64-bit only libcalls (PR #148571)

2025-07-14 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/148571 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] RuntimeLibcalls: Invert handling of 64-bit only libcalls (PR #148571)

2025-07-14 Thread Nikita Popov via llvm-branch-commits
@@ -938,6 +933,11 @@ def calloc : RuntimeLibcallImpl; // compiler-rt, not available for most architectures // +def __ashlti3 : RuntimeLibcallImpl; +def __lshrti3 : RuntimeLibcallImpl; +def __ashrti3 : RuntimeL

[llvm-branch-commits] [llvm] release/20.x: [X86] Ignore NSW when DstSVT is i32 (#131755) (PR #147034)

2025-07-04 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/147034 >From c50b409b6b523fa4b8164b80515a93b12e1b5cd4 Mon Sep 17 00:00:00 2001 From: Phoebe Wang Date: Tue, 18 Mar 2025 13:04:23 +0100 Subject: [PATCH] [X86] Ignore NSW when DstSVT is i32 (#131755) We don't have PACKSS

[llvm-branch-commits] [llvm] release/20.x: [RelLookupTableConverter] Drop unnamed_addr for GVs in entries to avoid generating GOTPCREL relocations (#146068) (PR #146191)

2025-07-03 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/146191 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [lld] release/20.x: Backport [LLD][COFF] Disallow importing DllMain from import libraries (#146610) (PR #146699)

2025-07-03 Thread Nikita Popov via llvm-branch-commits
@@ -313,6 +313,7 @@ struct Configuration { bool warnDebugInfoUnusable = true; bool warnLongSectionNames = true; bool warnStdcallFixup = true; + bool warnExportedDllMain = true; nikic wrote: This is an ABI break. https://github.com/llvm/llvm-project/pul

[llvm-branch-commits] AlwaysInliner: A new inlining algorithm to interleave alloca promotion with inlines. (PR #145613)

2025-07-02 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic commented: Can you please pre-commit a PhaseOrdering test that demonstrates the problem you are trying to solve? It's hard to understand whether this is the correct solution to the problem without an actual test case. https://github.com/llvm/llvm-project/pull/145613 __

[llvm-branch-commits] [llvm] release/20.x: [RelLookupTableConverter] Drop unnamed_addr for GVs in entries to avoid generating GOTPCREL relocations (#146068) (PR #146191)

2025-06-28 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/146191 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] TableGen: Generate enum for runtime libcall implementations (PR #144973)

2025-06-27 Thread Nikita Popov via llvm-branch-commits
@@ -235,29 +247,57 @@ void RuntimeLibcallEmitter::emitGetInitRuntimeLibcallNames( // TODO: Emit libcall names as string offset table. OS << "#ifdef GET_INIT_RUNTIME_LIBCALL_NAMES\n" -"const char *const " +"const RTLIB::LibcallImpl " "llvm::RTLIB::

[llvm-branch-commits] [llvm] TableGen: Generate enum for runtime libcall implementations (PR #144973)

2025-06-27 Thread Nikita Popov via llvm-branch-commits
@@ -235,29 +247,57 @@ void RuntimeLibcallEmitter::emitGetInitRuntimeLibcallNames( // TODO: Emit libcall names as string offset table. OS << "#ifdef GET_INIT_RUNTIME_LIBCALL_NAMES\n" -"const char *const " +"const RTLIB::LibcallImpl " "llvm::RTLIB::

[llvm-branch-commits] [llvm] TableGen: Generate enum for runtime libcall implementations (PR #144973)

2025-06-27 Thread Nikita Popov via llvm-branch-commits
@@ -882,7 +902,7 @@ def exp10f128 : RuntimeLibcallImpl; def sinf128 : RuntimeLibcallImpl; def cosf128 : RuntimeLibcallImpl; def tanf128 : RuntimeLibcallImpl; -def tanhf128 : RuntimeLibcallImpl; +def tanhf128 : RuntimeLibcallImpl; nikic wrote: Should probably b

[llvm-branch-commits] [llvm] TableGen: Generate enum for runtime libcall implementations (PR #144973)

2025-06-27 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/144973 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] TableGen: Generate enum for runtime libcall implementations (PR #144973)

2025-06-27 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic edited https://github.com/llvm/llvm-project/pull/144973 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] TableGen: Generate enum for runtime libcall implementations (PR #144973)

2025-06-27 Thread Nikita Popov via llvm-branch-commits
@@ -235,29 +247,57 @@ void RuntimeLibcallEmitter::emitGetInitRuntimeLibcallNames( // TODO: Emit libcall names as string offset table. OS << "#ifdef GET_INIT_RUNTIME_LIBCALL_NAMES\n" -"const char *const " +"const RTLIB::LibcallImpl " "llvm::RTLIB::

[llvm-branch-commits] [llvm] [InlineCost] Simplify extractvalue across callsite (PR #145054)

2025-06-23 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/145054 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] [InlineCost] Simplify extractvalue across callsite (PR #145054)

2025-06-23 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic edited https://github.com/llvm/llvm-project/pull/145054 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] [InlineCost] Simplify extractvalue across callsite (PR #145054)

2025-06-23 Thread Nikita Popov via llvm-branch-commits
nikic wrote: Could you please also add a negative test where extractvalue does not simplify (e.g. same as current but swap 0 and 1). https://github.com/llvm/llvm-project/pull/145054 ___ llvm-branch-commits mailing li

[llvm-branch-commits] [llvm] MC: Move ExceptionHandling enum to Support (PR #144692)

2025-06-19 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/144692 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] RuntimeLibcalls: Pass in exception handling type (PR #144696)

2025-06-19 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/144696 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] PowerPC: Fix using long double libm functions for f128 intrinsics (PR #144382)

2025-06-16 Thread Nikita Popov via llvm-branch-commits
@@ -321,6 +321,24 @@ void RuntimeLibcallsInfo::initLibcalls(const Triple &TT) { setLibcallName(RTLIB::OGT_F128, "__gtkf2"); setLibcallName(RTLIB::UO_F128, "__unordkf2"); +setLibcallName(RTLIB::ACOS_F128, "acosf128"); +setLibcallName(RTLIB::ASIN_F128, "asinf128"

[llvm-branch-commits] [llvm] Backport 90a52f494296 to release/20.x (PR #144299)

2025-06-16 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/144299 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/20.x: [InstCombine] Avoid folding select(umin(X, Y), X) with min/max values in false arm (#143020) (PR #144322)

2025-06-16 Thread Nikita Popov via llvm-branch-commits
nikic wrote: I'm not entirely sure about this one, as this is a performance rather than correctness fix and we're late in the release cycle. But the fix itself does seem quite safe and it blocks clickhouse from updating to LLVM 20. https://github.com/llvm/llvm-project/pull/144322 _

[llvm-branch-commits] [llvm] release/20.x: [InstCombine] Avoid folding select(umin(X, Y), X) with min/max values in false arm (#143020) (PR #144322)

2025-06-16 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/144322 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/20.x: [InstCombine] Avoid folding select(umin(X, Y), X) with min/max values in false arm (#143020) (PR #144322)

2025-06-16 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic created https://github.com/llvm/llvm-project/pull/144322 Backport of https://github.com/llvm/llvm-project/pull/143020 for https://github.com/llvm/llvm-project/issues/139050. >From 9792f981063d6ddadd3678ac31e2254daa6aa9cf Mon Sep 17 00:00:00 2001 From: Nikita Popov Dat

[llvm-branch-commits] [llvm] release/20.x: [CVP] Keep `ReachableCaseCount` in sync with range of condition (#142302) (PR #142730)

2025-06-06 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic edited https://github.com/llvm/llvm-project/pull/142730 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/20.x: [AArch64] Handle XAR with v1i64 operand types (#141754) (PR #143163)

2025-06-06 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic created https://github.com/llvm/llvm-project/pull/143163 Backport of https://github.com/llvm/llvm-project/commit/32837f376f3c795d3ae6e632adc4f1a60180a646. >From 2c1c9730974c384b10bccc9f4a4f63c94377d302 Mon Sep 17 00:00:00 2001 From: David Green Date: Thu, 29 May 2025

[llvm-branch-commits] [llvm] release/20.x: [AArch64] Handle XAR with v1i64 operand types (#141754) (PR #143163)

2025-06-06 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/143163 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] WebAssembly: Stop directly using RuntimeLibcalls.def (PR #143054)

2025-06-06 Thread Nikita Popov via llvm-branch-commits
@@ -528,23 +528,20 @@ RuntimeLibcallSignatureTable &getRuntimeLibcallSignatures() { // constructor for use with a static variable struct StaticLibcallNameMap { StringMap Map; - StaticLibcallNameMap() { -static const std::pair NameLibcalls[] = { -#define HANDLE_LIBCALL(c

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
@@ -0,0 +1,24 @@ +;; Test if the callee_type metadata attached to indirect call sites adhere to the expected format. + +; RUN: llvm-as < %s | llvm-dis | FileCheck %s +define i32 @_Z13call_indirectPFicEc(ptr %func, i8 signext %x) !type !0 { +entry: + %func.addr = alloca ptr, alig

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
@@ -1302,6 +1302,24 @@ static void addRange(SmallVectorImpl &EndPoints, EndPoints.push_back(High); } +MDNode *MDNode::getMergedCalleeTypeMetadata(LLVMContext &Ctx, MDNode *A, +MDNode *B) { + SmallVector AB; + SmallSet MergedCall

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
nikic wrote: The way FileCheck works this will pass even if the metadata is not dropped. You could try whether `FileCheck --match-full-lines` works. Otherwise you could use explicit `CHECK-NOT` or `{{$}}`. https://github.com/llvm/llvm-project/pull/87573 _

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
@@ -4161,6 +4161,11 @@ Instruction *InstCombinerImpl::visitCallBase(CallBase &Call) { Call, Builder.CreateBitOrPointerCast(ReturnedArg, CallTy)); } + // Drop unnecessary callee_type metadata from calls that were converted + // into direct calls. + if (Call.

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
@@ -3377,6 +3377,11 @@ static void combineMetadata(Instruction *K, const Instruction *J, K->setMetadata(Kind, MDNode::getMostGenericAlignmentOrDereferenceable(JMD, KMD)); break; + case LLVMContext::MD_callee_type: +if (!AAOnly) +

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
@@ -5096,6 +5097,19 @@ void Verifier::visitCallsiteMetadata(Instruction &I, MDNode *MD) { visitCallStackMetadata(MD); } +void Verifier::visitCalleeTypeMetadata(Instruction &I, MDNode *MD) { + Check(isa(I), "!callee_type metadata should only exist on calls", +&I); +

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
@@ -1302,6 +1302,24 @@ static void addRange(SmallVectorImpl &EndPoints, EndPoints.push_back(High); } +MDNode *MDNode::getMergedCalleeTypeMetadata(LLVMContext &Ctx, MDNode *A, +MDNode *B) { + SmallVector AB; + SmallSet MergedCall

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
@@ -1252,6 +1252,12 @@ class MDNode : public Metadata { bool isReplaceable() const { return isTemporary() || isAlwaysReplaceable(); } bool isAlwaysReplaceable() const { return getMetadataID() == DIAssignIDKind; } + bool hasGeneralizedMDString() const { n

[llvm-branch-commits] [clang] [llvm] [llvm] Introduce callee_type metadata (PR #87573)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
@@ -1302,6 +1302,24 @@ static void addRange(SmallVectorImpl &EndPoints, EndPoints.push_back(High); } +MDNode *MDNode::getMergedCalleeTypeMetadata(LLVMContext &Ctx, MDNode *A, +MDNode *B) { + SmallVector AB; + SmallSet MergedCall

[llvm-branch-commits] LowerTypeTests: Avoid zext of ptrtoint ConstantExpr. (PR #142886)

2025-06-05 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/142886 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] TargetLibraryInfo: Add tests for function availability (PR #142536)

2025-06-03 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic requested changes to this pull request. I do not think these tests provide value. https://github.com/llvm/llvm-project/pull/142536 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/c

[llvm-branch-commits] [llvm] release/20.x: [RelLookupTableConverter] Drop unnamed_addr to avoid generating GOTPCREL relocations (#142304) (PR #142311)

2025-06-02 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/142311 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/20.x: [RelLookupTableConverter] Drop unnamed_addr to avoid generating GOTPCREL relocations (#142304) (PR #142311)

2025-06-01 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/142311 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [clang] Backport: [clang] Serialization: support hashing null template arguments (PR #141957)

2025-05-30 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/141957 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] llvm-readobj: Use reportFatalUsageError (PR #142039)

2025-05-29 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/142039 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] CodeGen: Convert some assorted errors to use reportFatalUsageError (PR #142031)

2025-05-29 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/142031 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] X86: Add X86TTIImpl::isProfitableToSinkOperands hook for immediate operands. (PR #141326)

2025-05-28 Thread Nikita Popov via llvm-branch-commits
@@ -7170,16 +7165,31 @@ bool X86TTIImpl::isProfitableToSinkOperands(Instruction *I, II->getIntrinsicID() == Intrinsic::fshr) ShiftAmountOpNum = 2; } - if (ShiftAmountOpNum == -1) return false; + auto *ShiftAmount = &I->getOperandUse(ShiftAmountOpNum);

[llvm-branch-commits] X86: Add X86TargetLowering::isProfitableToHoist hook for immediate operands. (PR #141326)

2025-05-27 Thread Nikita Popov via llvm-branch-commits
nikic wrote: @pcc I think using fsh should at least help to get a ror instead of the shr+shl+or. Actually getting the value duplicated+sunk into each block is typically done in CGP, which has a bunch of related transforms. The most generic is probably tryToSinkFreeOperands driven by TTI.isPro

[llvm-branch-commits] [llvm] [llvm][EmbedBitcodePass] Prevent modifying the module with ThinLTO (PR #139999)

2025-05-27 Thread Nikita Popov via llvm-branch-commits
@@ -33,8 +34,11 @@ PreservedAnalyses EmbedBitcodePass::run(Module &M, ModuleAnalysisManager &AM) { std::string Data; raw_string_ostream OS(Data); + // Clone the module with with Thin LTO, since ThinLTOBitcodeWriterPass changes nikic wrote: ```suggestio

[llvm-branch-commits] [llvm] [llvm][EmbedBitcodePass] Prevent modifying the module with ThinLTO (PR #139999)

2025-05-27 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. Okay, let's go with this for now. Compile-time impact of cloning the module is about 0.2% when building clang with fat LTO: https://llvm-compile-time-tracker.com/compare.php?from=11a01e851a06188ae946ace1140f866d7a667221&to=46e037d763e7997a83

[llvm-branch-commits] [llvm] [llvm][EmbedBitcodePass] Prevent modifying the module with ThinLTO (PR #139999)

2025-05-27 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic edited https://github.com/llvm/llvm-project/pull/13 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] release/20.x: [MachO] Improve bounds check (#141083) (PR #141461)

2025-05-26 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/141461 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] [release/20.x] Update release notes for SystemZ changes (PR #140060)

2025-05-24 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/140060 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [libclc] release/20.x: [libclc] Include isnan implementation for SPIR-V targets (PR #140902)

2025-05-24 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/140902 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] X86: Add X86TargetLowering::isProfitableToHoist hook for immediate operands. (PR #141326)

2025-05-23 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic commented: I'm not super clear on what it is you're trying to fix here. Probably LowerTypeTests should be directly emitting a fshl/fshr instead of a bit shift sequence to make matching to rotate more reliable. Would that help you or not? https://github.com/llvm/llvm-p

[llvm-branch-commits] Transforms: Have CSE/GVN/LICM check isProfitableToHoist() before hoisting. (PR #141325)

2025-05-23 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic requested changes to this pull request. If you're using stacked pull requests, please link the other PRs from the stack. It's impossible to understand the context otherwise. Based on just the changes in this PR: * The EarlyCSE and GVN changes do not make sense to me.

[llvm-branch-commits] [mlir] Add missing imports (PR #138550)

2025-05-22 Thread Nikita Popov via llvm-branch-commits
nikic wrote: The LLVM 19 release is no longer supported. You'll have to apply this as a local patch if you want to build and old LLVM 19 with a new libstdc++. https://github.com/llvm/llvm-project/pull/138550 ___ llvm-branch-commits mailing list llvm-b

[llvm-branch-commits] [mlir] Add missing imports (PR #138550)

2025-05-22 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic closed https://github.com/llvm/llvm-project/pull/138550 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] [llvm][EmbedBitcodePass] Prevent modifying the module with ThinLTO (PR #139999)

2025-05-15 Thread Nikita Popov via llvm-branch-commits
nikic wrote: @ilovepi Does it also work on the release branch? I'd mainly see the clone module approach as something easily backportable for the release branch, but I assume for main we'll want a different solution? https://github.com/llvm/llvm-project/pull/13 _

[llvm-branch-commits] [llvm] [llvm][EmbedBitcodePass] Prevent modifying the module with ThinLTO (PR #139999)

2025-05-15 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic commented: Didn't we switch away from cloning because it breaks blockaddress somehow? https://github.com/llvm/llvm-project/pull/13 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.o

[llvm-branch-commits] [llvm] IR: Remove redundant UseList check in addUse (PR #138676)

2025-05-14 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/138676 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] IR: Remove redundant UseList check in addUse (PR #138676)

2025-05-14 Thread Nikita Popov via llvm-branch-commits
nikic wrote: I think this may have been noise. I reran this and there are no differences over the significance threshold: https://llvm-compile-time-tracker.com/compare.php?from=6c1bb48cc45396894597c8cb897c31205d1bdeb6&to=1837fe71fcfb4363fd2b66cdb9ff6a82b3f380fb&stat=instructions:u https://gith

[llvm-branch-commits] [llvm] release/20.x: AMDGPU: Stop emitting an error on illegal addrspacecasts (#127487) (PR #127496)

2025-05-10 Thread Nikita Popov via llvm-branch-commits
nikic wrote: Closing this as https://github.com/llvm/llvm-project/pull/127751 has landed. https://github.com/llvm/llvm-project/pull/127496 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/li

[llvm-branch-commits] [llvm] release/20.x: AMDGPU: Stop emitting an error on illegal addrspacecasts (#127487) (PR #127496)

2025-05-10 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic closed https://github.com/llvm/llvm-project/pull/127496 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [clang] release/20.x: [clang-format] Fix a crash on formatting missing r_pare… (PR #139345)

2025-05-10 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic milestoned https://github.com/llvm/llvm-project/pull/139345 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] [polly] Reapply "IR: Remove uselist for constantdata (#137313)" (PR #138961)

2025-05-07 Thread Nikita Popov via llvm-branch-commits
@@ -180,6 +180,10 @@ llvm::getKnowledgeForValue(const Value *V, } return RetainedKnowledge::none(); } + + if (!V->hasUseList()) +return RetainedKnowledge::none(); nikic wrote: As a followup, we should completely remove the non-AC code in this fu

[llvm-branch-commits] [llvm] [polly] Reapply "IR: Remove uselist for constantdata (#137313)" (PR #138961)

2025-05-07 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/138961 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] ValueTracking: Handle minimumnum and maximumnum in computeKnownFPClass (PR #138737)

2025-05-06 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/138737 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] ValueTracking: Handle minimumnum/maximumnum in canCreateUndefOrPoison (PR #138729)

2025-05-06 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/138729 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] IR: Reorder ConstantData enum values (PR #138638)

2025-05-06 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic edited https://github.com/llvm/llvm-project/pull/138638 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] IR: Reorder ConstantData enum values (PR #138638)

2025-05-06 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic commented: Peculiarly, this has a negative effect on stage1 builds using gcc and a positive effect on stage2 builds using clang: https://llvm-compile-time-tracker.com/compare.php?from=420eca364b07bad78dc0a5d21da5980493798df0&to=00be79cbc7dea09fcd8a57ea51b3e800564fd986&s

[llvm-branch-commits] [llvm] llvm-reduce: Support exotic terminators in instructions-to-return (PR #134794)

2025-05-02 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/134794 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [llvm] llvm-reduce: Support exotic terminators in instructions-to-return (PR #134794)

2025-05-02 Thread Nikita Popov via llvm-branch-commits
@@ -73,28 +73,16 @@ static void rewriteFuncWithReturnType(Function &OldF, Value *NewRetValue) { } } - // Now prune any CFG edges we have to deal with. - // - // Use KeepOneInputPHIs in case the instruction we are using for the return is - // that phi. - // TODO: C

  1   2   3   4   5   6   >