Version 3.15.5
Fixed JSON.stringify for objects with interceptor handlers. (Chromium issue 161028)
Fixed corner case in x64 compare stubs. (issue 2416)
Performance and stability improvements on all platforms.
git-svn-id: http://v8.googlecode.com/svn/trunk@13044 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
diff --git a/src/factory.cc b/src/factory.cc
index b5f6c56..556f2b0 100644
--- a/src/factory.cc
+++ b/src/factory.cc
@@ -200,7 +200,7 @@
PretenureFlag pretenure) {
CALL_HEAP_FUNCTION(
isolate(),
- isolate()->heap()->AllocateStringFromAscii(string, pretenure),
+ isolate()->heap()->AllocateStringFromOneByte(string, pretenure),
String);
}
@@ -226,7 +226,7 @@
PretenureFlag pretenure) {
CALL_HEAP_FUNCTION(
isolate(),
- isolate()->heap()->AllocateRawAsciiString(length, pretenure),
+ isolate()->heap()->AllocateRawOneByteString(length, pretenure),
SeqOneByteString);
}
@@ -950,6 +950,9 @@
Handle<JSArray> Factory::NewJSArray(int capacity,
ElementsKind elements_kind,
PretenureFlag pretenure) {
+ if (capacity != 0) {
+ elements_kind = GetHoleyElementsKind(elements_kind);
+ }
CALL_HEAP_FUNCTION(isolate(),
isolate()->heap()->AllocateJSArrayAndStorage(
elements_kind,