argon icon indicating copy to clipboard operation
argon copied to clipboard

CSE / Scheduling issue

Open dkoeplin opened this issue 8 years ago • 0 comments

Given IR that looks something like:

x1 = OpA(...)
...
x2 = OpB(x1,...)

In a transformer, if we insert an operation x3 prior to x1 which also uses x1 due to CSE:

 x3 = OpC(x1,...)
 x1 = OpA(...)
 ...
 x2 = OpB(x1,...)

Scheduling appears to leave it in this order, including during code generation, causing issues with generated code. Not clear if this is a new issue with scheduling or one previously undiscovered in LMS.

Fix should revise scheduling to move x1 before all of its uses

dkoeplin avatar Feb 08 '17 12:02 dkoeplin