Skip to content

[flang][openmp] Please address not yet implemented: Unhandled clause reduction in omp.simd operation #144290

Open
@sscalpone

Description

@sscalpone

A widely-used close-source app uses OpenMP SIMD reductions. It would be great if this feature was implemented. Thanks!

module foo
  implicit none

contains
  subroutine bar(arr,n_elem)
    integer i
    integer n_elem
    double precision arr(:),resul

    resul=0d0
 !$OMP SIMD REDUCTION(+:resul)
    do i=1,n_elem
       resul=resul+arr(i)*i
    enddo

  end subroutine bar
end module foo
% flang -fopenmp -c foo.f90
flang-21: warning: OpenMP support in flang is still experimental [-Wexperimental-option]
error: loc(".../foo.f90":11:8): not yet implemented: Unhandled clause reduction in omp.simd operation
error: loc(".../foo.f90":11:8): LLVM Translation failed for operation: omp.simd
error: failed to create the LLVM module

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions