Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
cbaa3d08
Commit
cbaa3d08
authored
Nov 14, 2023
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Add a stub ARM64EC CPU backend.
parent
dd77c32f
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
230 additions
and
5 deletions
+230
-5
Makefile.in
dlls/ntdll/Makefile.in
+1
-0
signal_arm64ec.c
dlls/ntdll/signal_arm64ec.c
+227
-0
signal_x86_64.c
dlls/ntdll/signal_x86_64.c
+2
-5
No files found.
dlls/ntdll/Makefile.in
View file @
cbaa3d08
...
...
@@ -37,6 +37,7 @@ SOURCES = \
sec.c
\
signal_arm.c
\
signal_arm64.c
\
signal_arm64ec.c
\
signal_i386.c
\
signal_x86_64.c
\
string.c
\
...
...
dlls/ntdll/signal_arm64ec.c
0 → 100644
View file @
cbaa3d08
/*
* ARM64EC signal handling routines
*
* Copyright 1999, 2005, 2023 Alexandre Julliard
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifdef __arm64ec__
#include <stdlib.h>
#include <stdarg.h>
#include "ntstatus.h"
#define WIN32_NO_STATUS
#include "windef.h"
#include "winternl.h"
#include "wine/exception.h"
#include "wine/list.h"
#include "ntdll_misc.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
unwind
);
WINE_DECLARE_DEBUG_CHANNEL
(
relay
);
/*******************************************************************
* KiUserExceptionDispatcher (NTDLL.@)
*/
NTSTATUS
WINAPI
KiUserExceptionDispatcher
(
EXCEPTION_RECORD
*
rec
,
CONTEXT
*
context
)
{
FIXME
(
"not implemented
\n
"
);
return
STATUS_INVALID_DISPOSITION
;
}
/*******************************************************************
* KiUserApcDispatcher (NTDLL.@)
*/
void
WINAPI
KiUserApcDispatcher
(
CONTEXT
*
context
,
ULONG_PTR
arg1
,
ULONG_PTR
arg2
,
ULONG_PTR
arg3
,
PNTAPCFUNC
apc
)
{
FIXME
(
"not implemented
\n
"
);
}
/*******************************************************************
* KiUserCallbackDispatcher (NTDLL.@)
*/
void
WINAPI
KiUserCallbackDispatcher
(
ULONG
id
,
void
*
args
,
ULONG
len
)
{
FIXME
(
"not implemented
\n
"
);
}
/**************************************************************************
* RtlIsEcCode (NTDLL.@)
*/
BOOLEAN
WINAPI
RtlIsEcCode
(
const
void
*
ptr
)
{
const
UINT64
*
map
=
(
const
UINT64
*
)
NtCurrentTeb
()
->
Peb
->
EcCodeBitMap
;
ULONG_PTR
page
=
(
ULONG_PTR
)
ptr
/
page_size
;
return
(
map
[
page
/
64
]
>>
(
page
&
63
))
&
1
;
}
/***********************************************************************
* RtlCaptureContext (NTDLL.@)
*/
void
WINAPI
RtlCaptureContext
(
CONTEXT
*
context
)
{
FIXME
(
"not implemented
\n
"
);
}
/*******************************************************************
* RtlRestoreContext (NTDLL.@)
*/
void
CDECL
RtlRestoreContext
(
CONTEXT
*
context
,
EXCEPTION_RECORD
*
rec
)
{
FIXME
(
"not implemented
\n
"
);
}
/**********************************************************************
* RtlVirtualUnwind (NTDLL.@)
*/
PVOID
WINAPI
RtlVirtualUnwind
(
ULONG
type
,
ULONG64
base
,
ULONG64
pc
,
RUNTIME_FUNCTION
*
function
,
CONTEXT
*
context
,
PVOID
*
data
,
ULONG64
*
frame_ret
,
KNONVOLATILE_CONTEXT_POINTERS
*
ctx_ptr
)
{
FIXME
(
"not implemented
\n
"
);
return
NULL
;
}
/*******************************************************************
* RtlUnwindEx (NTDLL.@)
*/
void
WINAPI
RtlUnwindEx
(
PVOID
end_frame
,
PVOID
target_ip
,
EXCEPTION_RECORD
*
rec
,
PVOID
retval
,
CONTEXT
*
context
,
UNWIND_HISTORY_TABLE
*
table
)
{
FIXME
(
"not implemented
\n
"
);
}
/*******************************************************************
* RtlUnwind (NTDLL.@)
*/
void
WINAPI
RtlUnwind
(
void
*
frame
,
void
*
target_ip
,
EXCEPTION_RECORD
*
rec
,
void
*
retval
)
{
FIXME
(
"not implemented
\n
"
);
}
/*******************************************************************
* _local_unwind (NTDLL.@)
*/
void
WINAPI
_local_unwind
(
void
*
frame
,
void
*
target_ip
)
{
CONTEXT
context
;
RtlUnwindEx
(
frame
,
target_ip
,
NULL
,
NULL
,
&
context
,
NULL
);
}
/*******************************************************************
* __C_specific_handler (NTDLL.@)
*/
EXCEPTION_DISPOSITION
WINAPI
__C_specific_handler
(
EXCEPTION_RECORD
*
rec
,
void
*
frame
,
CONTEXT
*
context
,
struct
_DISPATCHER_CONTEXT
*
dispatch
)
{
FIXME
(
"not implemented
\n
"
);
return
ExceptionContinueSearch
;
}
/*************************************************************************
* RtlCaptureStackBackTrace (NTDLL.@)
*/
USHORT
WINAPI
RtlCaptureStackBackTrace
(
ULONG
skip
,
ULONG
count
,
PVOID
*
buffer
,
ULONG
*
hash
)
{
FIXME
(
"not implemented
\n
"
);
return
0
;
}
/**************************************************************************
* __chkstk (NTDLL.@)
*
* Supposed to touch all the stack pages, but we shouldn't need that.
*/
void
__attribute__
((
naked
))
__chkstk
(
void
)
{
asm
(
"ret"
);
}
/***********************************************************************
* RtlRaiseException (NTDLL.@)
*/
void
WINAPI
RtlRaiseException
(
struct
_EXCEPTION_RECORD
*
rec
)
{
FIXME
(
"not implemented
\n
"
);
}
/***********************************************************************
* RtlUserThreadStart (NTDLL.@)
*/
void
WINAPI
RtlUserThreadStart
(
PRTL_THREAD_START_ROUTINE
entry
,
void
*
arg
)
{
__TRY
{
pBaseThreadInitThunk
(
0
,
(
LPTHREAD_START_ROUTINE
)
entry
,
arg
);
}
__EXCEPT
(
call_unhandled_exception_filter
)
{
NtTerminateProcess
(
GetCurrentProcess
(),
GetExceptionCode
()
);
}
__ENDTRY
}
/******************************************************************
* LdrInitializeThunk (NTDLL.@)
*/
void
WINAPI
LdrInitializeThunk
(
CONTEXT
*
context
,
ULONG_PTR
unk2
,
ULONG_PTR
unk3
,
ULONG_PTR
unk4
)
{
loader_init
(
context
,
(
void
**
)
&
context
->
Rcx
);
TRACE_
(
relay
)(
"
\1
Starting thread proc %p (arg=%p)
\n
"
,
(
void
*
)
context
->
Rcx
,
(
void
*
)
context
->
Rdx
);
NtContinue
(
context
,
TRUE
);
}
/**********************************************************************
* DbgBreakPoint (NTDLL.@)
*/
void
__attribute__
((
naked
))
DbgBreakPoint
(
void
)
{
asm
(
"brk #0xf000; ret"
);
}
/**********************************************************************
* DbgUserBreakPoint (NTDLL.@)
*/
void
__attribute__
((
naked
))
DbgUserBreakPoint
(
void
)
{
asm
(
"brk #0xf000; ret"
);
}
#endif
/* __arm64ec__ */
dlls/ntdll/signal_x86_64.c
View file @
cbaa3d08
...
...
@@ -18,7 +18,7 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#if
def __x86_64__
#if
defined(__x86_64__) && !defined(__arm64ec__)
#include <stdlib.h>
#include <stdarg.h>
...
...
@@ -711,10 +711,7 @@ void WINAPI KiUserCallbackDispatcher( ULONG id, void *args, ULONG len )
*/
BOOLEAN
WINAPI
RtlIsEcCode
(
const
void
*
ptr
)
{
const
UINT64
*
map
=
(
const
UINT64
*
)
NtCurrentTeb
()
->
Peb
->
EcCodeBitMap
;
ULONG_PTR
page
=
(
ULONG_PTR
)
ptr
/
page_size
;
if
(
!
map
)
return
FALSE
;
return
(
map
[
page
/
64
]
>>
(
page
&
63
))
&
1
;
return
FALSE
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment