mirror of
git://source.winehq.org/git/wine.git
synced 2024-11-05 18:01:34 +00:00
ntdll: Use a .seh handler in DbgUiRemoteBreakin on ARM64EC.
This commit is contained in:
parent
58e68a1b8a
commit
8e26b7e007
1 changed files with 18 additions and 14 deletions
|
@ -1792,26 +1792,30 @@ __ASM_GLOBAL_FUNC( "#process_breakpoint",
|
|||
"mov w0, #0\n\t" /* ExceptionContinueExecution */
|
||||
"ret" )
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* DbgUiRemoteBreakin (NTDLL.@)
|
||||
*/
|
||||
void WINAPI DbgUiRemoteBreakin( void *arg )
|
||||
void __attribute__((naked)) DbgUiRemoteBreakin( void *arg )
|
||||
{
|
||||
if (NtCurrentTeb()->Peb->BeingDebugged)
|
||||
{
|
||||
__TRY
|
||||
{
|
||||
DbgBreakPoint();
|
||||
}
|
||||
__EXCEPT_ALL
|
||||
{
|
||||
/* do nothing */
|
||||
}
|
||||
__ENDTRY
|
||||
}
|
||||
RtlExitUserThread( STATUS_SUCCESS );
|
||||
asm( ".seh_proc DbgUiRemoteBreakin\n\t"
|
||||
"stp x29, x30, [sp, #-16]!\n\t"
|
||||
".seh_save_fplr_x 16\n\t"
|
||||
".seh_endprologue\n\t"
|
||||
".seh_handler DbgUiRemoteBreakin_handler, @except\n\t"
|
||||
"ldr x0, [x18, #0x60]\n\t" /* NtCurrentTeb()->Peb */
|
||||
"ldrb w0, [x0, 0x02]\n\t" /* peb->BeingDebugged */
|
||||
"cbz w0, 1f\n\t"
|
||||
"bl DbgBreakPoint\n"
|
||||
"1:\tmov w0, #0\n\t"
|
||||
"bl RtlExitUserThread\n"
|
||||
"DbgUiRemoteBreakin_handler:\n\t"
|
||||
"mov sp, x1\n\t" /* frame */
|
||||
"b 1b\n\t"
|
||||
".seh_endproc" );
|
||||
}
|
||||
|
||||
|
||||
/**********************************************************************
|
||||
* DbgBreakPoint (NTDLL.@)
|
||||
*/
|
||||
|
|
Loading…
Reference in a new issue