mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-17 01:59:31 +02:00
* Win32 SEH: handle 'Athlon prefetch bug' and SSE detection exceptions in __FPC_default_handler.
git-svn-id: trunk@27164 -
This commit is contained in:
parent
a176c2d4f5
commit
17b5359db0
@ -163,6 +163,21 @@ var
|
||||
begin
|
||||
if (rec.ExceptionFlags and EXCEPTION_UNWIND)=0 then
|
||||
begin
|
||||
{ Athlon prefetch bug? }
|
||||
if (rec.ExceptionCode=STATUS_ACCESS_VIOLATION) and is_prefetch(pointer(context.eip)) then
|
||||
begin
|
||||
result:=ExceptionContinueExecution;
|
||||
exit;
|
||||
end
|
||||
else if (rec.ExceptionCode=STATUS_ILLEGAL_INSTRUCTION) and sse_check then
|
||||
begin
|
||||
os_supports_sse:=False;
|
||||
{ skip the offending movaps %xmm7,%xmm6 instruction }
|
||||
inc(context.eip,3);
|
||||
result:=ExceptionContinueExecution;
|
||||
exit;
|
||||
end;
|
||||
|
||||
RtlUnwind(@frame,nil,@rec,nil);
|
||||
asm
|
||||
{ RtlUnwind destroys nonvolatile registers, this assembler block prevents
|
||||
|
Loading…
Reference in New Issue
Block a user