-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Combine DMA loads #144
Comments
There is already some related code there. This was added some while ago to do a similar job, but I am not sure whether it is still applied. Anyway, that might be a good point to start. |
@doe300 I have a question. Is there a way to find the instruction corresponded the local (for example, I want to get the instruction
|
In general, you can query If there is just one writer, |
The general memory access (before we know whether the memory area is lowered to a register, the VPM or accessed via TMU or DMA) is represented as
The VPM object required can be retrieved via the Does this information suffice or do you need a special instruction type to represent VPM accesses (e.g. for further processing)? |
I understand, thanks. |
When we compile following OpenCL code which calls
vload16
three times withvc4c --asm -O3 -o dma_loads.asm dma_loads.cl
, VC4C outputs the following assembly(dma_loads.txt
). This contains three DMA loads, but these can be combined into one DMA load.dma_loads.txt
I want to implement the combiner and think the method.
At each block in CFG and LLVM IR
vload16
(actually_Z7vload16jPU3AS1Kh
).vload16
.I think the checking regular intervals is challenging. The symbolic execution can be used.
Example
Collect
vload16
(and address variables)Addresses
%mul - %width
%mul
%mul + %width
These are regular intervals (
%width
), then these are combined (I should create new functiondma_load
andvpm_load
).The text was updated successfully, but these errors were encountered: