…rective This makes accessing directive components, such as directive name or the list of clauses simpler and more uniform across different directives. It also makes the parser simpler, since it reuses existing parsing functionality. The changes are scattered over a number of files, but they all share the same nature: - getting the begin/end directive from OpenMPLoopConstruct, - getting the llvm::omp::Directive enum, and the source location, - getting the clause list.
24 lines
542 B
Fortran
24 lines
542 B
Fortran
! RUN: %flang_fc1 -fdebug-unparse -fopenmp %s | FileCheck --ignore-case %s
|
|
! RUN: %flang_fc1 -fdebug-dump-parse-tree -fopenmp %s | FileCheck --check-prefix="PARSE-TREE" %s
|
|
|
|
subroutine openmp_tiles(x)
|
|
|
|
integer, intent(inout)::x
|
|
|
|
!CHECK: !$omp tile
|
|
!$omp tile
|
|
!CHECK: do
|
|
do x = 1, 100
|
|
call F1()
|
|
!CHECK: end do
|
|
end do
|
|
!CHECK: !$omp end tile
|
|
!$omp end tile
|
|
|
|
!PARSE-TREE: OpenMPConstruct -> OpenMPLoopConstruct
|
|
!PARSE-TREE: OmpBeginLoopDirective
|
|
!PARSE-TREE: OmpDirectiveName -> llvm::omp::Directive = tile
|
|
|
|
END subroutine openmp_tiles
|
|
|