Skip to content

Commit

Permalink
Scalarize every loop to ensure nothing breaks in NEMO - Revert this l…
Browse files Browse the repository at this point in the history
…ater
  • Loading branch information
LonelyCat124 committed Jan 25, 2025
1 parent ef3cd34 commit 6d8bff5
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions examples/nemo/scripts/omp_gpu_trans.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@
Loop, Routine, Directive, Assignment, OMPAtomicDirective)
from psyclone.psyir.transformations import OMPTargetTrans
from psyclone.transformations import OMPDeclareTargetTrans, TransformationError
# TODO REMOVE
from psyclone.transformations import ScalarizationTrans

PROFILING_ENABLED = False

Expand Down Expand Up @@ -93,6 +95,11 @@ def trans(psyir):
hoist_expressions=True
)

#TODO REMOVE
scalartrans = ScalarizationTrans()
for loop in subroutine.walk(Loop):
scalartrans.apply(loop)

# Thes are functions that are called from inside parallel regions,
# annotate them with 'omp declare target'
if subroutine.name.lower().startswith("sign_"):
Expand Down

0 comments on commit 6d8bff5

Please sign in to comment.