1. Jan 06, 2024
    • Joseph Huber's avatar
      [ELF] Again attempt to fix test on BE architectures · c2f5e435
      Joseph Huber authored
      Summary:
      This formats something according to the style, and again attempts to fix
      this failing on the BE PPC test. Sorry for the spam, these commits are
      the only way I can check it because the failure isn't local.
      c2f5e435
    • Erich Keane's avatar
      [OpenACC] Implement 'default' clause parsing. (#77002) · 0e8b09c4
      Erich Keane authored
      A simple clause that is permitted on a few different constructs,
        'default' takes a required parameter of either 'none' or 'present'.
        This patch implements parsing for it.
      0e8b09c4
    • Yingwei Zheng's avatar
      [InstCombine] Canonicalize `switch(X << C)` into `switch(X)` (#77068) · 1259c051
      Yingwei Zheng authored
      This patch canonicalizes `switch(X << C)` to `switch(X)`. If the shift
      may wrap, an and instruction will be created to mask out all of the
      shifted bits.
      Alive2: https://alive2.llvm.org/ce/z/wSsL5y
      
      NOTE: We can relax the one-use constraint. But I don't see any benefit
      in my benchmark.
      
      Compile-time impact:
      http://llvm-compile-time-tracker.com/compare.php?from=a776740d6296520b8bde156aa3f8d9ecb32cddd9&to=6dd783b9f90ae5f258102d732953567d7e317c02&stat=instructions%3Au
      
      |stage1-O3|stage1-ReleaseThinLTO|stage1-ReleaseLTO-g|stage1-O0-g|stage2-O3|stage2-O0-g|stage2-clang|
      |--|--|--|--|--|--|--|
      |-0.00%|+0.01%|-0.02%|-0.01%|+0.02%|-0.00%|+0.01%|
      1259c051
    • Greg Clayton's avatar
      [lldb] Fix expressions that involve nested structs/classes/unions. (#77029) · e42edb55
      Greg Clayton authored
      The LLDB expression parser relies on using the external AST source
      support in LLDB. This allows us to find a class at the root namespace
      level, but it wouldn't allow us to find nested classes all of the time.
      When LLDB finds a class via this mechanism, it would be able to complete
      this class when needed, but during completion, we wouldn't populate
      nested types within this class which would prevent us from finding
      contained types when needed as clang would expect them to be present if
      a class was completed. When we parse a type for a class, struct or
      union, we make a forward declaration to the class which can be
      completed. Now when the class is completed, we also add any contained
      types to the class' declaration context which now allows these types to
      be found. If we have a struct that contains a struct, we will add the
      forward declaration of the contained structure which can be c ompleted
      later. Having this forward de...
      e42edb55
    • Joseph Huber's avatar
      [ELF] Attempt to fix test on big endian architectures · dfe9bb4d
      Joseph Huber authored
      Summary:
      This test fails because AMDGPU has a check for little-endianness before
      returning the architecture. This test attempts to force the type to be
      considered little-endian for the purpose of this test.
      dfe9bb4d
    • Craig Topper's avatar
      [RISCV] Don't call use_nodbg_operands for physical registers in... · 4dd5d967
      Craig Topper authored
      [RISCV] Don't call use_nodbg_operands for physical registers in RISCVOptWInstrs hasAllNBitUsers. (#77032)
      
      The ADDIW in the new test case was incorrectly removed due to
      incorrectly following the x10 register from the return value back to the
      argument. This is due to use_nodbg_operands returning every instruction
      that uses a physical register regardless of the data flow.
      4dd5d967
    • Mircea Trofin's avatar
      [mlgo] Fix post PR #76919 · c49965b9
      Mircea Trofin authored
      Relaxed a bit the opcode checks to make the test less sensitive to
      changes resulting in opcode numbering.
      c49965b9
    • Joseph Huber's avatar
      [ELF][Obvious] Remove unused CUDA OS/ABI struct · 59567e71
      Joseph Huber authored
      Summary:
      This did not need a separate struct because it is not past the
      "architecture specific" ones in the identifier. This was accidentally
      left when it was added somewhere else and caused unused variable
      warnings.
      59567e71
    • Joseph Huber's avatar
      [ELF] Attempt to set the OS when using 'makeTriple()' (#76992) · 3b337bbc
      Joseph Huber authored
      Summary:
      This patch fixes up the `makeTriple()` interface to emit append the
      operating system information when it is readily avaialble from the ELF.
      The main motivation for this is so the GPU architectures can be easily
      identified correctly when given and ELF. E.g. we want
      `amdgpu-amd-amdhsa` as the output and not `amdgpu--`.
      
      This required adding support for the CUDA OS/ABI, which is easily found
      to be `0x33` when using `readelf`.
      3b337bbc
    • Nick Desaulniers's avatar
      [libc] fix -Warray-bounds in block_offset (#77001) · 5352ce32
      Nick Desaulniers authored
      GCC reports an instance of -Warray-bounds in block_offset.  Reimplement
      block_offset in terms of memcpy_inline which was created to avoid this
      diagnostic. See the linked issue for the full trace of diagnostic.
      
      Fixes: https://github.com/llvm/llvm-project/issues/76877
      5352ce32
  2. Jan 05, 2024