Преглед на файлове

* fixed length(ansistring/widestring/dynarray) in i8086 far data memory models

git-svn-id: trunk@27673 -
nickysn преди 11 години
родител
ревизия
214eaebf99
променени са 1 файла, в които са добавени 3 реда и са изтрити 3 реда
  1. 3 3
      compiler/ncginl.pas

+ 3 - 3
compiler/ncginl.pas

@@ -300,16 +300,16 @@ implementation
            { length in ansi/wide strings and high in dynamic arrays is at offset -sizeof(pint) }
            { length in ansi/wide strings and high in dynamic arrays is at offset -sizeof(pint) }
            hlcg.location_force_reg(current_asmdata.CurrAsmList,left.location,left.resultdef,left.resultdef,false);
            hlcg.location_force_reg(current_asmdata.CurrAsmList,left.location,left.resultdef,left.resultdef,false);
            current_asmdata.getjumplabel(lengthlab);
            current_asmdata.getjumplabel(lengthlab);
-           cg.a_cmp_const_reg_label(current_asmdata.CurrAsmList,OS_ADDR,OC_EQ,0,left.location.register,lengthlab);
+           hlcg.a_cmp_const_reg_label(current_asmdata.CurrAsmList,left.resultdef,OC_EQ,0,left.location.register,lengthlab);
            if is_widestring(left.resultdef) and (tf_winlikewidestring in target_info.flags) then
            if is_widestring(left.resultdef) and (tf_winlikewidestring in target_info.flags) then
              begin
              begin
-               reference_reset_base(href,left.location.register,-sizeof(dword),sizeof(dword));
+               hlcg.reference_reset_base(href,left.resultdef,left.location.register,-sizeof(dword),sizeof(dword));
                hregister:=cg.makeregsize(current_asmdata.CurrAsmList,left.location.register,OS_INT);
                hregister:=cg.makeregsize(current_asmdata.CurrAsmList,left.location.register,OS_INT);
                cg.a_load_ref_reg(current_asmdata.CurrAsmList,OS_32,OS_INT,href,hregister);
                cg.a_load_ref_reg(current_asmdata.CurrAsmList,OS_32,OS_INT,href,hregister);
              end
              end
            else
            else
              begin
              begin
-               reference_reset_base(href,left.location.register,-sizeof(pint),sizeof(pint));
+               hlcg.reference_reset_base(href,left.resultdef,left.location.register,-sizeof(pint),sizeof(pint));
                hregister:=cg.makeregsize(current_asmdata.CurrAsmList,left.location.register,OS_INT);
                hregister:=cg.makeregsize(current_asmdata.CurrAsmList,left.location.register,OS_INT);
                cg.a_load_ref_reg(current_asmdata.CurrAsmList,OS_INT,OS_INT,href,hregister);
                cg.a_load_ref_reg(current_asmdata.CurrAsmList,OS_INT,OS_INT,href,hregister);
              end;
              end;