Code: ```c extern unsigned char array[256]; unsigned int foo() { unsigned int r = 0; for (int i = 255; i >= 0; --i) { r += array[i]; } return r; } ``` ``` foo: // @foo move r0, 0 move r1, -256 .LBB0_1: // =>This Inner Loop Header: Depth=1 not r2, r1 lbu r2, r2, array add r3, r1, 1 sub r4, r3, r1, ltu add r0, r0, r2 move r1, r3 jz r4, .LBB0_1 jump r23 ``` This is *not* ideal.
Code:
This is not ideal.