Closed Bug 1120272 Opened 9 years ago Closed 8 months ago

Fix the situation with jemalloc + aligned allocation + Windows

Categories

(Core :: Memory Allocator, defect)

x86_64
Linux
defect

Tracking

()

RESOLVED FIXED

People

(Reporter: n.nethercote, Assigned: glandium)

References

Details

Attachments

(1 file)

We expose posix_memalign from jemalloc on Windows, but fail to set HAVE_POSIX_MEMALIGN. This should be fixed.

Also, we use the Windows-only _aligned_malloc and _aligned_free functions but we don't expose them from jemalloc. So those calls might be going to the system allocator instead of jemalloc. This should also be fixed.
Assignee: nobody → mh+mozilla
(In reply to Nicholas Nethercote [:njn] from comment #0)
> We expose posix_memalign from jemalloc on Windows, but fail to set
> HAVE_POSIX_MEMALIGN. This should be fixed.

So, one glitch with this is that even if jemalloc exposes it and Windows can use it, code that relies on HAVE_POSIX_MEMALIGN has the problem that it doesn't get a declaration from headers. While it seems to build and work from a try build (probably using an implicit declaration), it feels to me this needs more thought and possibly involve wrapper headers to actually add the declaration.

> Also, we use the Windows-only _aligned_malloc and _aligned_free functions
> but we don't expose them from jemalloc. So those calls might be going to the
> system allocator instead of jemalloc. This should also be fixed.

This can be fixed independently.
Attachment #8550080 - Flags: review?(n.nethercote) → review+
The leave-open keyword is there and there is no activity for 6 months.
:glandium, maybe it's time to close this bug?
Flags: needinfo?(mh+mozilla)
This is still something that needs addressing.
Flags: needinfo?(mh+mozilla)
Keywords: leave-open
Severity: normal → S3

Let's consider this fixed, and the remaining issues can be addressed in bug 1842582

Status: NEW → RESOLVED
Closed: 8 months ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: