1. Jun 02, 2022
    • Scott Linder's avatar
      [AMDGPU][NFC] Refactor AMDGPUCallingConv.td · 2d43955c
      Scott Linder authored
      Rename CalleeSavedRegs defs to avoid being overly specific:
      
      * CSR_AMDGPU_AGPRs_32_255 => CSR_AMDGPU_AGPRs
      * CSR_AMDGPU_SGPRs_30_31 + CSR_AMDGPU_SGPRs_32_105 => CSR_AMDGPU_SGPRs
      * CSR_AMDGPU_SI_Gfx_SGPRs_4_29 + CSR_AMDGPU_SI_Gfx_SGPRs_64_105 =>
        CSR_AMDGPU_SI_Gfx_SGPRs
      * CSR_AMDGPU_HighRegs => CSR_AMDGPU
      * CSR_AMDGPU_HighRegs_With_AGPRs => CSR_AMDGPU_GFX90AInsts
      * CSR_AMDGPU_SI_Gfx_With_AGPRs => CSR_AMDGPU_SI_Gfx_GFX90AInsts
      
      Introduce a class RegMask to mark the cases where we use the
      CalleeSavedRegs class purely as an expedient way to produce a mask.
      Update the names of these masks to not mention "CSR". Other targets also
      seem to do this, so a reasonable alternative is to actually update
      table-gen to include a new class to do this explicitly, but the current
      approach seems harmless so I opted to just make it more explicit.
      
      Reviewed By: arsenm, sebastian-ne
      
      Differential Revision: https://reviews.llvm.org/D109008
      2d43955c
    • Mats Petersson's avatar
      [flang][OpenMP]Make omp.wsloop arguments appear in memory (#1277) · dc4bf2c3
      Mats Petersson authored
      As per issue #1196, the loop induction variable, which is an argument
      in the omp.wsloop operation, does not have a memory location, so when
      passed to a function or subroutine, the reference to the value is not
      a memory location, but the value of the induction variable. The callee
      function/subroutine is then trying to dereference memory at address 1
      or some other "not a good memory location".
      
      This is fixed by creating a temporary memory location and storing the
      value of the induction variable in that.
      
      Test fixes as a consequence of the changed code generated.
      
      Add checking for some of the omp-unstructured.f90 to check for alloca,
      store and load operations, to ensure the correct flow. Add a test
      for CYCLE inside a omp-do loop.
      
      Also convert to use -emit-fir in the omp-unstructrued, and make
      the symbol matching consistent in the omp-wsloop-variable test.
      
      Reviewed By: peixin
      
      Differential Revision: https://reviews.llvm.org/D126711
      dc4bf2c3
    • Matthias Braun's avatar
  2. Jun 01, 2022