A continuation of the thread "RP2350 PIO DMA performance question". viewtopic.php?t=375095
(If necessary a moderator can unlock the original one instead, if the forum policy allows that. Or it can continue here.)
viewtopic.php?t=375095#p2258145
The compiler shows "Error: branch out of range" when attempting to branch to a earlier label.
I am curious to try other methods to make fast response either using PIO + DMA / CPU, including the RISC-V Hazard3 core instead.
(If necessary a moderator can unlock the original one instead, if the forum policy allows that. Or it can continue here.)
viewtopic.php?t=375095#p2258145
https://devblogs.microsoft.com/oldnewth ... /?p=105311 :I think that CPU polling loop can be made tighter and smoother by using CBZ in assembly, especially on Cortex-M33.
So it seems CBZ / CBNZ can't be used to make a two instruction loop on RP2350, because those instructions can only branch forward. Unless there is a way to make PC increment backwards with every instruction...
cbz Rn, label ; branch if Rn == 0
cbnz Rn, label ; branch if Rn != 0
These are 16-bit instructions which are available only for low registers, and they are capable only of branching forward by up to 126 bytes.¹
The compiler shows "Error: branch out of range" when attempting to branch to a earlier label.
I am curious to try other methods to make fast response either using PIO + DMA / CPU, including the RISC-V Hazard3 core instead.
Statistics: Posted by wisi — Fri Dec 26, 2025 11:59 am — Replies 1 — Views 43