Commit Graph

123 Commits

Author SHA1 Message Date
Jeff Walden
45f2ee3b13 Bug 712939 - Replace a bunch of JS_STATIC_ASSERTs with static_assert. r=jandem
--HG--
extra : rebase_source : 4205bda533538d866b8facd669b11cb40e2f02e9
2014-10-22 15:17:38 -07:00
Nicolas B. Pierron
8b681bc06c Bug 1074911 - Replace JS_ASSERT by MOZ_ASSERT. r=jorendorff
Apply the following script

sed -i '
   /JS_ASSERT(/ {
     s/JS_ASSERT(/MOZ_ASSERT(/;
     :b;
     s/ \\$/\\/;
     /;/ { p; d; };
     n;
     s/^/ /;
     b b;
  };
  s/JS_ASSERT (/MOZ_ASSERT(/;
'

Except where the JS_ASSERT macro does not end with a semi-colon, where empty
lines are in the middle of the macro, and where the backslahes are always the
same-length after the expression.
2014-10-01 19:17:51 +02:00
Jon Coppeard
f91b2acbc0 Bug 650161 - Update pointers to relocated objects r=terrence 2012-06-05 11:47:42 -07:00
Ed Morley
98625ac358 Backed out changeset 3adf62f886d9 (bug 650161) 2014-08-14 12:52:41 +01:00
Jon Coppeard
f6bc914690 Bug 650161 - Update pointers to relocated objects r=terrence 2012-06-05 11:47:42 -07:00
Terrence Cole
255bf6c3fb Bug 1033442 - Remove non-pod calloc from MallocProvider and AllocPolicy; r=jonco 2014-08-05 14:06:35 -07:00
Nicholas Nethercote
3e1c93b184 Bug 1043605 - Fix up DEBUG/JS_DEBUG confusion in HashTable.h. r=jwalden.
--HG--
extra : rebase_source : ae56e815766be675083596e177844e2365e93906
2014-08-10 23:17:44 -07:00
Nicholas Nethercote
b4a9c6b93b Bug 1038601 - Shrink js::HashTable. r=luke.
This patch reduces sizeof(js::HashTable):
- On 64-bit: from 32 bytes to 24 bytes.
- On 32-bit: from 24 bytes to 16 bytes.

The latter is particularly nice because jemalloc rounds up allocation requests
of 24 bytes to 32, but it can allocate 16 bytes without slop, so we're saving
16 bytes per heap-allocated HashTable.

This is done by:
- Shrinking |removedCount| and |hashShift|.
- Reordering the fields.
- Not defining |mutationCount| and |mEntered| in non-DEBUG builds rather than
  using DebugOnly<> -- in non-DEBUG builds, DebugOnly<> fields take up 1 byte
  each.

This change saves over 55 KiB when starting Firefox and loading Gmail.

The patch also uses uint32_t more consistently for the generation.

--HG--
extra : rebase_source : 8bdfbfe40f233711433bd9b7a2b5a19d69beacc7
2014-07-16 16:51:09 -07:00
Nicholas Nethercote
8ea1b7923f Bug 1036789 - Convert the third quarter of MFBT to Gecko style. r=Ms2ger.
--HG--
extra : rebase_source : 668cd394806203ddfa34bd4f226335ff26c846b5
2014-07-10 19:10:17 -07:00
Dan Gohman
2db5003bfb Bug 1004363 - IonMonkey: A new value-numbering implementation based on a dom-tree DFS. r=nbp 2014-06-27 10:38:44 -07:00
Ehsan Akhgari
ad3b490e96 Bug 1013663 - Fix some bad implicit conversion constructors in the JS engine; r=jorendorff,jandem 2014-05-25 21:46:24 -04:00
Dan Gohman
d4e734cb37 Bug 1004363 - SpiderMonkey: Eliminate unused functions. r=mjrosenb 2014-05-14 21:51:55 -07:00
Chris Peterson
41e56b2e41 Bug 712873 - Part 2: Replace JS_ASSERT with MOZ_ASSERT outside js/src/ directory. r=luke 2014-02-17 22:24:15 -08:00
Daniel Holbert
84283bddce back out 3a8893b28489 (bug 712939) and 39adab158c17,16add78c43e3,37193db7e15b (bug 712873), for build bustage. 2014-02-19 00:15:51 -08:00
Chris Peterson
966ea39163 Bug 712873 - Part 2: Replace JS_ASSERT with MOZ_ASSERT outside js/src/ directory. r=luke 2014-02-17 22:24:15 -08:00
Chris Peterson
c8d24a2942 Bug 964016 - Part 2: Replace JS_UNLIKELY with MOZ_UNLIKELY. r=luke 2014-01-24 19:57:58 -08:00
Nicholas Nethercote
0ec65cabbf Bug 961883 (part 0) - Some tiny HashTable comment tweaks. r=luke.
--HG--
extra : rebase_source : 749b61ec992335aa5e2be63340e88b04ff236967
2014-01-20 19:52:52 -08:00
Terrence Cole
2e679fb1a1 Bug 948516 - Assert that js::HashTable pointers and enumerators are used correctly; r=luke 2013-12-03 12:51:02 -08:00
Terrence Cole
7f6fe020bb Backout changeset 70e76314c8a7 for build bustage on a CLOSED TREE.
--HG--
extra : rebase_source : 83e1e8a5a4802ef0b7b1d6f7dc0df6595bc9f00f
2013-12-10 15:26:05 -08:00
Terrence Cole
1ba90fd085 Bug 948516 - Assert that js::HashTable pointers and enumerators are used correctly; r=luke 2013-12-03 12:51:02 -08:00
Sean Stangl
c8c6d69eb0 Bug 939505 - Use JS_DEBUG in public headers. r=jorendorff 2013-12-06 15:03:08 -08:00
Jon Coppeard
cacaec6884 Bug 939993 - Add assert that hash key is still valid in HashTable::relookupOrAdd r=sfink 2013-12-07 12:50:52 +00:00
Jeff Walden
0d8f37059b Bug 940033 - js::HashMapEntry::{key,value} fields should be private, with accessors, and the former should expose a const reference. r=jimb
--HG--
extra : rebase_source : 439d194ed15bf87e9643c9c09d4512ff7f616fcc
2013-11-25 17:35:09 -08:00
Carsten "Tomcat" Book
29b36011f5 Backed out changeset 042ab55b8476 (bug 939993) for Spidermonkey rootanalysis orange on a CLOSED TREE 2013-11-25 15:04:35 +01:00
Jon Coppeard
eb1f048c43 Bug 939993 - Check that AddPtrs are used only with matching Lookup values r=sfink 2013-11-25 11:26:10 +00:00
Ryan VanderMeulen
1e4f3c8477 Backed out changeset 1469f9e856c0 (bug 939993) for SM rootanalysis crashes.
CLOSED TREE
2013-11-21 09:44:27 -05:00
Jon Coppeard
29d17a9ee7 Bug 939993 - Check that AddPtrs are used only with matching Lookup values r=sfink 2013-11-19 22:53:32 +00:00
Ed Morley
0f65d839f4 Backed out changeset 1b720320ccf4 (bug 939993) for rootanalysis assertions on a CLOSED TREE 2013-11-20 16:38:41 +00:00
Jon Coppeard
29da11f188 Bug 939993 - Check that AddPtrs are used only with matching Lookup values r=sfink 2013-11-19 22:53:32 +00:00
Jim Blandy
f0a0296f91 Bug 896100: Convert all uses of OldMove and MoveRef to true rvalue references and the modern Move and Forward. r=luke, r=waldo 2013-11-19 09:05:36 -08:00
Jeff Walden
3080160eaf Bug 934718 - Simplify some of the alpha computations in HashTable.h by converting alpha fractions to numerator/denominator ratios of integers, and convert associated JS_STATIC_ASSERT to static_assert. r=luke
--HG--
extra : rebase_source : a35631c885ad7058739d9e99498714f318ef589c
2013-10-24 17:11:32 +01:00
Nathan Froyd
536daacd4a Bug 925879 - use JS_BITS_PER_WORD instead of JS_BYTES_PER_WORD in HashTable.h; r=njn 2013-10-15 10:11:03 -04:00
Shu-yu Guo
128b76beaa Bug 903193 - Part 4: Add ability to do read only lookup on the Shape tree. (r=bhackett) 2013-10-08 15:14:03 -07:00
Douglas Crosher
e5a88dc385 Bug 923328 - Ionmonkey: fix float32 hash function. r=terrence 2013-10-03 10:11:18 +10:00
Jon Coppeard
1b245e7684 Bug 912567 - Split HashMap/HashSet::rekey() into rekey() and rekeyIfMoved() r=terrence 2013-09-24 10:03:32 +01:00
Birunthan Mohanathas
3f4f32b49a Bug 784739 - Switch from NULL to nullptr in js/ductwork/, js/ipc/, and js/public/; r=ehsan 2013-09-19 15:24:53 -04:00
Justin Lebar
2e2403726d Bug 909977 - Rename mozilla::Move to mozilla::OldMove, and make mozilla::Move a synonym for std::move(). r=waldo
--HG--
extra : rebase_source : 7b3bb02cc8cbc0ad6721c6c3895564d9567b8ddb
2013-08-29 11:54:14 -07:00
Jon Coppeard
8bab73cb34 Bug 906387 - Rehash hash tables if necessary when rekeying during minor GC r=terrence 2013-08-29 10:27:50 +01:00
Jon Coppeard
26d42248d9 Bug 726687 - Stop rekeying from calling pre barriers r=terrence 2013-02-15 17:59:19 +00:00
Ms2ger
6d567ab3cc Bug 904110 - Move alignment features out of Util.h into a new header; r=Waldo 2013-08-14 09:00:52 +02:00
Jeff Walden
6c81653318 Bug 891177 - Remove Vector.h's js/TemplateLib.h dependency by introducing mfbt/TemplateLib.h with the necessary bits. r=terrence
--HG--
extra : rebase_source : e84231171d6bd6c1e2de8201b8c9563375723d01
2013-07-08 12:42:13 -07:00
Jeff Walden
8a8be12d99 Bug 891177 - Move js::Swap to mozilla::Swap. r=terrence
--HG--
extra : rebase_source : 925bccd4fa3f95e1aa4e17d94ad5a443fc7a63aa
2013-07-03 15:57:33 -07:00
Jeff Walden
919f4b04c8 Bug 891177 - Add ReentrancyGuard.h as a helper class for asserting that use of a class is non-reentrant. r=terrence
--HG--
extra : rebase_source : 3751e523c0b0315697cb6e005dfd8ee625f6dd58
2013-07-02 17:47:08 -07:00
Jeff Walden
fe51d6bb86 Bug 891177 - Implement Move.h to define a move-construction interface. r=terrence
--HG--
extra : rebase_source : 45f9bb87fc0ee96ea35005ca0dcb263aa11745b8
2013-07-02 17:25:13 -07:00
Terrence Cole
b57778c83f Bug 888117 - Properly barrier the JSON stringifier's CycleDetection set; r=billm
--HG--
extra : rebase_source : 9cd269cf38bacfb63cbceef5dec795da2c24750c
2013-06-27 18:12:54 -07:00
Jon Coppeard
ff4b38f917 Bug 878160 - GC: post barrier weak references in the browser - part 1 JS engine r=terrence
--HG--
extra : rebase_source : 4dfd4f8f46564d3a9858646a0f68c9047c2f7e93
2013-07-02 09:43:45 +01:00
Catalin Iacob
1544c37641 Bug 798914 (part 4) - Use newly introduced mozilla::MallocSizeOf in js. r=njn.
--HG--
extra : rebase_source : d1c063b94c7ec58729150cbea602bb4c9f2a0e24
2013-06-23 13:21:01 +02:00
Dan Gohman
9e49b5eb5f Bug 885175 - DoubleHasher<double> fixes -- use a bitwise comparison to avoid considering zero and negative zero equal. r=luke 2013-06-20 11:55:41 -07:00
Emanuel Hoogeveen
73cb5d6b4d Bug 883697 (part 1) - Make include guards consistent in js/ductwork/, js/ipc/ and js/public/. r=njn.
--HG--
extra : rebase_source : 34f5559ba6e64831905686e12356b70109d873a8
2013-06-19 17:59:09 -07:00
Terrence Cole
8cf88bc3ae Bug 706885 - Implement generational GC for the SpiderMonkey interpreter; r=billm 2013-03-14 10:26:06 -07:00