target/whirl.c
static void move_to_reg(WhirlCodeSegment *segment, RingState *state, Reg reg) {
    generate_op_command(segment, state, OP_ONE);

    for (int i = 0; i < (int) reg + REG_START_POS; i++) {
        generate_op_command(segment, state, OP_DADD);
    }
}
// Starting from the first memory position, move to a specific register,
// preserving the value in the math ring
Starting from the first memory position, move to a specific register,
preserving the value in the math ring
Starting from the first memory position move to a specific register preserving the value in the math ring
static void move_to_reg(WhirlCodeSegment *segment, RingState *state, Reg reg) {
    generate_op_command(segment, state, OP_ONE);
    for (int i = 0; i < (int) reg + REG_START_POS; i++) {
        generate_op_command(segment, state, OP_DADD);
    }
}
static void move_to_reg ( WhirlCodeSegment * segment , RingState * state , Reg reg ) { generate_op_command ( segment , state , OP_ONE ) ; for ( int i = 0 ; i < ( int ) reg + REG_START_POS ; i ++ ) { generate_op_command ( segment , state , OP_DADD ) ; } }
Starting from the first memory position, move to a specific register,
preserving the value in the math ring
Starting from the first memory position move to a specific register preserving the value in the math ring