Closed
Bug 940218
Opened 11 years ago
Closed 11 years ago
Build memory/jemalloc and friends in unified mode
Categories
(Core :: Memory Allocator, defect)
Core
Memory Allocator
Tracking
()
RESOLVED
FIXED
mozilla28
People
(Reporter: cpeterson, Assigned: iacobcatalin)
References
Details
(Whiteboard: [qa-])
Attachments
(1 file, 1 obsolete file)
651 bytes,
patch
|
ehsan.akhgari
:
review+
|
Details | Diff | Splinter Review |
Green Try build:
https://tbpl.mozilla.org/?tree=Try&rev=774abfd2bb55
Attachment #8334357 -
Flags: review?(mh+mozilla)
Updated•11 years ago
|
Attachment #8334357 -
Flags: review?(mh+mozilla) → review+
Reporter | ||
Comment 1•11 years ago
|
||
Comment 2•11 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla28
Comment 3•11 years ago
|
||
Backed out for causing bug 941616: https://hg.mozilla.org/integration/mozilla-inbound/rev/f7e67f388134
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 4•11 years ago
|
||
The initial patch changed:
memory/build/moz.build
memory/jemalloc/moz.build
memory/mozalloc/moz.build
https://bugzilla.mozilla.org/show_bug.cgi?id=941616#c5 decided that memory/build/ shouldn't be built in unified mode
The memory/jemalloc/moz.build part gives the linking errors in https://bugzilla.mozilla.org/show_bug.cgi?id=941616#c8 (at least on Windows, when building with --enable-dmd)
At least some of the linking errors happen because each .c file defines a JEMALLOC_<SMTH>_C_ macro in the beginning and those macros change what various includes generate.
For example tcache.c defines JEMALLOC_TCACHE_C_ which decides whether tcache.h generates tcache_tsd_boot via the malloc_tsd_funcs macro:
#if (defined(JEMALLOC_ENABLE_INLINE) || defined(JEMALLOC_TCACHE_C_))
/* Map of thread-specific caches. */
malloc_tsd_externs(tcache, tcache_t *)
malloc_tsd_funcs(JEMALLOC_INLINE, tcache, tcache_t *, NULL,
tcache_thread_cleanup)
When we build in unified mode some other file pulls in tcache.h before JEMALLOC_TCACHE_C_ gets defined so no malloc_tsd_funcs is generated.
Given that every jemalloc .c file starts with such a macro which could change arbitrary things it's safer to just not build any of it in unified mode.
We are therefore left with only memory/mozalloc/moz.build which this patch proposes.
Attachment #8334357 -
Attachment is obsolete: true
Attachment #8337681 -
Flags: review?(ehsan)
Comment 5•11 years ago
|
||
Comment on attachment 8337681 [details] [diff] [review]
Minimal patch that works on Windows with --enable-dmd
Review of attachment 8337681 [details] [diff] [review]:
-----------------------------------------------------------------
Looks good, thanks!
Attachment #8337681 -
Flags: review?(ehsan) → review+
Assignee | ||
Updated•11 years ago
|
Keywords: checkin-needed
Comment 6•11 years ago
|
||
Assignee: cpeterson → iacobcatalin
Keywords: checkin-needed
Status: REOPENED → RESOLVED
Closed: 11 years ago → 11 years ago
Resolution: --- → FIXED
Updated•11 years ago
|
Whiteboard: [qa-]
You need to log in
before you can comment on or make changes to this bug.
Description
•