[all-commits] [llvm/llvm-project] d6ba09: [MLIR][OpenMP] Prevent composite omp.simd related ...

Sergio Afonso via All-commits all-commits at lists.llvm.org
Fri Oct 25 05:17:21 PDT 2024


  Branch: refs/heads/users/skatrak/composite-blockargs-01-mlir
  Home:   https://github.com/llvm/llvm-project
  Commit: d6ba0952b42a23af90ec549b4f764a34b90df2aa
      https://github.com/llvm/llvm-project/commit/d6ba0952b42a23af90ec549b4f764a34b90df2aa
  Author: Sergio Afonso <safonsof at amd.com>
  Date:   2024-10-25 (Fri, 25 Oct 2024)

  Changed paths:
    M mlir/lib/Target/LLVMIR/Dialect/OpenMP/OpenMPToLLVMIRTranslation.cpp
    M mlir/test/Target/LLVMIR/openmp-reduction.mlir

  Log Message:
  -----------
  [MLIR][OpenMP] Prevent composite omp.simd related crashes

This patch updates the translation of `omp.wsloop` with a nested `omp.simd` to
prevent uses of block arguments defined by the latter from triggering null
pointer dereferences.

This happens because the inner `omp.simd` operation representing composite `do
simd` constructs is currently skipped and not translated, but this results in
block arguments defined by it not being mapped to an LLVM value. The proposed
solution is to map these block arguments to the LLVM value associated to the
corresponding operand, which is defined above.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list