Răsfoiți Sursa

* use sizeuinttype, instead of ptruinttype for the indexdef conversion in
tcgvecnode.pass_generate_code. This avoids a meaningless conversion to 32-bit
(and using the cwd instruction) on i8086 in the far data memory models.

git-svn-id: trunk@39472 -

nickysn 7 ani în urmă
părinte
comite
42432d4ef3
1 a modificat fișierele cu 2 adăugiri și 2 ștergeri
  1. 2 2
      compiler/ncgmem.pas

+ 2 - 2
compiler/ncgmem.pas

@@ -1074,8 +1074,8 @@ implementation
               if not(right.location.loc in [LOC_CREGISTER,LOC_REGISTER]) or
               if not(right.location.loc in [LOC_CREGISTER,LOC_REGISTER]) or
                  not valid_index_size(right.location.size) then
                  not valid_index_size(right.location.size) then
                 begin
                 begin
-                  hlcg.location_force_reg(current_asmdata.CurrAsmList,right.location,right.resultdef,ptruinttype,true);
-                  indexdef:=ptruinttype
+                  hlcg.location_force_reg(current_asmdata.CurrAsmList,right.location,right.resultdef,sizeuinttype,true);
+                  indexdef:=sizeuinttype
                 end
                 end
               else
               else
                 indexdef:=right.resultdef;
                 indexdef:=right.resultdef;