Thx for the comments, here is an update.

I removed the test. As noted, with the optimized switch to GENERIC without
missing to the runtime, we will underreport generic and overreport polymorphic.
That is reflected in my simple test.

thx!
--Michael


https://codereview.chromium.org/445943002/diff/1/src/ia32/code-stubs-ia32.cc
File src/ia32/code-stubs-ia32.cc (left):

https://codereview.chromium.org/445943002/diff/1/src/ia32/code-stubs-ia32.cc#oldcode2459
src/ia32/code-stubs-ia32.cc:2459: // We are going megamorphic. If the
feedback is a JSFunction, it is fine
On 2014/08/06 14:49:09, Jakob wrote:
Removing optimizations is sad... is the type feedback vector for calls
shared
with optimized code (when it's megamorphic)? Maybe we can just keep
this code --
even though it violates consistency of overall system behavior, maybe
it's an
exception to the rule that we can afford not to care about.

That sounds good to me. I'll move this change to a separate CL which
I'll test against benchmarks.

https://codereview.chromium.org/445943002/diff/1/src/ic.cc
File src/ic.cc (right):

https://codereview.chromium.org/445943002/diff/1/src/ic.cc#newcode1963
src/ic.cc:1963: void CallIC::UpdateTypeFeedbackInfo(Object*
old_feedback, Object* new_feedback) {
On 2014/08/06 14:49:09, Jakob wrote:
nit: 80col

Done.

https://codereview.chromium.org/445943002/diff/1/src/ic.cc#newcode1964
src/ic.cc:1964: // Convert old_feedback to an IC_State enum:
On 2014/08/06 14:49:09, Jakob wrote:
This comment seems to belong to line 1971, but I don't think it adds
much value,
so feel free to just drop it.

Done.

https://codereview.chromium.org/445943002/diff/1/src/ic.cc#newcode1965
src/ic.cc:1965: Code* host = isolate()->
On 2014/08/06 14:49:09, Jakob wrote:
Idea for reducing code duplication: pull out most of this method
(except for
lines 1971, 1972) into a helper with signature (Address*, IC::State
old_state,
IC::State new_state).

The drawback is that you'll have to compute the states before you know
whether
you'll need them; but that should be fairly cheap, and at least some
of the
computations can be avoided: callers of this method know the new_state
in many
(all?) cases, e.g. for vector->set(...MegamorphicSentinel...).

Excellent idea, done. I think the cost of computing a state var is very
cheap.

https://codereview.chromium.org/445943002/

--
--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
--- You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to