Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(265)

Issue 1142493002: Use a private own symbol instead of a hidden property for hash codes (Closed)

Created:
5 years, 7 months ago by Erik Corry Chromium.org
Modified:
5 years ago
CC:
v8-dev
Base URL:
https://chromium.googlesource.com/v8/v8.git@master
Target Ref:
refs/pending/heads/master
Project:
v8
Visibility:
Public.

Description

Use a private own symbol instead of a hidden property for hash codes R=adamk@chromium.org, verwaest@chromium.org BUG=

Patch Set 1 #

Total comments: 8
Unified diffs Side-by-side diffs Delta from patch set Stats (+72 lines, -84 lines) Patch
M src/collection.js View 2 chunks +9 lines, -0 lines 6 comments Download
M src/factory.h View 1 chunk +1 line, -1 line 0 comments Download
M src/factory.cc View 1 chunk +6 lines, -1 line 0 comments Download
M src/heap/heap.h View 3 chunks +3 lines, -1 line 0 comments Download
M src/heap/heap.cc View 2 chunks +19 lines, -3 lines 0 comments Download
M src/isolate.cc View 2 chunks +7 lines, -0 lines 1 comment Download
M src/math.js View 3 chunks +11 lines, -0 lines 0 comments Download
M src/objects.cc View 9 chunks +14 lines, -38 lines 1 comment Download
M src/runtime/runtime-symbol.cc View 2 chunks +2 lines, -5 lines 0 comments Download
M test/cctest/test-heap.cc View 1 chunk +0 lines, -35 lines 0 comments Download

Messages

Total messages: 13 (3 generated)
Erik Corry Chromium.org
5 years, 7 months ago (2015-05-14 11:57:49 UTC) #1
Erik Corry
On my microbenchmark this doubles the speed of common operations on ES6 Map. I think ...
5 years, 7 months ago (2015-05-14 12:00:56 UTC) #3
arv (Not doing code reviews)
High level comments: 1. We have a perf test for maps. We should add a ...
5 years, 7 months ago (2015-05-14 13:16:17 UTC) #5
Erik Corry
Surely it always caused a map transition. How else can you add the hidden property? ...
5 years, 7 months ago (2015-05-14 13:17:59 UTC) #6
adamk
This looks great, I didn't realize how easy it was to add properties to a ...
5 years, 7 months ago (2015-05-14 15:01:28 UTC) #7
Erik Corry
https://codereview.chromium.org/1142493002/diff/1/src/collection.js File src/collection.js (right): https://codereview.chromium.org/1142493002/diff/1/src/collection.js#newcode85 src/collection.js:85: if (IS_SPEC_OBJECT(key)) { On 2015/05/14 15:01:27, adamk wrote: > ...
5 years, 7 months ago (2015-05-14 15:42:19 UTC) #8
arv (Not doing code reviews)
https://codereview.chromium.org/1142493002/diff/1/src/isolate.cc File src/isolate.cc (right): https://codereview.chromium.org/1142493002/diff/1/src/isolate.cc#newcode791 src/isolate.cc:791: return name == heap()->hidden_string(); Does this one need to ...
5 years, 7 months ago (2015-05-14 19:58:54 UTC) #9
Toon Verwaest
https://codereview.chromium.org/1142493002/diff/1/src/collection.js File src/collection.js (right): https://codereview.chromium.org/1142493002/diff/1/src/collection.js#newcode85 src/collection.js:85: if (IS_SPEC_OBJECT(key)) { On 2015/05/14 15:42:19, Erik Corry wrote: ...
5 years, 7 months ago (2015-05-15 12:24:10 UTC) #10
adamk
https://codereview.chromium.org/1142493002/diff/1/src/objects.cc File src/objects.cc (right): https://codereview.chromium.org/1142493002/diff/1/src/objects.cc#newcode5039 src/objects.cc:5039: return JSGlobalProxy::cast(this)->hash(); To expand slightly on Toon's explanation, here's ...
5 years, 7 months ago (2015-05-19 17:39:38 UTC) #11
Erik Corry Chromium.org
5 years, 7 months ago (2015-05-21 11:13:43 UTC) #12
On 2015/05/19 17:39:38, adamk wrote:
> https://codereview.chromium.org/1142493002/diff/1/src/objects.cc
> File src/objects.cc (right):
> 
> https://codereview.chromium.org/1142493002/diff/1/src/objects.cc#newcode5039
> src/objects.cc:5039: return JSGlobalProxy::cast(this)->hash();
> To expand slightly on Toon's explanation, here's the codepath we used to go
down
> for the identity hash of the JSGlobalProxy.

Moved this to a new issue, sorry: https://codereview.chromium.org/1149863005/

Powered by Google App Engine
This is Rietveld 408576698