Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(215)

Side by Side Diff: src/factory.h

Issue 1612323003: Introduce {FAST,SLOW}_STRING_WRAPPER_ELEMENTS (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: one more DCHECK fix Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/elements-kind.cc ('k') | src/heap/heap.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_FACTORY_H_ 5 #ifndef V8_FACTORY_H_
6 #define V8_FACTORY_H_ 6 #define V8_FACTORY_H_
7 7
8 #include "src/isolate.h" 8 #include "src/isolate.h"
9 #include "src/messages.h" 9 #include "src/messages.h"
10 #include "src/type-feedback-vector.h" 10 #include "src/type-feedback-vector.h"
(...skipping 377 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 Handle<Map> map, 388 Handle<Map> map,
389 PretenureFlag pretenure = NOT_TENURED, 389 PretenureFlag pretenure = NOT_TENURED,
390 Handle<AllocationSite> allocation_site = Handle<AllocationSite>::null()); 390 Handle<AllocationSite> allocation_site = Handle<AllocationSite>::null());
391 391
392 // JS modules are pretenured. 392 // JS modules are pretenured.
393 Handle<JSModule> NewJSModule(Handle<Context> context, 393 Handle<JSModule> NewJSModule(Handle<Context> context,
394 Handle<ScopeInfo> scope_info); 394 Handle<ScopeInfo> scope_info);
395 395
396 // JS arrays are pretenured when allocated by the parser. 396 // JS arrays are pretenured when allocated by the parser.
397 397
398 // Create a JSArray with no elements.
399 Handle<JSArray> NewJSArray(ElementsKind elements_kind,
400 Strength strength = Strength::WEAK,
401 PretenureFlag pretenure = NOT_TENURED);
402
403 // Create a JSArray with a specified length and elements initialized 398 // Create a JSArray with a specified length and elements initialized
404 // according to the specified mode. 399 // according to the specified mode.
405 Handle<JSArray> NewJSArray( 400 Handle<JSArray> NewJSArray(
406 ElementsKind elements_kind, int length, int capacity, 401 ElementsKind elements_kind, int length, int capacity,
407 Strength strength = Strength::WEAK, 402 Strength strength = Strength::WEAK,
408 ArrayStorageAllocationMode mode = DONT_INITIALIZE_ARRAY_ELEMENTS, 403 ArrayStorageAllocationMode mode = DONT_INITIALIZE_ARRAY_ELEMENTS,
409 PretenureFlag pretenure = NOT_TENURED); 404 PretenureFlag pretenure = NOT_TENURED);
410 405
411 Handle<JSArray> NewJSArray( 406 Handle<JSArray> NewJSArray(
412 int capacity, ElementsKind elements_kind = TERMINAL_FAST_ELEMENTS_KIND, 407 int capacity, ElementsKind elements_kind = TERMINAL_FAST_ELEMENTS_KIND,
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after
697 Handle<Object> GetNumberStringCache(Handle<Object> number); 692 Handle<Object> GetNumberStringCache(Handle<Object> number);
698 693
699 // Update the cache with a new number-string pair. 694 // Update the cache with a new number-string pair.
700 void SetNumberStringCache(Handle<Object> number, Handle<String> string); 695 void SetNumberStringCache(Handle<Object> number, Handle<String> string);
701 696
702 // Creates a function initialized with a shared part. 697 // Creates a function initialized with a shared part.
703 Handle<JSFunction> NewFunction(Handle<Map> map, 698 Handle<JSFunction> NewFunction(Handle<Map> map,
704 Handle<SharedFunctionInfo> info, 699 Handle<SharedFunctionInfo> info,
705 Handle<Context> context, 700 Handle<Context> context,
706 PretenureFlag pretenure = TENURED); 701 PretenureFlag pretenure = TENURED);
702
703 // Create a JSArray with no elements and no length.
704 Handle<JSArray> NewJSArray(ElementsKind elements_kind,
705 Strength strength = Strength::WEAK,
706 PretenureFlag pretenure = NOT_TENURED);
707 }; 707 };
708 708
709 } // namespace internal 709 } // namespace internal
710 } // namespace v8 710 } // namespace v8
711 711
712 #endif // V8_FACTORY_H_ 712 #endif // V8_FACTORY_H_
OLDNEW
« no previous file with comments | « src/elements-kind.cc ('k') | src/heap/heap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698