[all-commits] [llvm/llvm-project] 07a40b: [mlir][OpenMP] Fix taskloop outlined step handling...
Tom Eccles via All-commits
all-commits at lists.llvm.org
Tue Apr 7 08:51:25 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 07a40b33e513c85061a4204b579a8cd8a60e6507
https://github.com/llvm/llvm-project/commit/07a40b33e513c85061a4204b579a8cd8a60e6507
Author: Tom Eccles <tom.eccles at arm.com>
Date: 2026-04-07 (Tue, 07 Apr 2026)
Changed paths:
M llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp
M mlir/test/Target/LLVMIR/openmp-taskloop-cancel.mlir
M mlir/test/Target/LLVMIR/openmp-taskloop-cancellation-point.mlir
M mlir/test/Target/LLVMIR/openmp-taskloop-collapse.mlir
M mlir/test/Target/LLVMIR/openmp-taskloop-no-context-struct.mlir
A mlir/test/Target/LLVMIR/openmp-taskloop-outer-bounds.mlir
M mlir/test/Target/LLVMIR/openmp-taskloop.mlir
Log Message:
-----------
[mlir][OpenMP] Fix taskloop outlined step handling (#190198)
The outlined taskloop preheader still used the original function's
casted step value when computing the canonical loop trip count. When
lb/ub/step were defined outside the taskloop body, the outlined function
ended up referring to an instruction from another function, which
crashed LLVM IR verification and finalization.
Reload the task step from the outlined task shareds, alongside lb and
ub, and use that value for the trip-count division. Update the MLIR
taskloop checks and add a regression for outer-scope variable bounds.
Fortran reproducer:
```
subroutine test(lb, ub, step)
integer :: i, lb, ub, step
!$omp taskloop
do i=lb,ub,step
call do_something(i)
enddo
!$omp end taskloop
end subroutine
```
Assisted-by: codex
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