Граф коммитов

163 Коммитов

Автор SHA1 Сообщение Дата
Jeff Walden 176f2f5a05 Bug 1246061 - Add some comments. r=luke
--HG--
extra : rebase_source : 6577e0ab9834fa00f3f0fe2893a6b039bb70f5f3
2016-03-23 13:21:02 -07:00
Jon Coppeard 17af524d85 Bug 1260785 - Make hashcode generation fallible for cell pointers that can be moved by GC r=terrence 2016-07-13 10:20:00 +01:00
Jan de Mooij d54ca15369 Bug 1269319 followup - Don't swap an entry with itself to avoid Variant self assignment. r=bustage
--HG--
extra : rebase_source : 0bf8331f4aba57502bbff07df478c1aeb91c2fc6
2016-05-21 18:08:30 +02:00
Jan de Mooij eb2ea5c544 Bug 1269319 - Make AlignedStorage/AlignedStorage2 non-copyable to fix strict aliasing issues. r=Waldo 2016-05-19 20:57:36 +02:00
Nicholas Nethercote 2511b2c327 Bug 1267550 (part 2) - Rename MOZ_WARN_UNUSED_RESULT as MOZ_MUST_USE. r=froydnj.
It's an annotation that is used a lot, and should be used even more, so a
shorter name is better.

MozReview-Commit-ID: 1VS4Dney4WX

--HG--
extra : rebase_source : b26919c1b0fcb32e5339adeef5be5becae6032cf
2016-04-27 14:16:50 +10:00
Shu-yu Guo a58fd08178 Bug 1265956 - Assert that no entry is found in HashTable::putNew. (r=terrence) 2016-04-20 14:52:12 -07:00
Jeff Walden 1dd8dbc3f7 Bug 1246061. r=jandem, r=bz, r=luke, r=froydnj
--HG--
extra : rebase_source : 5b314d4c4c6e0b553290884be7338f8e79c22f71
2016-03-09 00:37:20 -08:00
Luke Wagner b4d7059241 Bug 1234985 - Hoist CStringHasher (r=sfink)
--HG--
extra : commitid : KxwfOhuDfeq
extra : rebase_source : 1a38c30bea5b324ca913a7688c2febd834873d49
2016-01-20 12:00:21 -06:00
Luke Wagner 6ebd19920f Bug 1239601 - improve the UniquePtr situation (r=jorendorff)
--HG--
extra : commitid : FwqWNSZ3SKY
extra : rebase_source : 75ed67bfadcbdaeb5bf89a57ad6ca9ef75b7f1f0
2016-01-15 18:26:06 -06:00
Terrence Cole 3c0b63c8e8 Bug 1239515 - Simplify HashSet's key-overwriting interface; r=sunfish 2016-01-14 09:43:30 -08:00
Jim Blandy 9aba54fc4f Bug 1236801: Don't check for simulated OOM in a way that invalidates AddPtrs for no discernable reason. (Revised to fix uninitialized var, r=sfink) r=jonco
--HG--
extra : rebase_source : 23222e831fb516bc3cc2672b4c6807564d56bce1
2016-01-12 16:49:45 -08:00
Wes Kocher 0439338087 Backed out changeset 7111837e42b9 (bug 1236801) for SM wError bustage
--HG--
extra : commitid : EZ9x68Sn1qG
2016-01-12 16:55:12 -08:00
Jim Blandy 637fbf70ae Bug 1236801: Don't check for simulated OOM in a way that invalidates AddPtrs for no discernable reason. r=jonco
--HG--
extra : rebase_source : 12fd6cb6969733355581d7cd28876a7b46097c45
extra : amend_source : 04430312d8175c746139a85b0f8062b408c82192
2016-01-08 10:01:53 -08:00
Jon Coppeard 498b421261 Bug 1232672 - Use MOZ_WARN_UNUSED_RESULT to make hash table clients check for failure r=luke r=billm r=njn 2015-12-22 13:29:43 +00:00
Jon Coppeard 204777d13d Bug 1207519 - Prevent HashTable shrink from ignoring allocation failures that may have been reported r=Waldo 2015-09-30 11:34:49 +01:00
Jon Coppeard 3616fbd00c Bug 1200642 - Add OOM simulation to hastables r=terrence 2015-09-30 11:34:49 +01:00
Terrence Cole a6855649ac Bug 1196847 - Part 2: Implement a cell hasher that uses unique id based hashes; r=jonco
--HG--
extra : rebase_source : 4d33add708a491e27492f9cdb63d98e76a7af94e
2015-08-26 14:51:35 -07:00
Terrence Cole 01fd1cc898 Bug 1196847 - Part 1: Allow storage of a unique id for a cell independent of address; r=jonco
* * *
imported patch rewrite_uid_on_ht_with_zone_sweeping

--HG--
extra : rebase_source : fc3a37b4ea6bbf32f8f55f56a1c4846be92c0164
2015-08-20 10:35:22 -07:00
Terrence Cole c4ccb272ae Backout cca86cd156cf (Bug 1196847) for regressing EarleyBoyer. 2015-09-28 14:57:16 -07:00
Terrence Cole b5775180d1 Backout 74608aa063b9 (Bug 1196847) for regressing EarleyBoyer. 2015-09-28 14:56:57 -07:00
Terrence Cole 0c90745b80 Bug 1196847 - Part 2: Implement a cell hasher that uses unique id based hashes; r=jonco
--HG--
extra : rebase_source : e1464d566ec7dbf85b1b9d861450906945057e23
2015-08-26 14:51:35 -07:00
Terrence Cole a10a39f891 Bug 1196847 - Part 1: Allow storage of a unique id for a cell independent of address; r=jonco
* * *
imported patch rewrite_uid_on_ht_with_zone_sweeping

--HG--
extra : rebase_source : e0d01c24e9ea7cdb9660f5cac3b65699eb091cfd
2015-08-20 10:35:22 -07:00
Terrence Cole d0d0a951de Backout 7f6585a46cd0 (Bug 1196847) for being on top of a regression.
--HG--
extra : rebase_source : 9c9b94cf6e514c603fa8e7964da1d51004326399
2015-09-03 09:37:19 -07:00
Terrence Cole 5e9eddeee5 Bug 1196847 - Part 2: Implement a cell hasher that uses unique id based hashes; r=jonco
--HG--
extra : rebase_source : aec278105f1cb4303eff593edef244f10ebd2a0e
2015-08-26 14:51:35 -07:00
Nick Fitzgerald 3bc1833993 Bug 1187399 - Add a js::DefaultHasher specialization for mozilla::UniquePtr<T> that proxies the UniquePtr's raw pointer to PointerHasher. r=terrence
--HG--
extra : rebase_source : 86db93fe0874c21792554ad000d94939148ea4c6
2015-07-24 10:42:00 -04:00
Birunthan Mohanathas a8939590de Bug 1182996 - Fix and add missing namespace comments. rs=ehsan
The bulk of this commit was generated by running:

  run-clang-tidy.py \
    -checks='-*,llvm-namespace-comment' \
    -header-filter=^/.../mozilla-central/.* \
    -fix
2015-07-13 08:25:42 -07:00
Jan de Mooij 11274288e1 Bug 1144366 followup - Stop declaring multiple pointers on a single line. r=jorendorff 2015-04-02 11:22:21 +02:00
Jon Coppeard c1a7380238 Bug 1149135 - Don't create HashMapEntry on stack when adding to a HashMap r=luke 2015-04-01 10:11:06 +01:00
Jan de Mooij b8b1677f0f Bug 1144366 - Switch SpiderMonkey and XPConnect style from |T *t| to |T* t|. r=jorendorff 2015-03-28 23:22:11 +01:00
Phil Ringnalda c8a25251c1 Backed out changeset 0c030f97a04f (bug 1144366) for being on top of patches being backed out
CLOSED TREE
2015-03-28 10:39:56 -07:00
Jan de Mooij 8d6d44ecb8 Bug 1144366 - Switch SpiderMonkey and XPConnect style from |T *t| to |T* t|. r=jorendorff 2015-03-28 12:08:37 +01:00
Brian Hackett a054a9a07e Bug 1143521 - Remove IsPoisonedPtr stuff, r=sfink. 2015-03-18 18:01:35 -07:00
Nick Fitzgerald 57951abfec Bug 1139217 - Make js::HashSet<T> work with move-only T types; r=luke 2015-03-03 17:54:00 +01:00
Jon Coppeard 8db99543e5 Bug 1136046 - Increase maximum capacity of js::HashMap and HashSet r=luke 2015-02-26 09:02:13 +00:00
Nicholas Nethercote 5454a067f6 Bug 979293 - Don't write collision bits in HashTable unnecessarily. r=luke.
This avoids no-op writes to the keyHash of entries when doing a no-add-lookup.
This removes a genuine data race in JSRuntime::permanentAtoms, which receives
frequent no-add-lookups from multiple threads after JSRuntime initialization
without any kind of locking.

--HG--
extra : rebase_source : bb0ccf75e674f28e21f0a7209699f68dd7977f04
2015-02-25 10:39:46 -08:00
Dan Gohman 0a60c87158 Bug 1131783 - Mark various unlikely conditions as MOZ_UNLIKELY r=waldo 2015-02-12 08:37:01 -08:00
Birunthan Mohanathas 1b10c9d731 Bug 1120796 - Part 2: Replace ConvertibleToBool hackarounds with explicit bool operators. r=Waldo 2015-02-03 18:52:36 +02:00
Jon Coppeard c6f9d9bd30 Bug 1127246 - Add a post barrier to the baseShapes table r=terrence a=abillings 2015-02-02 10:11:23 +00:00
Masatoshi Kimura bf312ad056 Bug 1120062 - Part 1: Remove most Nullptr.h includes. r=waldo 2015-01-11 11:34:52 +09:00
Ehsan Akhgari 4354953b4f Bug 1118486 - Part 1: Use `= delete` instead of MOZ_DELETE directly; r=Waldo
Most of this patch (with the exception of dom/bindings/Codegen.py) was
generated by the following bash script:

#!/bin/bash

function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
       ! -wholename "*security/nss*" \
       ! -wholename "*/.hg*" \
       ! -wholename "*/.git*" \
       ! -wholename "obj-*" \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert MOZ_DELETE '= delete'
2015-01-08 23:19:05 -05:00
Jeff Walden fffb54d187 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 206d7d6d49 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 7e5aae13e9 Bug 650161 - Update pointers to relocated objects r=terrence 2012-06-05 11:47:42 -07:00
Ed Morley 1b0adcea11 Backed out changeset 3adf62f886d9 (bug 650161) 2014-08-14 12:52:41 +01:00
Jon Coppeard 5b1c8897ed Bug 650161 - Update pointers to relocated objects r=terrence 2012-06-05 11:47:42 -07:00
Terrence Cole a6741673cf Bug 1033442 - Remove non-pod calloc from MallocProvider and AllocPolicy; r=jonco 2014-08-05 14:06:35 -07:00
Nicholas Nethercote 609079cb43 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 256a1f168b 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 2a0942be41 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 abf3658282 Bug 1004363 - IonMonkey: A new value-numbering implementation based on a dom-tree DFS. r=nbp 2014-06-27 10:38:44 -07:00