1. Feb 11, 2023
    • Johannes Doerfert's avatar
      [Attributor][NFCI] Avoid a temporary vector and exit early · 8bc0bee2
      Johannes Doerfert authored
      This change simply avoids the temporary vector and processes the elments
      right away.
      8bc0bee2
    • Louis Dionne's avatar
      [libc++][NFC] Reorganize hash.h · 91e38bc7
      Louis Dionne authored
      - Add missing _LIBCPP_HIDE_FROM_ABI
      - Implement inline functions in the class to simplify the code
      - Add missing `const` to `operator()`
      - Move _LIBCPP_DISABLE_UBSAN_UNSIGNED_INTEGER_CHECK to the usual location for function attributes
      
      Differential Revision: https://reviews.llvm.org/D143668
      91e38bc7
    • Michael Buch's avatar
      [lldb][DWARFASTParserClang] Attach linkage name to ctors/dtors if missing · b296ddd9
      Michael Buch authored
      **Summary**
      
      This patch addresses the case where we have a `DW_AT_external`
      subprogram for a constructor (and/or destructor) that doesn't carry
      a `DW_AT_linkage_name` attribute. The corresponding DIE(s) that
      represent the definition will have a linkage name, but if the name
      contains constructs that LLDBs fallback mechanism for guessing mangled
      names to resolve external symbols doesn't support (e.g., abi-tags)
      then we end up failing to resolve the function call.
      
      We address this by trying to find the linkage name before we create
      the constructor/destructor decl, which will get attached using
      an `AsmLabelAttr` to make symbol resolution easier.
      
      **Testing**
      
      * Added API test
      
      Differential Revision: https://reviews.llvm.org/D143652
      b296ddd9
    • Michael Buch's avatar
      Reland "[llvm][dsymutil] Add DW_TAG_imported_declaration to accelerator table" · b8ef007f
      Michael Buch authored
      This relands the commit previously reverted in
      `8570bee5` due to failures on linux.
      
      The problem was that the test executable was built with absolute
      OSO prefix paths. This re-commit adds a modified version of the
      executable that strips the absolute OSO prefix paths and makes
      sure the test appends the OSO prefix appropriately (via the appropriate
      dsymutil flags).
      
      Differential Revision: https://reviews.llvm.org/D143458
      b8ef007f
    • Florian Hahn's avatar
      [ConstraintElim] Update getLastConstraint to return to last row. (NFC) · 94976800
      Florian Hahn authored
      The current code incorrectly returned the first instead of the last row.
      This fixes the debug output.
      94976800
    • Slava Zakharin's avatar
      [flang] Fixed selective TargetRewrite. · ff8742df
      Slava Zakharin authored
      Some conversions were still happening under no-complex/character-conversion
      options. This change fixes that and adds a LIT test.
      
      Differential Revision: https://reviews.llvm.org/D143685
      ff8742df
    • Markus Böck's avatar
      [mlir][OpenMP] Add support for using Opaque Pointers in the OpenMP Dialect · 81767f52
      Markus Böck authored
      The current OpenMP implementation assumes the use of typed pointers (or rather typed pointer like types). Given the support for typed pointers in LLVM is now pending removal, the OpenMP Dialect should be able to support opaque pointers as well, given that any users of it must lower OpenMP through the LLVM Dialect.
      
      This patch fixes the above and adds support for using LLVM opaque pointers with the OpenMP dialect. This is implemented by making all related code not make use of the element type of pointer arguments. The few (one) op requiring a pointer element type now use an explicit `TypeAttr` for representing the element type.
      More concretely, the list of changes are:
      * `omp.atomic.read` now has an extra `TypeAttr` (also in syntax) which is the element type of the values read and stored from the operands
      * `omp.reduction` now has an type argument in the syntax for both the accmulator and operand since the operand type can no longer be inferred from the accumulator
      * `OpenMPToLLVMIRTranslation.cpp` was rewritten to never query element types of pointers
      * Adjusted the verifier to be able to handle pointers without element types
      
      Differential Revision: https://reviews.llvm.org/D143582
      81767f52
    • Markus Böck's avatar
      [mlir][Async] Add option to LLVM lowering to use opaque pointers · 2ca46421
      Markus Böck authored
      Part of https://discourse.llvm.org/t/rfc-switching-the-llvm-dialect-and-dialect-lowerings-to-opaque-pointers/68179
      
      This patch adds the pass option 'use-opaque-pointers' to allow the dialect conversion from async to LLVM to create LLVM opaque pointers instead of typed pointers.
      The gist of the changes boil down to having to propagate the choice of whether opaque or typed pointers should be used, to various helper functions that then either create typed pointers or opaque pointers.
      This sadly creates a bit of a code duplication in comparison to other patches in this series, which I think is mostly unavoidable however, since a lot of the patterns in this lowering require the use of the AsyncTypeConverter, instead of the LLVMTypeConverter.
      
      Besides that, the tests have been converter to opaque pointers with one file with typed pointer support having been created as regression tests.
      
      Differential Revision: https://reviews.llvm.org/D143661
      2ca46421
    • Daniel Grumberg's avatar
      [clang] [extract-api] Don't crash for category in libclang APIs · 7da2d644
      Daniel Grumberg authored
      Remove failure conditions for categories in libclang and return empty
      content instead.
      
      Differential Revision: https://reviews.llvm.org/D142101
      7da2d644
    • Florian Hahn's avatar
      [ConstraintElim] Improve debug test to show removed constraints (NFC). · 57606bb3
      Florian Hahn authored
      The current checks show incorrect debug output.
      57606bb3
    • Tom Eccles's avatar
      [mlir] Add function for checking if a block is inside a loop · 81a79ee4
      Tom Eccles authored
      This function returns whether a block is nested inside of a loop. There
      can be three kinds of loop:
        1) The block is nested inside of a LoopLikeOpInterface
        2) The block is nested inside another block which is in a loop
        3) There is a cycle in the control flow graph
      
      This will be useful for Flang's stack arrays pass, which moves array
      allocations from the heap to the stack. Special handling is needed when
      allocations occur inside of loops to ensure additional stack space is
      not allocated on each loop iteration.
      
      Differential Revision: https://reviews.llvm.org/D141401
      81a79ee4
  2. Feb 10, 2023