* cache inoutres threadvar address

git-svn-id: trunk@8824 -
This commit is contained in:
peter 2007-10-16 19:12:29 +00:00
parent 4f862a23a7
commit cd35804502

View File

@ -607,20 +607,25 @@ end;
procedure fpc_iocheck;[public,alias:'FPC_IOCHECK']; compilerproc;
var
l : longint;
HInoutRes : PWord;
begin
if InOutRes<>0 then
HInOutRes:=@InoutRes;
if HInOutRes^<>0 then
begin
l:=InOutRes;
InOutRes:=0;
l:=HInOutRes^;
HInOutRes^:=0;
HandleErrorFrame(l,get_frame);
end;
end;
Function IOResult:Word;{$ifdef SYSTEMINLINE}inline;{$endif}
var
HInoutRes : PWord;
Begin
IOResult:=InOutRes;
InOutRes:=0;
HInoutRes:=@InoutRes;
IOResult:=HInOutRes^;
HInOutRes^:=0;
End;