Browse Source

* changed explicit paraloc handling to use ppuload/ppuwrite functions in paraloc instead of directly writing the data. this hopefully fixes some endian issues when using crosscompiled-on-littleendian PPUs with explicit paralocs on bigendian systems (this means Amiga/68k and MorphOS)

git-svn-id: trunk@28596 -
Károly Balogh 11 years ago
parent
commit
05b3a94843
1 changed files with 3 additions and 12 deletions
  1. 3 12
      compiler/symsym.pas

+ 3 - 12
compiler/symsym.pas

@@ -2139,15 +2139,8 @@ implementation
          paraloc[calleeside].init;
          paraloc[calleeside].init;
          paraloc[callerside].init;
          paraloc[callerside].init;
          if vo_has_explicit_paraloc in varoptions then
          if vo_has_explicit_paraloc in varoptions then
-           begin
-             paraloc[callerside].alignment:=ppufile.getbyte;
-             b:=ppufile.getbyte;
-             if b<>sizeof(paraloc[callerside].location^) then
-               internalerror(200411154);
-             ppufile.getdata(paraloc[callerside].add_location^,sizeof(paraloc[callerside].location^));
-             paraloc[callerside].size:=paraloc[callerside].location^.size;
-             paraloc[callerside].intsize:=tcgsize2size[paraloc[callerside].size];
-           end;
+           paraloc[callerside].ppuload(ppufile);
+
          ppuload_platform(ppufile);
          ppuload_platform(ppufile);
       end;
       end;
 
 
@@ -2175,9 +2168,7 @@ implementation
          if vo_has_explicit_paraloc in varoptions then
          if vo_has_explicit_paraloc in varoptions then
            begin
            begin
              paraloc[callerside].check_simple_location;
              paraloc[callerside].check_simple_location;
-             ppufile.putbyte(sizeof(paraloc[callerside].alignment));
-             ppufile.putbyte(sizeof(paraloc[callerside].location^));
-             ppufile.putdata(paraloc[callerside].location^,sizeof(paraloc[callerside].location^));
+             paraloc[callerside].ppuwrite(ppufile);
            end;
            end;
          writeentry(ppufile,ibparavarsym);
          writeentry(ppufile,ibparavarsym);
       end;
       end;