- if (branch) {
- zero = beqi(_jit->pc.w, t3, 0);
- over = beqi(_jit->pc.w, t3, __WORDSIZE);
- done = jmpi(_jit->pc.w, 1);
- flush();
- patch_at(over, _jit->pc.w);
- /* underflow */
- if (sign)
- rshi(r0, t2, __WORDSIZE - 1);
- else
- movi(r0, 0);
- done_over = jmpi(_jit->pc.w, 1);
- /* zero */
- flush();
- patch_at(zero, _jit->pc.w);
- if (sign)
- rshi(r1, t2, __WORDSIZE - 1);
- else
- movi(r1, 0);
- flush();
- patch_at(done, _jit->pc.w);
- patch_at(done_over, _jit->pc.w);
- jit_unget_reg(s1);
- }
- else {
- /* zero? */
- if (sign)
- rshi(t0, t2, __WORDSIZE - 1);
- else
- movi(t0, 0);
- movzr(r1, t0, t3);
- /* underflow? */
- eqi(t1, t3, __WORDSIZE);
- movnr(r0, t0, t1);
- jit_unget_reg(s1);
- }