- OP(FILTER_OP_AND_DOUBLE):
- {
- struct logical_op *insn = (struct logical_op *) pc;
-
- /* If REG_R0 is 0, skip and evaluate to 0 */
- if ((reg[REG_R0].type == REG_DOUBLE && unlikely(reg[REG_R0].d == 0.0))
- || (reg[REG_R0].type == REG_S64 && unlikely(reg[REG_R0].v == 0))) {
- dbg_printf("Jumping to bytecode offset %u\n",
- (unsigned int) insn->skip_offset);
- next_pc = start_pc + insn->skip_offset;
- } else {
- next_pc += sizeof(struct logical_op);
- }
- PO;
- }
- OP(FILTER_OP_OR_DOUBLE):
- {
- struct logical_op *insn = (struct logical_op *) pc;
-
- /* If REG_R0 is nonzero, skip and evaluate to 1 (in double) */
- if ((reg[REG_R0].type == REG_DOUBLE && unlikely(reg[REG_R0].d != 0.0))
- || (reg[REG_R0].type == REG_S64 && unlikely(reg[REG_R0].v != 0))) {
- reg[REG_R0].d = 1.0;
- dbg_printf("Jumping to bytecode offset %u\n",
- (unsigned int) insn->skip_offset);
- next_pc = start_pc + insn->skip_offset;
- } else {
- next_pc += sizeof(struct logical_op);
- }
- PO;
- }