[LLVMdev] Disable loop unroll pass

Krzysztof Parzyszek kparzysz at codeaurora.org
Wed Nov 21 08:29:29 PST 2012


On 11/21/2012 10:31 AM, Ivan Llopard wrote:
>
> Does Hexagon provides the same loop support? How have you addressed this?

Yes, Hexagon has hardware support for loops: you set up the loop start 
address, number of iterations and indicate where the loop ends, and the 
hardware would execute the code repeatedly until the count goes down to 
zero.

I'm not aware of any specific changes that had been made to the 
bitcode-level loop unroller in connection with the hardware loop 
support.  I just glanced over the unrolling code and I didn't see 
anything that would be aimed at helping the hardware-based loop generation.

We have a pass in our backend that converts "normal" loops into 
hardware-based loops, and it can handle loops that have been unrolled 
(but not completely).  If a loop has been completely unrolled, it is a 
straight-line code and it will not be "re-rolled".

-Krzysztof

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, 
hosted by The Linux Foundation



More information about the llvm-dev mailing list