Browse Source

* optimization in thlcgwasm.resize_stack_int_val to avoid some redundant conversions

Nikolay Nikolov 22 hours ago
parent
commit
12bfa69736
1 changed files with 1 additions and 1 deletions
  1. 1 1
      compiler/wasm32/hlcgcpu.pas

+ 1 - 1
compiler/wasm32/hlcgcpu.pas

@@ -2831,7 +2831,7 @@ implementation
                   internalerror(2021010302);
                   internalerror(2021010302);
               end;
               end;
             end
             end
-          else if tcgsize2size[fromcgsize]>=tcgsize2size[tocgsize] then
+          else if (tcgsize2size[fromcgsize]>=tcgsize2size[tocgsize]) and (fromcgsize<>tocgsize) then
             begin
             begin
               { truncate }
               { truncate }
               case tocgsize of
               case tocgsize of