Przeglądaj źródła

- removed code not used for years

git-svn-id: trunk@43575 -
florian 5 lat temu
rodzic
commit
9e307f5c3a
1 zmienionych plików z 0 dodań i 85 usunięć
  1. 0 85
      compiler/i386/aoptcpu.pas

+ 0 - 85
compiler/i386/aoptcpu.pas

@@ -160,91 +160,6 @@ unit aoptcpu;
                 A_MOVSX,
                 A_MOVZX :
                   Result:=OptPass1Movx(p);
-(* should not be generated anymore by the current code generator
-                A_POP:
-                  begin
-                    if target_info.system=system_i386_go32v2 then
-                    begin
-                      { Transform a series of pop/pop/pop/push/push/push to }
-                      { 'movl x(%esp),%reg' for go32v2 (not for the rest,   }
-                      { because I'm not sure whether they can cope with     }
-                      { 'movl x(%esp),%reg' with x > 0, I believe we had    }
-                      { such a problem when using esp as frame pointer (JM) }
-                      if (taicpu(p).oper[0]^.typ = top_reg) then
-                        begin
-                          hp1 := p;
-                          hp2 := p;
-                          l := 0;
-                          while getNextInstruction(hp1,hp1) and
-                                (hp1.typ = ait_instruction) and
-                                (taicpu(hp1).opcode = A_POP) and
-                                (taicpu(hp1).oper[0]^.typ = top_reg) do
-                            begin
-                              hp2 := hp1;
-                              inc(l,4);
-                            end;
-                          getLastInstruction(p,hp3);
-                          l1 := 0;
-                          while (hp2 <> hp3) and
-                                assigned(hp1) and
-                                (hp1.typ = ait_instruction) and
-                                (taicpu(hp1).opcode = A_PUSH) and
-                                (taicpu(hp1).oper[0]^.typ = top_reg) and
-                                (taicpu(hp1).oper[0]^.reg.enum = taicpu(hp2).oper[0]^.reg.enum) do
-                            begin
-                              { change it to a two op operation }
-                              taicpu(hp2).oper[1]^.typ:=top_none;
-                              taicpu(hp2).ops:=2;
-                              taicpu(hp2).opcode := A_MOV;
-                              taicpu(hp2).loadoper(1,taicpu(hp1).oper[0]^);
-                              reference_reset(tmpref);
-                              tmpRef.base.enum:=R_INTREGISTER;
-                              tmpRef.base.number:=NR_STACK_POINTER_REG;
-                              convert_register_to_enum(tmpref.base);
-                              tmpRef.offset := l;
-                              taicpu(hp2).loadRef(0,tmpRef);
-                              hp4 := hp1;
-                              getNextInstruction(hp1,hp1);
-                              asml.remove(hp4);
-                              hp4.free;
-                              getLastInstruction(hp2,hp2);
-                              dec(l,4);
-                              inc(l1);
-                            end;
-                          if l <> -4 then
-                            begin
-                              inc(l,4);
-                              for l1 := l1 downto 1 do
-                                begin
-                                  getNextInstruction(hp2,hp2);
-                                  dec(taicpu(hp2).oper[0]^.ref^.offset,l);
-                                end
-                            end
-                        end
-                      end
-                    else
-                      begin
-                        if (taicpu(p).oper[0]^.typ = top_reg) and
-                          GetNextInstruction(p, hp1) and
-                          (tai(hp1).typ=ait_instruction) and
-                          (taicpu(hp1).opcode=A_PUSH) and
-                          (taicpu(hp1).oper[0]^.typ = top_reg) and
-                          (taicpu(hp1).oper[0]^.reg.enum=taicpu(p).oper[0]^.reg.enum) then
-                          begin
-                            { change it to a two op operation }
-                            taicpu(p).oper[1]^.typ:=top_none;
-                            taicpu(p).ops:=2;
-                            taicpu(p).opcode := A_MOV;
-                            taicpu(p).loadoper(1,taicpu(p).oper[0]^);
-                            reference_reset(tmpref);
-                            TmpRef.base.enum := R_ESP;
-                            taicpu(p).loadRef(0,TmpRef);
-                            asml.remove(hp1);
-                            hp1.free;
-                          end;
-                      end;
-                  end;
-*)
                 A_PUSH:
                   begin
                     if (taicpu(p).opsize = S_W) and