forked from pfaure/CrossAssembleur
Patch LOADI STOREI
This commit is contained in:
parent
78216ace0a
commit
a119a968a8
1 changed files with 2 additions and 2 deletions
4
as.y
4
as.y
|
@ -109,13 +109,13 @@ Instruction : tWR tNB tNB {increment_time();
|
||||||
int added_instruction = 0;
|
int added_instruction = 0;
|
||||||
int reg_dest = get_reg_write($2, &added_instruction);
|
int reg_dest = get_reg_write($2, &added_instruction);
|
||||||
int reg_addr = get_reg_read($3, &added_instruction);
|
int reg_addr = get_reg_read($3, &added_instruction);
|
||||||
add_instruction(LOADI, reg_dest, reg_addr, 0);
|
add_instruction(STOREI, reg_dest, reg_addr, 0);
|
||||||
new_instruction(added_instruction + 1);};
|
new_instruction(added_instruction + 1);};
|
||||||
Instruction : tREAD tNB tNB {increment_time();
|
Instruction : tREAD tNB tNB {increment_time();
|
||||||
int added_instruction = 0;
|
int added_instruction = 0;
|
||||||
int reg_addr = get_reg_read($2, &added_instruction);
|
int reg_addr = get_reg_read($2, &added_instruction);
|
||||||
int reg_value = get_reg_read($3, &added_instruction);
|
int reg_value = get_reg_read($3, &added_instruction);
|
||||||
add_instruction(STOREI, reg_addr, reg_value, 0);
|
add_instruction(LOADI, reg_addr, reg_value, 0);
|
||||||
new_instruction(added_instruction + 1);};
|
new_instruction(added_instruction + 1);};
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue