From 0657ce7c02e291d2d4c24da335da5d89686824e8 Mon Sep 17 00:00:00 2001 From: florian Date: Mon, 25 Feb 2019 21:43:56 +0000 Subject: [PATCH] * get rid of fpc_Resume git-svn-id: branches/debug_eh@41476 - --- compiler/psabiehpi.pas | 4 ++-- rtl/inc/psabieh.inc | 12 ------------ rtl/inc/psabiehh.inc | 5 +---- 3 files changed, 3 insertions(+), 18 deletions(-) diff --git a/compiler/psabiehpi.pas b/compiler/psabiehpi.pas index 7bb21ffbac..d4cc17be12 100644 --- a/compiler/psabiehpi.pas +++ b/compiler/psabiehpi.pas @@ -630,12 +630,12 @@ implementation psabiehprocinfo.PushLandingPad(psabiehprocinfo.NoAction); end; - pd:=search_system_proc('fpc_resume'); + pd:=search_system_proc('_unwind_resume'); cgpara1.init; paramanager.getintparaloc(list,pd,1,cgpara1); hlcg.a_load_reg_cgpara(list,voidpointertype,t.unwind_info,cgpara1); paramanager.freecgpara(list,cgpara1); - hlcg.g_call_system_proc(current_asmdata.CurrAsmList,'fpc_resume',[@cgpara1],nil).resetiftemp; + hlcg.g_call_system_proc(current_asmdata.CurrAsmList,'_unwind_resume',[@cgpara1],nil).resetiftemp; { we do not have to clean up the stack, we never return } cgpara1.done; diff --git a/rtl/inc/psabieh.inc b/rtl/inc/psabieh.inc index b3e6daba79..2f12f74a14 100644 --- a/rtl/inc/psabieh.inc +++ b/rtl/inc/psabieh.inc @@ -1204,18 +1204,6 @@ procedure fpc_ReRaise; [public,alias:'FPC_RERAISE']; compilerproc; RunError(217); end; - -{$if defined(cpui386) and not defined(cpullvm)} -{$define FPC_SYSTEM_HAS_RESUME} -procedure fpc_Resume(exception_object: PFPC_Unwind_Exception); [public,alias:'FPC_RESUME']; compilerproc; assembler; nostackframe; - asm - popl %ecx - pushl %eax - pushl %ecx - jmp _Unwind_Resume - end; -{$endif} - {$define FPC_SYSTEM_HAS_RAISENESTED} procedure fpc_raise_nested;compilerproc; var diff --git a/rtl/inc/psabiehh.inc b/rtl/inc/psabiehh.inc index 8f7b92d53b..f34b3ff344 100644 --- a/rtl/inc/psabiehh.inc +++ b/rtl/inc/psabiehh.inc @@ -57,7 +57,7 @@ type end; function _Unwind_RaiseException(exception_object: PFPC_Unwind_Exception): FPC_Unwind_Reason_Code; cdecl; external; - procedure _Unwind_Resume(exception_object: PFPC_Unwind_Exception); cdecl; external; + procedure _Unwind_Resume(exception_object: PFPC_Unwind_Exception); compilerproc; cdecl; external; type TFPC_psabieh_exceptionClass = record @@ -80,9 +80,6 @@ function _FPC_psabieh_personality_v0(version: longint; actions: FPC_Unwind_Actio {$endif} function FPC_psabi_begin_catch(exc:PFPC_Unwind_Exception): pointer; compilerproc; procedure FPC_psabi_end_catch; cdecl; compilerproc; -{$if defined(cpui386) and not defined(cpullvm)} -Procedure fpc_Resume(exception_object: PFPC_Unwind_Exception); compilerproc; -{$endif} { llvm cannot create a catch/cleanup block if there is no call inside the try block to a routine that can raise an exception. Hence, we will call