nod-ai / iree-amd-aie

IREE plugin repository for the AMD AIE accelerator
Apache License 2.0
69 stars 30 forks source link

Multicore convolution #821

Open newling opened 1 month ago

newling commented 1 month ago

Convolutions currently target a single AIE core. This is because targetting multiple cores results in

error: 'aie.memtile_dma' op could not find and assign a valid BD id

See https://github.com/nod-ai/iree-amd-aie/pull/789

This task is to make the required changes to be able to compile to multiple AIE cores.

newling commented 1 month ago

Update:

I can use a full column of 4 AIE cores with (for conv2d)

 tileSizeLevel0 = {1, 1, OW, 4*OC, 0, 0, 0}; 
 tileSizeLevel1 = {1, 1, OW, OC, 0, 0, 0}; 

The above error message is then observed when this is extended to multiple columns:

 tileSizeLevel0 = {1, 2, OW, 4*OC, 0, 0, 0}; 
 tileSizeLevel1 = {1, 1, OW, OC, 0, 0, 0}; 
newling commented 1 month ago

Update:

The problem is that there are these dma start ops which have "index" gte 6:

  %13 = aie.dma_start(S2MM, 7, ^bb40, ^bb42)   

They are created in lower-to-aie.