Remove usage of JSArray in Script object
authorsgjesse@chromium.org <sgjesse@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Fri, 27 Nov 2009 14:10:48 +0000 (14:10 +0000)
committersgjesse@chromium.org <sgjesse@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Fri, 27 Nov 2009 14:10:48 +0000 (14:10 +0000)
commit6d163d9fd0fdef82558944f505f6773824bb2bee
treeab434cbe474daedcb932addac786788088ad82ed
parentc75ff5e8b5dcf51b9a6e8f8c219618f73d8553ef
Remove usage of JSArray in Script object

Storing a JSArray in the Script object could cause an indirect reference from the compilation cache to a global object to be created. Now the line ends are only stored as a FixedArrya and when that is needed in JavaScript a JSArray copy is created. Changed some of the JavaScript code to cache the line ends in a local variable for better performance.

BUG=http://code.google.com/p/v8/issues/detail?id=528
TEST=test/test-api/Bug528
Review URL: http://codereview.chromium.org/434117

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@3374 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
include/v8.h
src/accessors.cc
src/api.cc
src/factory.cc
src/handles.cc
src/messages.js
src/objects-debug.cc
src/objects-inl.h
src/objects.h
test/cctest/test-api.cc
test/cctest/test-debug.cc