Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows: mark a few spots that need porting for ARM support #54782

Merged
merged 1 commit into from
Jun 20, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions src/ccall.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -373,18 +373,18 @@ static bool is_native_simd_type(jl_datatype_t *dt) {

#if defined ABI_LLVM
typedef ABI_LLVMLayout DefaultAbiState;
#elif defined _CPU_X86_64_
# if defined _OS_WINDOWS_
#elif defined _OS_WINDOWS_
# if defined _CPU_X86_64_
typedef ABI_Win64Layout DefaultAbiState;
# else
typedef ABI_x86_64Layout DefaultAbiState;
# endif
#elif defined _CPU_X86_
# if defined _OS_WINDOWS_
# elif defined _CPU_X86_
typedef ABI_Win32Layout DefaultAbiState;
# else
typedef ABI_x86Layout DefaultAbiState;
# error Windows is currently only supported on x86 and x86_64
# endif
#elif defined _CPU_X86_64_
typedef ABI_x86_64Layout DefaultAbiState;
#elif defined _CPU_X86_
typedef ABI_x86Layout DefaultAbiState;
#elif defined _CPU_ARM_
typedef ABI_ARMLayout DefaultAbiState;
#elif defined _CPU_AARCH64_
Expand Down
4 changes: 3 additions & 1 deletion src/stackwalk.c
Original file line number Diff line number Diff line change
Expand Up @@ -969,10 +969,12 @@ static void jl_rec_backtrace(jl_task_t *t) JL_NOTSAFEPOINT
c.R15 = mctx->R15;
c.Rip = mctx->Rip;
memcpy(&c.Xmm6, &mctx->Xmm6, 10 * sizeof(mctx->Xmm6)); // Xmm6-Xmm15
#else
#elif defined(_CPU_X86_)
c.Eip = mctx->Eip;
c.Esp = mctx->Esp;
c.Ebp = mctx->Ebp;
#else
#error Windows is currently only supported on x86 and x86_64
#endif
context = &c;
#elif defined(JL_HAVE_UNW_CONTEXT)
Expand Down
2 changes: 2 additions & 0 deletions src/win32_ucontext.c
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ void jl_makecontext(win32_ucontext_t *ucp, void (*func)(void))
Registration[0].Handler = &__julia_personality;
Registration[1].Next = (PEXCEPTION_REGISTRATION_RECORD)0xFFFFFFFF;
Registration[1].Handler = UnHandler;
#else
#error jl_makecontext not defined for CPU type
#endif
stack_top -= sizeof(void*);
*(void**)stack_top = 0; // push rta
Expand Down