Skip to content

Rename _aligned_msize to prevent conflict with mingw64 defintion #58238

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

Merged
merged 1 commit into from
Apr 29, 2025
Merged
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
4 changes: 2 additions & 2 deletions src/gc-common.c
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ JL_DLLEXPORT void jl_gc_set_cb_notify_gc_pressure(jl_gc_cb_notify_gc_pressure_t
// but with several fixes to improve the correctness of the computation and remove unnecessary parameters
#define SAVED_PTR(x) ((void *)((DWORD_PTR)((char *)x - sizeof(void *)) & \
~(sizeof(void *) - 1)))
static size_t _aligned_msize(void *p)
static size_t _jl_aligned_msize(void *p)
{
void *alloc_ptr = *(void**)SAVED_PTR(p);
return _msize(alloc_ptr) - ((char*)p - (char*)alloc_ptr);
Expand All @@ -138,7 +138,7 @@ size_t memory_block_usable_size(void *p, int isaligned) JL_NOTSAFEPOINT
{
#if defined(_OS_WINDOWS_)
if (isaligned)
return _aligned_msize(p);
return _jl_aligned_msize(p);
else
return _msize(p);
#elif defined(_OS_DARWIN_)
Expand Down