https://codereview.chromium.org/23444029/diff/1/src/compiler.cc
File src/compiler.cc (right):
https://codereview.chromium.org/23444029/diff/1/src/compiler.cc#newcode883
src/compiler.cc:883:
info->context()->native_context()->AddOptimizedCode(*code);
On 2013/09/03 21:52:31, Michael Starzinger wrote:
This is a bad choking point to add code to the weak list for two
reasons:
1) The name of this function implies that it only deals with the
optimized code
map, and nothing else.
2) One of the two call-sites (i.e. Compiler::InstallOptimizedCode)
actually only
calls it if there is not yet another optimized code object for the
same native
context in the optimize code map.
Can we hoist this out to the two call-sites and leave this method
untouched?
I've moved it out to the point that the optimized code is transferred
into the CompilationInfo.
https://codereview.chromium.org/23444029/diff/1/src/deoptimizer.cc
File src/deoptimizer.cc (right):
https://codereview.chromium.org/23444029/diff/1/src/deoptimizer.cc#newcode398
src/deoptimizer.cc:398: // (This may actually cause a GC due to a stub
being generated.)
On 2013/09/03 22:03:47, Michael Starzinger wrote:
Is this actually true? Can this cause a GC, I cannot seem to find the
path where
this happens. If it cannot happen, then my comments about
handlification are
obsolete and we also could use a ZoneList<Code*> instead. If it can
happen, then
there are many more stale pointers here.
Right...fixed. No GC tolerated.
https://codereview.chromium.org/23444029/diff/1/src/deoptimizer.cc#newcode419
src/deoptimizer.cc:419: DeoptimizeMarkedCodeForContext(native_context);
On 2013/09/03 21:52:31, Michael Starzinger wrote:
Since DeoptimizeMarkedCodeForContext() might cause a GC, all raw
pointer here
(i.e. native_context) might actually be stale. Better handlify this
function and
the "context" argument to DeoptimizeMarkedCodeForContext() as well.
So; you were right, we don't tolerate GC here--thankfully--so this code
doesn't need to be handlified.
https://codereview.chromium.org/23444029/diff/1/src/deoptimizer.cc#newcode702
src/deoptimizer.cc:702: // count all entries in the deoptimizing code
list of every context.
On 2013/09/03 21:52:31, Michael Starzinger wrote:
nit: Capitalize sentence.
Done.
https://codereview.chromium.org/23444029/diff/1/src/mark-compact.cc
File src/mark-compact.cc (right):
https://codereview.chromium.org/23444029/diff/1/src/mark-compact.cc#newcode3454
src/mark-compact.cc:3454: // Update the heads of the native contexts
list the code to deoptimize list.
On 2013/09/03 21:52:31, Michael Starzinger wrote:
nit: Comment is outdated.
Done.
https://codereview.chromium.org/23444029/diff/1/src/objects.h
File src/objects.h (right):
https://codereview.chromium.org/23444029/diff/1/src/objects.h#newcode7131
src/objects.h:7131: // uses this link to chain together flushing
candidates. Treatly weakly
On 2013/09/03 21:52:31, Michael Starzinger wrote:
nit: s/Treatly/Treated/
This weakly treatly brought to you courtesy of a diseased, geistig
behindert, brain.
https://codereview.chromium.org/23444029/
--
--
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/groups/opt_out.