ocannl icon indicating copy to clipboard operation
ocannl copied to clipboard

Consider allowing multiple virtual tensors to share the same for loop

Open lukstafi opened this issue 2 years ago • 1 comments

In the initial implementation, we in effect assume without checking that for-loops only compute a single node. This is currently true in particular because we do not have for-loops in the high-level representation. But it is easy to extend the code to handle the general case: in virtual_llc, a call loop_proc ~inline_only:true should return a pair where one result is setters/fillers of the virtual node only, and the other the remaining ones.

lukstafi avatar May 01 '23 20:05 lukstafi

This will be mostly fixed soon, except for the case where multiple virtual tensors share the same for loop. It's because I'm introducing filtering of virtual / non-virtual getters & setters in cleanup_virtual_llc / inline_computation (mostly to account for late-identified non-virtual nodes). The code will be easy to extend to handle the general case, just not adding the complication yet as it's not needed.

lukstafi avatar May 03 '23 19:05 lukstafi