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

Issue 16174008: - Create isolate specific resuable handles and use them in the hot lookup paths. (Closed)

Created:
7 years, 6 months ago by siva
Modified:
7 years, 5 months ago
Reviewers:
Ivan Posva
CC:
reviews_dartlang.org
Visibility:
Public.

Description

- Create isolate specific resuable handles and use them in the hot lookup paths. - Create a ResuableHandleScope class which ensures that we do not end up recursively reusing handles leading to corruption. This change shows Dart2JSCompileAll runtime change from 739931 to about 645035 on my local machine. R=iposva@google.com Committed: https://code.google.com/p/dart/source/detail?r=24373

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Total comments: 2

Patch Set 4 : #

Total comments: 8
Unified diffs Side-by-side diffs Delta from patch set Stats (+186 lines, -38 lines) Patch
M runtime/vm/base_isolate.h View 1 2 3 3 chunks +13 lines, -0 lines 0 comments Download
M runtime/vm/handles.h View 1 2 3 2 chunks +2 lines, -1 line 0 comments Download
M runtime/vm/isolate.h View 1 2 3 8 chunks +84 lines, -2 lines 4 comments Download
M runtime/vm/isolate.cc View 1 2 3 5 chunks +25 lines, -1 line 0 comments Download
M runtime/vm/object.h View 1 2 3 6 chunks +13 lines, -10 lines 4 comments Download
M runtime/vm/object.cc View 1 2 3 9 chunks +49 lines, -24 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
siva
7 years, 6 months ago (2013-06-07 16:45:39 UTC) #1
siva
synched up to top of tree
7 years, 6 months ago (2013-06-14 23:42:38 UTC) #2
Ivan Posva
We should discuss this change and ways to make it safe in person. -Ivan https://codereview.chromium.org/16174008/diff/15001/runtime/vm/handles.h ...
7 years, 6 months ago (2013-06-16 11:15:26 UTC) #3
siva
As discussed offline I moved all the isolate specific handle accessors to the ReusableHandleScope object. ...
7 years, 6 months ago (2013-06-19 20:41:55 UTC) #4
Ivan Posva
LGTM -ip https://codereview.chromium.org/16174008/diff/25001/runtime/vm/isolate.h File runtime/vm/isolate.h (right): https://codereview.chromium.org/16174008/diff/25001/runtime/vm/isolate.h#newcode672 runtime/vm/isolate.h:672: VMHandles handles_; reusable_handles_? https://codereview.chromium.org/16174008/diff/25001/runtime/vm/isolate.h#newcode724 runtime/vm/isolate.h:724: #endif // ...
7 years, 6 months ago (2013-06-22 01:01:36 UTC) #5
siva
Committed patchset #4 manually as r24373 (presubmit successful).
7 years, 6 months ago (2013-06-24 22:41:07 UTC) #6
siva
7 years, 5 months ago (2013-07-18 20:39:23 UTC) #7
Message was sent while issue was closed.
https://codereview.chromium.org/16174008/diff/25001/runtime/vm/isolate.h
File runtime/vm/isolate.h (right):

https://codereview.chromium.org/16174008/diff/25001/runtime/vm/isolate.h#newc...
runtime/vm/isolate.h:672: VMHandles handles_;
On 2013/06/22 01:01:36, Ivan Posva wrote:
> reusable_handles_?

Done.

https://codereview.chromium.org/16174008/diff/25001/runtime/vm/isolate.h#newc...
runtime/vm/isolate.h:724: #endif  // defined(DEBUG)
On 2013/06/22 01:01:36, Ivan Posva wrote:
> To not keep objects alive longer than needed we should probably set all of the
> handles to pointing to null.

Done.

https://codereview.chromium.org/16174008/diff/25001/runtime/vm/object.h
File runtime/vm/object.h (right):

https://codereview.chromium.org/16174008/diff/25001/runtime/vm/object.h#newco...
runtime/vm/object.h:5816: inline void Object::SetRaw(RawObject* value) {
On 2013/06/22 01:01:36, Ivan Posva wrote:
> DART_FORCE_INLINE would be a good alternative here.

Done.

https://codereview.chromium.org/16174008/diff/25001/runtime/vm/object.h#newco...
runtime/vm/object.h:5823: vtable_ptr = Smi::handle_vtable_;
Reverted this change as DART_FORCE_INLINE should make sure this is inlined.

On 2013/06/22 01:01:36, Ivan Posva wrote:
> --verify_handles will fail below when being passed a Smi handle.

Powered by Google App Engine
This is Rietveld 408576698