Skip to content

Commit 7b217d2

Browse files
FabioLuporiniEdCaunt
authored andcommitted
compiler: Fixup nbytes-avail-mapper
1 parent cd9058b commit 7b217d2

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

devito/operator/operator.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1343,7 +1343,11 @@ def nbytes_avail_mapper(self):
13431343
continue
13441344
try:
13451345
if i._mem_mapped:
1346-
mapper[device_layer] -= i.nbytes
1346+
try:
1347+
v = self[i.name]._obj.nbytes
1348+
except AttributeError:
1349+
v = i.nbytes
1350+
mapper[device_layer] -= v
13471351
except AttributeError:
13481352
pass
13491353

0 commit comments

Comments
 (0)