From 54615e34d4b41ca3a0fb6fdb3913aa1cb5e15e2e Mon Sep 17 00:00:00 2001 From: xnpster Date: Wed, 1 Oct 2025 18:54:55 +0300 Subject: [PATCH] REMOVE_DIST_ARRAYS_FROM_IO: use more general isSgVarListDeclStmt and isSgNestedVarListDeclStmt functions --- .../ReplaceArraysInIO/replace_dist_arrays_in_io.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Transformations/ReplaceArraysInIO/replace_dist_arrays_in_io.cpp b/src/Transformations/ReplaceArraysInIO/replace_dist_arrays_in_io.cpp index 021e797..248cea2 100644 --- a/src/Transformations/ReplaceArraysInIO/replace_dist_arrays_in_io.cpp +++ b/src/Transformations/ReplaceArraysInIO/replace_dist_arrays_in_io.cpp @@ -19,7 +19,7 @@ using std::pair; static inline bool isArrayDeclaration(SgStatement* st) { - return isSgDeclarationStatement(st) || st->variant() == DIM_STAT || st->variant() == COMM_STAT; + return isSgDeclarationStatement(st) || isSgVarListDeclStmt(st) || isSgNestedVarListDeclStmt(st); } static SgExpression* findExprWithVariant(SgExpression* exp, int variant) @@ -855,7 +855,7 @@ void replaceDistributedArraysInIO(vector& regions, if (last_io_bound == curr_stmt) // always true last_io_bound = curr_stmt->lexPrev(); } - + curr_stmt = curr_stmt->lexNext(); } }