Mike Hommey
e2e878c195
Bug 1104173 - Properly export jemalloc_* symbols from the jemalloc3 replace-malloc library. r=njn
...
Bug 818922 made MOZ_REPLACE_MALLOC a global define, and that changed the
defines set when building mozjemalloc_compat.c for the jemalloc3
replace-malloc library. In turn, this made the symbol munging wrong for
that library, making the jemalloc_* functions exported as je_jemalloc_*
instead of replace_jemalloc_*.
2014-11-26 16:04:25 +09:00
Nicholas Nethercote
b79b7d305e
Bug 1094552 (part 3) - DMD: rename |Block| as |LiveBlock|. r=mccr8.
...
This is to give better contrast with |DeadBlock|, which will be added in the
next patch.
--HG--
extra : rebase_source : cbc767fcc5667cfed108ca7c4ebf1d7e82aa185e
2014-11-18 18:57:20 -08:00
Nicholas Nethercote
b684b5b781
Bug 1094552 (part 2) - DMD: tweak Range and Enum use. r=mccr8.
...
This patch:
- Uses |auto| in Range loops, so more of them fit on a single line.
- Converts one use of HashSet::Enum (which is only needed if you're modifying
the HashSet as you iterate) to HashSet::Range.
--HG--
extra : rebase_source : 09b011cd69218c06984f06420d375839cd4e9214
2014-11-23 17:39:17 -08:00
Nicholas Nethercote
d789a68478
Bug 1094552 (part 1) - DMD: rename mSampled field. r=mccr8.
...
The getter is called IsSampled(), so the field should match that.
--HG--
extra : rebase_source : 074c748eff909faee51bc03888b0c7f328bff82e
2014-11-18 19:11:36 -08:00
Emanuel Hoogeveen
e1583bbd30
Bug 1100485 - Lock chunks during double purging to avoid racing with allocation. r=glandium
2014-11-19 09:34:00 +01:00
Mike Hommey
b14ace82e2
Bug 1098967
- Use native Win32 APIs to append to the LogAlloc output. r=nfroyd
...
Because it turns out that the POSIX API the CRT exposes doesn't do O_APPEND
in a sane manner.
2014-11-19 09:46:49 +09:00
Mike Hommey
480b8cc023
Bug 1087245 part 2 - Register the MALLOC_LOG file handle from LogAlloc to poison IO interposer. r=nfroyd
2014-11-18 19:21:06 +09:00
Mike Hommey
fb847fca47
Bug 1087245 part 1 - Allow replace-malloc libraries to register debug file handles to poison IO interposer. r=nfroyd
2014-11-18 19:21:06 +09:00
Mike Hommey
e6bc795b4f
Bug 1097507 - Make libxul independent of libdmd when DMD is enabled. r=njn
...
This also effectively changes how DMD is enabled from requiring both
replace-malloc initialization and the DMD environment variable to
requiring only the former. The DMD environment variable can still be
used to specify options, but not to disable entirely.
This however doesn't touch all the parts that do enable DMD by setting
the DMD environment variable to 1, so the code to handle this value
is kept.
2014-11-18 19:21:06 +09:00
Mike Hommey
5da2027760
Bug 818922 - Add bidirectional method calls with replace-malloc library. r=njn
2014-11-18 19:21:06 +09:00
Emanuel Hoogeveen
cecfd996f1
Bug 1073662 - Part 7: Enable limited chunk recycling on all platforms. r=glandium
2014-11-13 22:56:00 +01:00
Emanuel Hoogeveen
03c2641eb2
Bug 1073662 - Part 6: Add JEMALLOC_RECYCLE, a mode that keeps a limited amount of chunks alive. r=glandium
2014-11-13 22:55:00 +01:00
Emanuel Hoogeveen
fda914780e
Bug 1073662 - Part 5: Hook the chunk recycle code up to JEMALLOC_MUNMAP and make it safe for use with MALLOC_DECOMMIT and MALLOC_DOUBLE_PURGE. r=glandium
2014-11-13 22:52:00 +01:00
Emanuel Hoogeveen
0e7c7d96e4
Bug 1073662 - Part 4: Import chunk recycling code from jemalloc3. r=glandium
2014-11-01 12:00:00 +01:00
Emanuel Hoogeveen
891c31cce8
Bug 1073662 - Part 3: Make all chunk-sized and larger allocations go through chunk_alloc. r=glandium
2014-09-26 13:29:00 +02:00
Emanuel Hoogeveen
f8aff7e649
Bug 1073662 - Part 2: Always use the jemalloc3 allocation logic and remove the old logic. r=glandium
2014-09-26 13:27:00 +02:00
Emanuel Hoogeveen
7c217a4de4
Bug 1073662 - Part 1: Remove support for the unused MALLOC_PAGEFILE. r=glandium
2014-09-26 13:27:00 +02:00
Mike Hommey
df7a8ce416
Bug 1097506 - Pass a JSONWriteFunc to dmd::AnalyzeReports instead of a JSONWriter. r=njn
...
The interesting feature JSONWriteFunc has, contrary to JSONWriter, is that it
only has virtual methods, which makes it a better candidate to be passed
around between libraries not linked against each other.
This will allow to make dmd and libxul independent from each other.
2014-11-13 09:24:28 +09:00
Guilherme Goncalves
e0957f3ac7
Bug 762448 - Disable tcache in jemalloc3. r=glandium
2014-10-23 02:36:00 -04:00
Guilherme Goncalves
278c4010c4
Bug 1093174 - Properly compute the total size for calloc() calls. r=glandium
2014-11-03 09:01:00 -05:00
Guilherme Goncalves
e6ae083bb0
Bug 1090591 - Fix test_dmd.js on jemalloc3 builds. r=njn
2014-10-28 16:13:00 -04:00
Mike Hommey
f95a929b11
Fixup for bug 1077148: SmokeDMD needs mozglue linkage. r=me
2014-10-30 16:33:30 +09:00
Mike Hommey
d667f4bb59
Bug 1077148 part 4 - Add and use new moz.build templates for Gecko programs and libraries. r=gps
...
There are, sadly, many combinations of linkage in use throughout the tree.
The main differentiator, though, is between program/libraries related to
Gecko or not. Kind of. Some need mozglue, some don't. Some need dependent
linkage, some standalone.
Anyways, these new templates remove the need to manually define the
right dependencies against xpcomglue, nspr, mozalloc and mozglue
in most cases.
Places that build programs and were resetting MOZ_GLUE_PROGRAM_LDFLAGS
or that build libraries and were resetting MOZ_GLUE_LDFLAGS can now
just not use those Gecko-specific templates.
2014-10-30 13:06:12 +09:00
Nicholas Nethercote
e934d99086
Bug 1085727 (part 3, attempt 2) - Print dmd.py's invocation at the top of its output. r=mccr8.
2014-10-20 17:45:58 -07:00
Nicholas Nethercote
b5f25a2bdc
Bug 1085727 (part 2, attempt 2) - Remove dmd.py's -b option and make its behaviour the default. r=mccr8.
2014-10-20 17:45:45 -07:00
Nicholas Nethercote
d699ffb940
Bug 1085727 (part 1, attempt 2) - DMD: make some very short functions one-liners. r=mccr8.
2014-10-20 17:45:09 -07:00
Nicholas Nethercote
755b93f87d
Bug 1014343 (attempt 2) - Add diff support to dmd.py. r=mccr8.
2014-10-16 19:06:45 -07:00
Nicholas Nethercote
6705ab7753
Bug 1076446 (attempt 2) - Make the DMD test work on Windows. r=glandium.
2014-10-09 19:28:33 -07:00
Andrew McCreight
4c55acb4db
Bug 1082128 - Make id to string conversion in DMD use a class. r=njn
2014-10-24 13:44:33 -07:00
Carsten "Tomcat" Book
f22c011ab0
Backed out changeset 835fbe63da4a (bug 1076446) for perma failure in 10.8 mozilla-inbound debug test xpcshell
2014-10-24 12:32:38 +02:00
Carsten "Tomcat" Book
25d0431d7e
Backed out changeset 94c5d968e7e8 (bug 1014343)
2014-10-24 12:32:05 +02:00
Carsten "Tomcat" Book
049dc9761b
Backed out changeset 450c187cbc1b (bug 1085727)
2014-10-24 12:32:03 +02:00
Carsten "Tomcat" Book
dadc9af9b6
Backed out changeset 2cfce41bed5c (bug 1085727)
2014-10-24 12:32:00 +02:00
Carsten "Tomcat" Book
10bb376603
Backed out changeset 1bb832d0c539 (bug 1085727)
2014-10-24 12:31:51 +02:00
Mike Hommey
a567ba99f8
Bug 1083686 - Tool to capture and reproduce Firefox's memory allocations. r=njn,r=mshal
...
--HG--
rename : mozglue/build/Makefile.in => mozglue/build/replace_malloc.mk
2014-10-24 13:08:01 +09:00
Mike Hommey
e29f3df03f
Bug 1083686 part 0 - Don't set MOZ_MEMORY_API to static for OSX in replace_malloc.c. r=njn
...
It appears to be an unnecessary optimization, since the compiler is still inlining
the functions when they're not marked static. OTOH, following patches will require
the _impl functions not to be static.
2014-10-24 13:08:01 +09:00
Nicholas Nethercote
d216b9c742
Bug 1085727 (part 3) - Print dmd.py's invocation at the top of its output. r=mccr8.
...
--HG--
extra : rebase_source : 939ad38842c4e7a93a0a15e88d63ad7adf40a02c
2014-10-20 17:45:58 -07:00
Nicholas Nethercote
a9a59f2ff4
Bug 1085727 (part 2) - Remove dmd.py's -b option and make its behaviour the default. r=mccr8.
...
--HG--
extra : rebase_source : 8edce2b3d2d09b2ace2a7946a2b705ff44ed4cfa
2014-10-20 17:45:45 -07:00
Nicholas Nethercote
654eaa0aa2
Bug 1085727 (part 1) - DMD: make some very short functions one-liners. r=mccr8.
...
--HG--
extra : rebase_source : 6b92db54973b57f23d2231b92b9d567da054333e
2014-10-20 17:45:09 -07:00
Nicholas Nethercote
6ee070c9d4
Bug 1014343 - Add diff support to dmd.py. r=mccr8.
...
--HG--
extra : rebase_source : d91abce6ec9a3b81419f997ed5dfc1b23c89cc7c
2014-10-16 19:06:45 -07:00
Nicholas Nethercote
b3b573ee7b
Bug 1076446 - Make the DMD test work on Windows. r=glandium.
...
--HG--
extra : rebase_source : 7cc8d3b18b0539ff170a98fa1c5706ff46e20d32
2014-10-09 19:28:33 -07:00
Guilherme Goncalves
177e6396f5
Bug 1082199 - Recompute stats in jemalloc_stats when using jemalloc3. r=glandium
2014-10-17 15:55:00 +02:00
Mike Hommey
5015a8682a
Bug 1084210 - Simplify tree traversal for memory/replace. r=mshal
2014-10-18 16:16:20 +09:00
Mike Hommey
b08088c7c1
Bug 1077366 - Remove most symbol wrapping from Android builds. r=nfroyd
...
Since essentially everything is linked to libmozglue and libmozglue takes
precedence in symbol resolution in our dynamic linker, there is no need
to wrap most symbols. PR_GetEnv/PR_SetEnv still needs wrapping because
there's no other way to actually wrap the calls from NSPR itself and NSS,
as well as the symbols wrapped because our dynamic linker can't find them
in system libraries on some devices because they're weak.
2014-10-14 07:17:13 +09:00
Mike Hommey
095f40d1e1
Bug 1081011 - Remove memory/replace/defs.mk. r=mshal
2014-10-14 07:14:34 +09:00
Nicholas Nethercote
d9b1c453b0
Bug 1078981 - Teach dmd.py how to handle gzipped files. r=mccr8.
2014-10-03 00:52:27 -07:00
Nicholas Nethercote
7617782fac
Bug 1078979 - Add more testing of dmd.py. r=erahm.
...
--HG--
rename : memory/replace/dmd/test/full-heap-expected1.txt => memory/replace/dmd/test/full-heap-empty-expected.txt
rename : memory/replace/dmd/test/full-heap-expected4.txt => memory/replace/dmd/test/full-heap-sampled-expected.txt
rename : memory/replace/dmd/test/full-heap-expected2.txt => memory/replace/dmd/test/full-heap-unsampled1-expected.txt
rename : memory/replace/dmd/test/full-heap-expected3.txt => memory/replace/dmd/test/full-heap-unsampled2-expected.txt
rename : memory/replace/dmd/test/full-reports-expected1.txt => memory/replace/dmd/test/full-reports-empty-expected.txt
rename : memory/replace/dmd/test/full-reports-expected4.txt => memory/replace/dmd/test/full-reports-sampled-expected.txt
rename : memory/replace/dmd/test/full-reports-expected2.txt => memory/replace/dmd/test/full-reports-unsampled1-expected.txt
rename : memory/replace/dmd/test/full-reports-expected3.txt => memory/replace/dmd/test/full-reports-unsampled2-expected.txt
extra : rebase_source : 6fc66545db4422a9cd38d734db2b76d3b9b25880
2014-10-09 16:50:12 -07:00
Nicholas Nethercote
079f209c38
Bug 1077230 - Enable the DMD test on Mac 10.8. r=glandium.
...
--HG--
extra : rebase_source : c298dd524ab29644f93dc204128b8ab5a2a7383c
2014-10-07 23:29:07 -07:00
Nicholas Nethercote
7262d7d554
Bug 1079660 - DMD: don't call malloc et al. directly in the test. r=glandium.
...
--HG--
extra : rebase_source : 619e57f5624e5fb4fe370608bb4c04cf43a9be00
2014-10-07 21:44:42 -07:00
Nicholas Nethercote
efd2cec666
Bug 1073312 - Test DMD on TBPL (Linux-only). r=glandium.
...
--HG--
extra : rebase_source : c35cc2bfd6720db35ece715dc7ef900ab5864409
2014-09-28 20:50:52 -07:00