Dear all,
- is it possible to force the compiler through a special flag (whether ARM CC, or ARM gnu toolchain) to use predication instead of branch instruction throughout the whole binary.?
- Suppose that in an Out of order processor (such as the A15) the predicated instruction and the instruction on which the predication depends are both in-flight (in the pipeline) and it happens that the predicated instruction finishes its computation before the result of the predication is forwarded to the predicated instruction, does the predicated instruction wait in the reorder buffer until it receives the predication result where it commits to the architected state or not correspondingly.
Thank you so much.
I will add to the comments above that a good practice is to use the --cpu option on your compiler command lines. This ensures that the compiler takes into consideration the micro-architecture of your particular target. You may find that the assembly code generated for one device may be different than the code for a different target. For example, the conditional execution of instructions may be less efficient that using branch instructions in complex super-scalar out-of-order pipelines like that of the Cortex-A15 that have advanced branch prediction logic. Nonetheless, the functional behavior of the code will be correct.