Browse Source

- removed redundant code for general purpose to general purpose transfer from tcgmos6502.a_load_reg_reg (this is handled by emit_mov now)

Nikolay Nikolov 1 year ago
parent
commit
670069d02a
1 changed files with 1 additions and 16 deletions
  1. 1 16
      compiler/mos6502/cgcpu.pas

+ 1 - 16
compiler/mos6502/cgcpu.pas

@@ -1676,22 +1676,7 @@ unit cgcpu;
          if tcgsize2size[fromsize]>tcgsize2size[tosize] then
            fromsize:=tosize;
 
-         if is_6502_general_purpose_register(reg1) and is_6502_general_purpose_register(reg2) then
-           begin
-             if not (fromsize in [OS_8,OS_S8]) or not (tosize in [OS_8,OS_S8]) then
-               internalerror(2024040704);
-             if (reg1=NR_A) and (reg2=NR_X) then
-               list.Concat(taicpu.op_none(A_TAX))
-             else if (reg1=NR_A) and (reg2=NR_Y) then
-               list.Concat(taicpu.op_none(A_TAY))
-             else if (reg1=NR_X) and (reg2=NR_A) then
-               list.Concat(taicpu.op_none(A_TXA))
-             else if (reg1=NR_Y) and (reg2=NR_A) then
-               list.Concat(taicpu.op_none(A_TYA))
-             else
-               internalerror(2024040705);
-           end
-         else if (tcgsize2size[tosize]=tcgsize2size[fromsize]) or (fromsize in [OS_8,OS_16,OS_32]) then
+         if (tcgsize2size[tosize]=tcgsize2size[fromsize]) or (fromsize in [OS_8,OS_16,OS_32]) then
            begin
              if reg1<>reg2 then
                for i:=1 to tcgsize2size[fromsize] do