You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It seems that for imperfect loop nests, polymer-opt can end up generating IR that invokes functions representing statements with parameters that may cause out-of-bounds memory accesses. For example, when invoking polymer-opt -reg2mem -extract-scop-stmt -pluto-opt kernel.cgeist.mlir -o kernel.polymer.mlir --allow-unregistered-dialect on the following IR saved as kernel.mlir:
The 448th invocation of S1 by this IR is with %arg1 = 2, %arg4 = 21, and %arg5 = 418, which causes %arg3 to be indexed with a negative value, ultimately resulting in a segmentation fault.
I experienced similar issues with imperfect loop nests directly with pluto in the past and this may be related. Could somebody confirm that this is indeed a bug in pluto? Any suggestions for fixes or workarounds are welcome, too.
Thanks!
The text was updated successfully, but these errors were encountered:
It seems that for imperfect loop nests,
polymer-opt
can end up generating IR that invokes functions representing statements with parameters that may cause out-of-bounds memory accesses. For example, when invokingpolymer-opt -reg2mem -extract-scop-stmt -pluto-opt kernel.cgeist.mlir -o kernel.polymer.mlir --allow-unregistered-dialect
on the following IR saved askernel.mlir
:polymer-opt
generates:The 448th invocation of
S1
by this IR is with%arg1 = 2
,%arg4 = 21
, and%arg5 = 418
, which causes%arg3
to be indexed with a negative value, ultimately resulting in a segmentation fault.This behavior can be reproduced with the code from this repository with a minimal non-working example:
Compiling the kernel with plain
cgeist
and without any polymer optimizations yields the expected results:which are the same as the results produced by a binary compiled using a plain C compiler:
I experienced similar issues with imperfect loop nests directly with
pluto
in the past and this may be related. Could somebody confirm that this is indeed a bug inpluto
? Any suggestions for fixes or workarounds are welcome, too.Thanks!
The text was updated successfully, but these errors were encountered: