LLVM/project dd20a09llvm/include/llvm/Support KnownFPClass.h, llvm/lib/Transforms/InstCombine InstCombineSimplifyDemanded.cpp

InstCombine: Handle multiple use copysign

Handle multiple use copysign in SimplifyDemandedFPClass
DeltaFile
+36-3llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
+7-7llvm/test/Transforms/InstCombine/simplify-demanded-fpclass.ll
+7-0llvm/include/llvm/Support/KnownFPClass.h
+50-103 files

LLVM/project 0271a14llvm/lib/Transforms/InstCombine InstCombineSimplifyDemanded.cpp

Address comments
DeltaFile
+3-3llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
+3-31 files

LLVM/project 479e5afllvm/test/Transforms/InstCombine simplify-demanded-fpclass.ll

InstCombine: Add baseline tests for SimplifyDemandedFPClass copysign improvements

Prepare to support more folds and multiple uses.
DeltaFile
+651-0llvm/test/Transforms/InstCombine/simplify-demanded-fpclass.ll
+651-01 files

LLVM/project 275ca9cllvm/lib/Transforms/InstCombine InstCombineSimplifyDemanded.cpp, llvm/test/Transforms/InstCombine simplify-demanded-fpclass.ll

InstCombine: Handle nsz in copysign SimplifyDemandedFPClass

If the only sign bit difference is for 0, fold through the source.
DeltaFile
+31-1llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
+2-4llvm/test/Transforms/InstCombine/simplify-demanded-fpclass.ll
+33-52 files

LLVM/project d779199llvm/test/Transforms/InstCombine simplify-demanded-fpclass.ll

Add another test
DeltaFile
+18-0llvm/test/Transforms/InstCombine/simplify-demanded-fpclass.ll
+18-01 files

LLVM/project f4b8187lldb/bindings/python python-wrapper.swig, lldb/include/lldb/Interpreter ScriptInterpreter.h

[lldb] Add conversions for SBValueList and SBValue to the python bridge.

This patch adds support for:
- PyObject -> SBValueList (which was surprisingly not there before!)
- PyObject -> SBValue
- SBValue -> ValueObjectSP using the ScriptInterpreter

These three are the main remaining plumbing changes necessary before we can get to the meat of actually using ScriptedFrame to provide values to the printer/etc. Future patches build off this change in order to allow ScriptedFrames to provide variables and get values for variable expressions.

stack-info: PR: https://github.com/llvm/llvm-project/pull/178574, branch: users/bzcheeseman/stack/5
DeltaFile
+38-0lldb/source/Plugins/ScriptInterpreter/Python/Interfaces/ScriptedPythonInterface.cpp
+14-0lldb/source/Plugins/ScriptInterpreter/Python/Interfaces/ScriptedPythonInterface.h
+12-0lldb/bindings/python/python-wrapper.swig
+10-0lldb/source/Interpreter/ScriptInterpreter.cpp
+3-0lldb/include/lldb/Interpreter/ScriptInterpreter.h
+1-0lldb/source/Plugins/ScriptInterpreter/Python/SWIGPythonBridge.h
+78-06 files

LLVM/project ea2ba05lldb/source/Commands CommandObjectDWIMPrint.cpp

[lldb] Make `print` delegate to synthetic frames.

This patch is more of a proposal in that it's a pretty dramatic change to the way that `print` works. It completely delegates getting values to the frame if the frame is synthetic, and does not redirect at all if the frame fails.

For this patch, the main goal was to allow the synthetic frame to bubble up its own errors in expression evaluation, rather than having errors come back with an extra "could not find identifier <blah>" or worse, simply get swallowed. If there's a better way to handle this, I'm more than happy to change this as long as the core goals of 'delegate variable/value extraction to the synthetic frame', and 'allow the synthetic frame to give back errors that are displayed to the user' can be met.

stack-info: PR: https://github.com/llvm/llvm-project/pull/178602, branch: users/bzcheeseman/stack/7
DeltaFile
+23-2lldb/source/Commands/CommandObjectDWIMPrint.cpp
+23-21 files

LLVM/project c3d0c37lldb/include/lldb/Interpreter/Interfaces ScriptedFrameInterface.h, lldb/source/Plugins/Process/scripted ScriptedFrame.cpp ScriptedFrame.h

[lldb] Add support for ScriptedFrame to provide values/variables.

This patch adds plumbing to support the implementations of StackFrame::Get{*}Variable{*} on ScriptedFrame. The major pieces required are:
- A modification to ScriptedFrameInterface, so that we can actually call the python methods.
- A corresponding update to the python implementation to call the python methods.
- An implementation in ScriptedFrame that can get the variable list on construction inside ScriptedFrame::Create, and pass that list into the ScriptedFrame so it can get those values on request.

There is a major caveat, which is that if the values from the python side don't have variables attached, right now, they won't be passed into the scripted frame to be stored in the variable list. Future discussions around adding support for 'extended variables' when printing frame variables may create a reason to change the VariableListSP into a ValueObjectListSP, and generate the VariableListSP on the fly, but that should be addressed at a later time.

This patch also adds tests to the frame provider test suite to prove these changes all plumb together correctly.

stack-info: PR: https://github.com/llvm/llvm-project/pull/178575, branch: users/bzcheeseman/stack/6
DeltaFile
+82-0lldb/test/API/functionalities/scripted_frame_provider/test_frame_providers.py
+72-5lldb/source/Plugins/Process/scripted/ScriptedFrame.cpp
+53-0lldb/test/API/functionalities/scripted_frame_provider/TestScriptedFrameProvider.py
+29-0lldb/source/Plugins/ScriptInterpreter/Python/Interfaces/ScriptedFramePythonInterface.cpp
+20-1lldb/source/Plugins/Process/scripted/ScriptedFrame.h
+11-0lldb/include/lldb/Interpreter/Interfaces/ScriptedFrameInterface.h
+267-62 files not shown
+277-68 files

LLVM/project 509aa8alldb/include/lldb/API SBValue.h, lldb/include/lldb/ValueObject ValueObject.h

[lldb] Move ValueImpl and ValueLocker to ValueObject, NFC.

This patch moves ValueImpl and ValueLocker to ValueObject.{h,cpp}. This follows the example set in TypeImpl/SBType, where we have something that SBType uses internally that needs to be exposed in the layer below. In this case, SBValue uses ValueImpl, which wraps ValueObject. The wrapper helps avoid bugs, so we want to keep it, but the script interpreter needs to use it and said interpreter is conceptually *below* the SB layer...which means we can't use methods on SBValue.

This patch is purely the code motion part of that, future patches will actually make use of this moved code.

stack-info: PR: https://github.com/llvm/llvm-project/pull/178573, branch: users/bzcheeseman/stack/4
DeltaFile
+0-166lldb/source/API/SBValue.cpp
+91-0lldb/source/ValueObject/ValueObject.cpp
+78-0lldb/include/lldb/ValueObject/ValueObject.h
+6-4lldb/include/lldb/API/SBValue.h
+175-1704 files

LLVM/project ad1a45bllvm/lib/Target/AArch64 AArch64TargetMachine.cpp, llvm/test/CodeGen/AArch64 ldrpre-ldr-merge.mir strpre-str-merge.mir

[AArch64] Use GISel for optnone functions (#174746)

Currently, when SDAG is run on AArch64 and an `optnone` function is
encountered, the selector is chosen as FastISel. AArch64 makes use of
GlobalISel at O0 and this patch aims to align `optnone` with this
functionality.

A flag is exposed to enable this functionality for a given backend but,
as AArch64 is currently the only backend I could find using GlobalISel
at O0 this is the only one with it implemented. This flag is set when
the target supports GlobalISel & GlobalISel hasn't been forced by the
user, the target machine or by being at an optimisation level lower than
`EnableGlobalISelAtO`.

If this happens, the GlobalISel passes are included as shown in
`llvm/test/CodeGen/AArch64/O3-pipeline.ll` and skipped by IRTranslator
for functions not marked as `optnone`.

In updating the tests based on this functionality, I found some unused

    [5 lines not shown]
DeltaFile
+79-79llvm/test/CodeGen/AArch64/ldrpre-ldr-merge.mir
+68-50llvm/test/CodeGen/AArch64/strpre-str-merge.mir
+73-14llvm/test/CodeGen/AArch64/literal_pools_float.ll
+47-0llvm/test/CodeGen/AArch64/GlobalISel/optnone-llc.ll
+37-9llvm/lib/Target/AArch64/AArch64TargetMachine.cpp
+28-0llvm/test/CodeGen/AArch64/GlobalISel/optnone-mixed.ll
+332-15217 files not shown
+437-19923 files

LLVM/project dfe05b8llvm/include/llvm/CodeGen MachineFunction.h, llvm/lib/CodeGen ResetMachineFunctionPass.cpp

[GlobalISel] Provide a fast path for ResetMachineFunctionPass when the function is empty (#177341)

As part of https://github.com/llvm/llvm-project/pull/174746 I
encountered a compile time regression due to ResetMachineFunction
performing full resets on empty functions. In normal operation, this
behaviour is not likely to impact compile time, as the pass is only
inserted when using GlobalISel.

https://github.com/llvm/llvm-project/pull/174746 includes GlobalISel
passes in the SDAG pipeline (only on AArch64) and skips them if a given
function is not optnone surfacing this. By checking if the
MachineFunction is empty we can perform a more lightweight reset that
just sets the required flags, reducing the impact of this change.
DeltaFile
+23-13llvm/lib/CodeGen/ResetMachineFunctionPass.cpp
+8-0llvm/include/llvm/CodeGen/MachineFunction.h
+31-132 files

LLVM/project 2ea77edllvm/lib/Transforms/Vectorize SLPVectorizer.cpp, llvm/test/Transforms/SLPVectorizer/X86 disjoint-or-reductions.ll

[SLP]Support for bswap pattern for bytes-based disjoint or reductions

If the reduction forms reversed bitcast, we can represent it as
a bitcast + bswap, if the source elements are byte sized

Reviewers: hiraditya, RKSimon

Pull Request: https://github.com/llvm/llvm-project/pull/178513
DeltaFile
+56-15llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp
+2-2llvm/test/Transforms/SLPVectorizer/X86/disjoint-or-reductions.ll
+58-172 files

LLVM/project b005768llvm/lib/Transforms/InstCombine InstCombineSimplifyDemanded.cpp, llvm/test/Transforms/InstCombine simplify-demanded-fpclass.ll

InstCombine: Improve single-use fneg(fabs(x)) SimplifyDemandedFPClass handling

Match the multi-use case's logic for understanding no-nan/no-inf context.
Also only apply the nsz handling in the single use case. alive2 seems to treat
nsz as nondeterministic for each use.
DeltaFile
+244-11llvm/test/Transforms/InstCombine/simplify-demanded-fpclass.ll
+74-20llvm/lib/Transforms/InstCombine/InstCombineSimplifyDemanded.cpp
+318-312 files

LLVM/project 4e5a9f5llvm/test/CodeGen/AArch64 itofp-bf16.ll scalarize-vector-load.ll, llvm/test/CodeGen/AMDGPU vector_shuffle.packed.ll

DAG: Handle load in SimplifyDemandedVectorElts

This improves some AMDGPU cases and avoids future regressions.
The combiner likes to form shuffles for cases where an extract_vector_elt
would do perfectly well, and this recovers some of the regressions from
losing load narrowing.

AMDGPU, Arch64 and RISCV test changes look broadly better. Other targets have
some improvements, but mostly regressions. In particular X86 looks much
worse. I'm guessing this is because it's shouldReduceLoadWidth is wrong.

I mostly just regenerated the checks. I assume some set of them should
switch to use volatile loads to defeat the optimization.
DeltaFile
+450-355llvm/test/CodeGen/X86/avx512-shuffles/partial_permute.ll
+106-152llvm/test/CodeGen/AMDGPU/vector_shuffle.packed.ll
+128-128llvm/test/CodeGen/AArch64/itofp-bf16.ll
+147-107llvm/test/CodeGen/AArch64/scalarize-vector-load.ll
+111-101llvm/test/CodeGen/PowerPC/v2i64_scalar_to_vector_shuffle.ll
+99-96llvm/test/CodeGen/X86/fixup-blend.ll
+1,041-939157 files not shown
+3,310-3,025163 files

LLVM/project e752df9llvm/test/CodeGen/AMDGPU amdgcn.bitcast.1024bit.ll amdgcn.bitcast.512bit.ll, llvm/test/CodeGen/RISCV fpclamptosat.ll

Rebase

Created using spr 1.3.7
DeltaFile
+74,257-82,975llvm/test/CodeGen/AMDGPU/amdgcn.bitcast.1024bit.ll
+26,135-30,267llvm/test/CodeGen/AMDGPU/amdgcn.bitcast.512bit.ll
+9,044-11,203llvm/test/CodeGen/AMDGPU/amdgcn.bitcast.320bit.ll
+5,872-6,681llvm/test/CodeGen/AMDGPU/amdgcn.bitcast.256bit.ll
+850-5,393llvm/test/CodeGen/RISCV/fpclamptosat.ll
+2,674-3,346llvm/test/CodeGen/AMDGPU/amdgcn.bitcast.128bit.ll
+118,832-139,865896 files not shown
+167,812-170,979902 files

pfSense/pfsense b67acbcsrc/usr/local/www interfaces.php

interfaces: reorder code to align with configuration type order

no functional changes intended
DeltaFile
+417-418src/usr/local/www/interfaces.php
+417-4181 files

LLVM/project 97ac55dclang/include/clang/Analysis/Analyses/LifetimeSafety Loans.h, clang/lib/Analysis/LifetimeSafety FactsGenerator.cpp Checker.cpp

Revisit handling moved origins
DeltaFile
+32-24clang/lib/Analysis/LifetimeSafety/FactsGenerator.cpp
+37-17clang/test/Sema/warn-lifetime-safety.cpp
+37-9clang/lib/Analysis/LifetimeSafety/Checker.cpp
+40-1clang/include/clang/Analysis/Analyses/LifetimeSafety/Loans.h
+26-9clang/lib/Sema/AnalysisBasedWarnings.cpp
+14-9clang/test/Sema/warn-lifetime-safety-dangling-field.cpp
+186-6913 files not shown
+287-10419 files

LLVM/project f05b4c4llvm/lib/Extensions Extensions.cpp

[NFC][LLVM] Fix macro redefinition warning in Extensions.cpp (#178555)

Also add missing file header and fixed code to used nested namespace for
definining the anchor function.
DeltaFile
+17-6llvm/lib/Extensions/Extensions.cpp
+17-61 files

pfSense/pfsense 20ac936src/etc/inc config.lib.inc

Log detaild info about config path warnings
DeltaFile
+11-30src/etc/inc/config.lib.inc
+11-301 files

LLVM/project 53ec484llvm/lib/CodeGen/SelectionDAG SelectionDAG.cpp, llvm/unittests/CodeGen SelectionDAGNodeConstructionTest.cpp

[SelectionDAG] Add CTLS to FoldConstantArithmetic and optimize i1 CTLS to 0. (#178552)

Since we don't have a CTLS intrinsic, it likely gets constant folded
while it is still a CTLZ pattern so I'm using a unittest to test it.
DeltaFile
+23-0llvm/unittests/CodeGen/SelectionDAGNodeConstructionTest.cpp
+9-0llvm/lib/CodeGen/SelectionDAG/SelectionDAG.cpp
+32-02 files

LLVM/project 21783c7clang/include/clang/Analysis/Analyses/LifetimeSafety Loans.h Facts.h, clang/lib/Analysis/LifetimeSafety FactsGenerator.cpp Checker.cpp

Revisit handling moved origins
DeltaFile
+32-24clang/lib/Analysis/LifetimeSafety/FactsGenerator.cpp
+37-17clang/test/Sema/warn-lifetime-safety.cpp
+37-9clang/lib/Analysis/LifetimeSafety/Checker.cpp
+40-1clang/include/clang/Analysis/Analyses/LifetimeSafety/Loans.h
+26-9clang/lib/Sema/AnalysisBasedWarnings.cpp
+23-0clang/include/clang/Analysis/Analyses/LifetimeSafety/Facts.h
+195-6013 files not shown
+287-10419 files

LLVM/project 1a384ffllvm/lib/Transforms/IPO OpenMPOpt.cpp

[NFCI][OpenMPOpt] replace call to getAllocatedType with getAllocationSize (#178356)

Removes reliance on the exact structure of the declared alloca type,
without changing the behavior of the code here.
DeltaFile
+7-8llvm/lib/Transforms/IPO/OpenMPOpt.cpp
+7-81 files

LLVM/project 91dad7ellvm/lib/Target/X86 X86ISelLowering.cpp, llvm/test/CodeGen/X86 merge-consecutive-loads-256.ll

[X86] canonicalizeLaneShuffleWithRepeatedOps - avoid folding vperm2x128(vpshufd(load()),undef) -> vpshufd(vperm2x128(load(),undef)) (#178675)

There's no benefit to letting vperm2x128 handle the fold in an unary
shuffle and llvm-mca assumes there's an extra register dependency, which
confuses analysis.

Fixes #178632
DeltaFile
+12-5llvm/lib/Target/X86/X86ISelLowering.cpp
+8-8llvm/test/CodeGen/X86/merge-consecutive-loads-256.ll
+20-132 files

FreeBSD/src 5a73302usr.bin/touch/tests touch_test.sh

touch: Test for -m flag

Reviewed by:    kevans
Approved by:    kevans
Sponsored by:   Klara, Inc.
Differential Revision:  https://reviews.freebsd.org/D54853
DeltaFile
+14-1usr.bin/touch/tests/touch_test.sh
+14-11 files

FreeBSD/src 578b4ecusr.bin/touch/tests touch_test.sh

touch: Test for -a flag

Reviewed by:    kevans
Approved by:    kevans
Sponsored by:   Klara, Inc.
Differential Revision:  https://reviews.freebsd.org/D54852
DeltaFile
+21-1usr.bin/touch/tests/touch_test.sh
+21-11 files

FreeBSD/src 21efed6usr.bin/touch/tests touch_test.sh

touch: Tests for -h flag

Reviewed by:    kevans
Approved by:    kevans
Sponsored by:   Klara, Inc.
Differential Revision:  https://reviews.freebsd.org/D54836
DeltaFile
+32-1usr.bin/touch/tests/touch_test.sh
+32-11 files

LLVM/project 7deea9dllvm/lib/Target/AMDGPU SIInsertWaitcnts.cpp

[AMDGPU] Move WaitcntBrackets::simplifyXcnt near other simplify functions. NFC. (#178673)

DeltaFile
+21-21llvm/lib/Target/AMDGPU/SIInsertWaitcnts.cpp
+21-211 files

LLVM/project 1b35218llvm/test/CodeGen/AArch64 ptrauth-isel.ll

Test case: check generated MIR output
DeltaFile
+57-4llvm/test/CodeGen/AArch64/ptrauth-isel.ll
+57-41 files

LLVM/project 99e63bbllvm/lib/CodeGen ExpandIRInsts.cpp, llvm/test/CodeGen/AMDGPU fptoi.i128.ll

[ExpandIRInsts] Improve variable naming

Improve naming of variables/blocks, both in the code and the
generated IR.
DeltaFile
+161-161llvm/test/Transforms/ExpandIRInsts/X86/expand-large-fp-convert-fptoui129.ll
+161-161llvm/test/Transforms/ExpandIRInsts/X86/expand-large-fp-convert-fptosi129.ll
+104-104llvm/test/Transforms/ExpandIRInsts/X86/expand-fp-convert-small.ll
+60-60llvm/test/CodeGen/AMDGPU/fptoi.i128.ll
+48-43llvm/lib/CodeGen/ExpandIRInsts.cpp
+534-5295 files

LLVM/project e2abf01clang/include/clang/Analysis/Analyses/LifetimeSafety Loans.h Facts.h, clang/lib/Analysis/LifetimeSafety FactsGenerator.cpp Checker.cpp

Revisit handling moved origins
DeltaFile
+32-24clang/lib/Analysis/LifetimeSafety/FactsGenerator.cpp
+37-9clang/lib/Analysis/LifetimeSafety/Checker.cpp
+40-1clang/include/clang/Analysis/Analyses/LifetimeSafety/Loans.h
+26-9clang/lib/Sema/AnalysisBasedWarnings.cpp
+24-0clang/include/clang/Analysis/Analyses/LifetimeSafety/Facts.h
+12-11clang/lib/Analysis/LifetimeSafety/LifetimeSafety.cpp
+171-5413 files not shown
+253-9419 files