Does every pure function have a branchless equivalent?
By pure function I understand a function that uses only its input values and no global state to produce the output.
By branchless function I understand a function that does not use if/else during its execution. A loop contains a branch with and unconditional jump. Constant loops can be unrolled.
As an example, here is the signum function:
function signum(x): if (x > 0) return 1; if (x < 0) return -1; return 0;
And here is a branchless version of the same function:
function signum(x): return (x > 0) - (x < 0);