If module imports are used to define temporary array sizes deep in a call-tree, these variables might be undefined in intermediate layers when the temporaries are hoisted up to the driver. This should be taken care of by the transformation, possibly by storing all array size related module imports in item.trafo_data, and subsequently appending these imports as necessary to subroutine.spec as we move up the call-tree.
If module imports are used to define temporary array sizes deep in a call-tree, these variables might be undefined in intermediate layers when the temporaries are hoisted up to the driver. This should be taken care of by the transformation, possibly by storing all array size related module imports in
item.trafo_data
, and subsequently appending these imports as necessary tosubroutine.spec
as we move up the call-tree.