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

Issue 11358047: Add is_intrinsic and is_not_intrinsic bits to prevent repeated tests on the same function (inlining… (Closed)

Created:
8 years, 1 month ago by srdjan
Modified:
8 years, 1 month ago
Reviewers:
siva
CC:
reviews_dartlang.org
Visibility:
Public.

Description

Add is_intrinsic and is_not_intrinsic bits to prevent repeated tests on the same function (inlining, recompilations). The bist are set lazily, initially both are false. Committed: https://code.google.com/p/dart/source/detail?r=14444

Patch Set 1 #

Patch Set 2 : #

Total comments: 6

Patch Set 3 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+42 lines, -19 lines) Patch
M runtime/vm/intrinsifier.cc View 1 2 1 chunk +11 lines, -10 lines 0 comments Download
M runtime/vm/object.h View 1 2 3 chunks +25 lines, -9 lines 0 comments Download
M runtime/vm/object.cc View 1 2 chunks +6 lines, -0 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
srdjan
8 years, 1 month ago (2012-11-01 22:06:46 UTC) #1
siva
lgtm https://codereview.chromium.org/11358047/diff/5001/runtime/vm/intrinsifier.cc File runtime/vm/intrinsifier.cc (right): https://codereview.chromium.org/11358047/diff/5001/runtime/vm/intrinsifier.cc#newcode76 runtime/vm/intrinsifier.cc:76: if (function.IsClosureFunction()) return false; Should we do the ...
8 years, 1 month ago (2012-11-01 23:04:06 UTC) #2
srdjan
8 years, 1 month ago (2012-11-01 23:08:18 UTC) #3
Thanks for great suggestions.

https://codereview.chromium.org/11358047/diff/5001/runtime/vm/intrinsifier.cc
File runtime/vm/intrinsifier.cc (right):

https://codereview.chromium.org/11358047/diff/5001/runtime/vm/intrinsifier.cc...
runtime/vm/intrinsifier.cc:76: if (function.IsClosureFunction()) return false;
On 2012/11/01 23:04:06, siva wrote:
> Should we do the closure function check first because
> to always return false for these and the intrinsic bits will
> never be set.

Done.

https://codereview.chromium.org/11358047/diff/5001/runtime/vm/intrinsifier.cc...
runtime/vm/intrinsifier.cc:90: }
On 2012/11/01 23:04:06, siva wrote:
> Not related to your current change I was wondering if
> we could move the line
> const char*class_name = String::Handle(function_class.Name()).ToCString() to
> after the if check it would save a handle creation for the negative case.
> 
> Also I don't think you need the core_lib, core_impl_lib handles, we could
write
> if (function_class.library() != Library::CoreLibrary() &&
>     function_class.library() != Library::CoreImplLibrary()
>     ....) {
>   return false;
> }

Done.

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

https://codereview.chromium.org/11358047/diff/5001/runtime/vm/object.h#newcod...
runtime/vm/object.h:1277: kUnknownIntrinsic,  // Initial value.
On 2012/11/01 23:04:06, siva wrote:
> kUnknownIntrinsic = 0,

Done.

Powered by Google App Engine
This is Rietveld 408576698