If you're interested in my opinion, I think the approach looks
promising, but there are some issues:
1. A function may also have a compiled construct stub and an initial
map that need to be updated.
2. There may be (direct) references in generated code to old code for
the function. Since there's already heap traversal involved they can
be found and patched (in another pass). Alternative approach is to
make the old code object patch its callers to the new location.
3. If we're currently running (and maybe debugging) the function being
patched we might want to restart it.

-- Vitaly

On Sun, Jan 24, 2010 at 12:52 PM,  <pfeld...@chromium.org> wrote:
> Looks interesting. Couple of questions:
> 0) Could you send it to Vitaly to get his review?
> 1) Will this generate AFTER_COMPILE event?
> 2) Can we act as Eclipse for the cases when new script does not compile?
> (replace body with "throw 'Syntax error: ...';" )
>
>
> http://codereview.chromium.org/546125/diff/4001/4002
> File src/debug-delay.js (right):
>
> http://codereview.chromium.org/546125/diff/4001/4002#newcode748
> src/debug-delay.js:748: Debug.change_script_live = function(script, pos,
> old_len, new_str) {
> I'd call it something like 'patch_script'. Also comment on what it does
> would be nice.
>
> http://codereview.chromium.org/546125/diff/4001/4003
> File src/runtime.cc (right):
>
> http://codereview.chromium.org/546125/diff/4001/4003#newcode7936
> src/runtime.cc:7936: static Object*
> Runtime_GetOverlappingFunctionInfos(Arguments args) {
> It is strange that mutator has a Get* name. Also, debugger functions are
> generally called Runtime_Debug*.
>
> http://codereview.chromium.org/546125
>
> --
> v8-dev mailing list
> v8-dev@googlegroups.com
> http://groups.google.com/group/v8-dev
>

-- 
v8-dev mailing list
v8-dev@googlegroups.com
http://groups.google.com/group/v8-dev

Reply via email to