1. Mar 29, 2024
  2. Mar 28, 2024
    • Nick Desaulniers's avatar
      [libc] s/NULL/nullptr (#86867) · 7789ec06
      Nick Desaulniers authored
      Otherwise we need to pull in stddef.h for the declaration of NULL.
      7789ec06
    • Craig Topper's avatar
      [RISCV] Add validation of SPIMM for cm.push/pop. (#84989) · 152fcf6e
      Craig Topper authored
      This checks the immediate is a multiple of 16 bytes.
      152fcf6e
    • Craig Topper's avatar
      [MCP] Use MachineInstr::all_defs instead of MachineInstr::defs in... · f9081354
      Craig Topper authored
      [MCP] Use MachineInstr::all_defs instead of MachineInstr::defs in hasOverlappingMultipleDef. (#86889)
      
      defs does not return the defs for inline assembly. We need to use
      all_defs to find them.
      
      Fixes #86880.
      f9081354
    • Jerry Wu's avatar
      [MLIR] Add pattern to fold insert_slice of extract_slice (#86328) · f566b079
      Jerry Wu authored
      Fold the `tensor.insert_slice` of `tensor.extract_slice` into
      `tensor_extract_slice` when the `insert_slice` simply expand some unit
      dims dropped by the `extract_slice`.
      f566b079
    • Jonas Paulsson's avatar
      [ISel] Move handling of atomic loads from SystemZ to DAGCombiner (NFC). (#86484) · 94b5c118
      Jonas Paulsson authored
      The folding of sign/zero extensions into an atomic load by specifying an
      extension type is not target specific, and therefore belongs in the
      DAGCombiner rather than in the SystemZ backend.
      
      - Handle atomic loads similarly to regular loads by adding
      AtomicLoadExtActions with set/get methods.
      - Move SystemZ extendAtomicLoad() to DagCombiner.cpp.
      94b5c118
    • Fraser Cormack's avatar
      [libclc] Make CMake messages better fit into LLVM (#86945) · e251f56a
      Fraser Cormack authored
      The libclc project is currently only properly supported as an external
      project. However, when trying to get it to also build in-tree, the CMake
      configuration messages it outputs stand out amongst the rest of the LLVM
      projects and sub-projects.
      
      This commit makes all messages clear that they belong to the libclc
      project, as well as turning them into 'STATUS' messages where
      appropriate.
      e251f56a
    • martinboehme's avatar
      [clang][dataflow] Fix for value constructor in class derived from optional. (#86942) · ae280281
      martinboehme authored
      The constructor `Derived(int)` in the newly added test
      `ClassDerivedFromOptionalValueConstructor` is not a template, and this
      used to
      cause an assertion failure in `valueOrConversionHasValue()` because
      `F.getTemplateSpecializationArgs()` returns null.
      
      (This is modeled after the `MaybeAlign(Align Value)` constructor, which
      similarly causes an assertion failure in the analysis when assigning an
      `Align`
      to a `MaybeAlign`.)
      
      To fix this, we can simply look at the type of the destination type
      which we're
      constructing or assigning to (instead of the function template
      argument), and
      this not only fixes this specific case but actually simplifies the
      implementation.
      
      I've added some additional tests for the case of assigning to a nested
      optional
      because we didn't have coverage for these and I wanted to make sure I
      didn't
      break anything.
      ae280281
    • Andrzej Warzyński's avatar
      [mlir][vector] Add support for scalable vectors to VectorLinearize (#86786) · d3aa92ed
      Andrzej Warzyński authored
      Adds support for scalable vectors to patterns defined in
      VectorLineralize.cpp.
      
      Linearization is disable in 2 notable cases:
        * vectors with more than 1 scalable dimension (we cannot represent
          vscale^2),
        * vectors initialised with arith.constant that's not a vector splat
          (such arith.constant Ops cannot be flattened).
      d3aa92ed
    • Ed Maste's avatar
      [libc++] Switch FreeBSD to C++26 (#86658) · ffed554f
      Ed Maste authored
      ffed554f
    • Andrzej Warzyński's avatar
      [mlir][linalg] Add e2e test for linalg.mmt4d + pack/unpack (#84964) · d7753989
      Andrzej Warzyński authored
      This is a follow-up for #81790. This patch basically extends:
      
        * test/Integration/Dialect/Linalg/CPU/mmt4d.mlir
      
      with pack/unpack ops so that to overall computation is a matrix
      multiplication (as opposed to linalg.mmt4d). For comparison (and to make
      it easier to verify correctness), linalg.matmul is also included in the
      test.
      d7753989
    • Alexey Bataev's avatar
      [SLP]Add better minbitwidth analysis for udiv/urem instructions. · d7975c9d
      Alexey Bataev authored
      Adds improved bitwidth analysis for udiv/urem instructions. The
      analysis is based on similar version in InstCombiner.
      
      Reviewers: RKSimon
      
      Reviewed By: RKSimon
      
      Pull Request: https://github.com/llvm/llvm-project/pull/85928
      d7975c9d
    • Alfie Richards's avatar
    • Yingwei Zheng's avatar
      [OCaml] Fix buildbot failure caused by caa22582. NFC. · a515ea55
      Yingwei Zheng authored
      Closes #86944.
      a515ea55
    • Akira Hatanaka's avatar
      [CodeGen][arm64e] Add methods and data members to Address, which are needed to... · 84780af4
      Akira Hatanaka authored
      [CodeGen][arm64e] Add methods and data members to Address, which are needed to authenticate signed pointers (#86923)
      
      To authenticate pointers, CodeGen needs access to the key and
      discriminators that were used to sign the pointer. That information is
      sometimes known from the context, but not always, which is why `Address`
      needs to hold that information.
      
      This patch adds methods and data members to `Address`, which will be
      needed in subsequent patches to authenticate signed pointers, and uses
      the newly added methods throughout CodeGen. Although this patch isn't
      strictly NFC as it causes CodeGen to use different code paths in some
      cases (e.g., `mergeAddressesInConditionalExpr`), it doesn't cause any
      changes in functionality as it doesn't add any information needed for
      authentication.
      
      In addition to the changes mentioned above, this patch introduces class
      `RawAddress`, which contains a pointer that we know is unsigned, and
      adds several new functions for creating `Address` and `LValue` objects.
      
      This reapplies d9a685a9, which was
      reverted because it broke ubsan bots. There seems to be a bug in
      coroutine code-gen, which is causing EmitTypeCheck to use the wrong
      alignment. For now, pass alignment zero to EmitTypeCheck so that it can
      compute the correct alignment based on the passed type (see function
      EmitCXXMemberOrOperatorMemberCallExpr).
      84780af4
    • Amy Kwan's avatar
      [AIX][TLS] Produce a faster local-exec access sequence for the "aix-small-tls"... · a3efc53f
      Amy Kwan authored
      [AIX][TLS] Produce a faster local-exec access sequence for the "aix-small-tls" global variable attribute (#83053)
      
      Similar to 3f46e545, this patch allows
      the backend to produce a faster access sequence for the local-exec TLS
      model, where loading from the TOC can be avoided, for local-exec TLS
      variables that are annotated with the "aix-small-tls" attribute.
      
      The expectation is for local-exec TLS variables to be set with this
      attribute through PGO. Furthermore, the optimized access sequence is
      only generated for local-exec TLS variables annotated with
      "aix-small-tls", only if they are less than ~32KB in size.
      a3efc53f
    • Rolf Morel's avatar
      [SCF][Transform] Add support for scf.for in LoopFuseSibling op (#81495) · eacda36c
      Rolf Morel authored
      Adds support for fusing two scf.for loops occurring in the same block.
      Uses the rudimentary checks already in place for scf.forall (like the
      target loop's operands being dominated by the source loop).
      
      - Fixes a bug in the dominance check whereby it was checked that values
      in the target loop themselves dominated the source loop rather than the
      ops that define these operands.
      - Renames the LoopFuseSibling op to LoopFuseSiblingOp.
      - Updates LoopFuseSiblingOp's description.
      - Adds tests for using LoopFuseSiblingOp on scf.for loops, including one
      which fails without the fix for the dominance check.
      - Adds tests checking the different failure modes of the dominance
      checker.
      - Adds test for case whereby scf.yield is automatically generated when
      there are no loop-carried variables.
      eacda36c