Home | History | Annotate | Download | only in src

Lines Matching refs:elements

264   // Normalize the elements of the boilerplate to save space if needed.
367 Handle<FixedArray> elements) {
377 static_cast<ElementsKind>(Smi::cast(elements->get(0))->value());
379 FixedArrayBase::cast(elements->get(1)));
456 Handle<FixedArray> elements = CompileTimeValue::GetElements(array);
462 elements,
468 elements,
473 isolate, literals, elements);
537 Handle<FixedArray> elements) {
542 ASSERT(*elements != isolate->heap()->empty_fixed_array());
544 Runtime::CreateArrayLiteralBoilerplate(isolate, literals, elements);
562 CONVERT_ARG_HANDLE_CHECKED(FixedArray, elements, 2);
565 literals_index, elements);
578 CONVERT_ARG_HANDLE_CHECKED(FixedArray, elements, 2);
581 literals_index, elements);
585 if (boilerplate->elements()->map() ==
917 Handle<ExternalArray> elements =
921 holder->set_elements(*elements);
983 Handle<ExternalArray> elements =
987 holder->set_elements(*elements);
2439 FixedArray* elements = FixedArray::cast(new_object);
2452 array->set_elements(elements);
2539 // This is necessary to enable fast checks for absence of elements
3139 bool HasCapacity(int elements) {
3141 int required_length = length_ + elements;
3145 void EnsureCapacity(int elements) {
3147 int required_length = length_ + elements;
3254 void EnsureCapacity(int elements) {
3255 array_builder_.EnsureCapacity(elements);
3893 // all components to use two elements when encoded as two smis.
4414 Handle<FixedArray> elements = isolate->factory()->NewFixedArray(matches);
4417 elements->set(0, *substring);
4424 elements->set(i, *substring);
4426 Handle<JSArray> result = isolate->factory()->NewJSArrayWithElements(elements);
4478 Handle<FixedArray>(FixedArray::cast(result_array->elements()));
4523 Handle<FixedArray> elements =
4526 elements->set(0, *match);
4534 elements->set(i, *substring);
4537 elements->set(i, isolate->heap()->undefined_value());
4540 elements->set(capture_count + 1, Smi::FromInt(match_start));
4541 elements->set(capture_count + 2, *subject);
4542 builder.Add(*isolate->factory()->NewJSArrayWithElements(elements));
4887 // definite out-of-bounds access to elements, which is a strong indicator
4889 // transition elements to FAST_*_ELEMENTS to avoid excessive boxing of
4890 // doubles for those future calls in the case that the elements would
4895 FixedArrayBase* elements = js_object->elements();
4896 if (args.at<Smi>(1)->value() >= elements->length()) {
5358 FixedDoubleArray* double_array = FixedDoubleArray::cast(object->elements());
5373 FixedArray* object_array = FixedArray::cast(object->elements());
6510 FixedArray::cast(result->elements())->set(0, *subject);
6514 Handle<FixedArray> elements(FixedArray::cast(result->elements()));
6521 elements->set(i, *substring);
6530 *elements,
6545 FixedArray* elements,
6551 WriteBarrierMode mode = elements->GetWriteBarrierMode(no_gc);
6555 elements->set(i, value, mode);
6559 memset(elements->data_start() + i, 0, kPointerSize * (length - i));
6563 Object* element = elements->get(j);
6583 Handle<FixedArray> elements;
6592 elements = Handle<FixedArray>(FixedArray::cast(obj), isolate);
6597 // Note, this will initialize all elements (not only the prefix)
6601 *elements,
6604 MemsetPointer(elements->data_start(),
6609 elements = isolate->factory()->NewFixedArray(length);
6614 elements->set(i, *str);
6619 ASSERT(String::cast(elements->get(i))->length() == 1);
6623 return *isolate->factory()->NewJSArrayWithElements(elements);
6917 FixedArray* fixed_array = FixedArray::cast(array->elements());
7027 FixedArray* fixed_array = FixedArray::cast(array->elements());
7098 static void JoinSparseArrayWithSeparator(FixedArray* elements,
7107 int position = NumberToInt32(elements->get(i));
7108 String* string = String::cast(elements->get(i + 1));
7148 // separator is string to put between elements. Assumed to be non-empty.
7163 FixedArray* elements = FixedArray::cast(elements_array->elements());
7165 RUNTIME_ASSERT(elements->get(i)->IsNumber());
7166 RUNTIME_ASSERT(elements->get(i + 1)->IsString());
7167 String* string = String::cast(elements->get(i + 1));
7209 JoinSparseArrayWithSeparator<uint8_t>(elements,
7223 JoinSparseArrayWithSeparator<uc16>(elements,
7800 // Allocate the elements if needed.
7871 // If there is no aliasing, the arguments object elements are not
7873 Handle<FixedArray> elements =
7875 result->set_elements(*elements);
7877 elements->set(i, *(parameters - i - 1));
7898 // Allocate the elements if needed.
9433 FixedArray* output_array = FixedArray::cast(output->elements());
9683 FixedArray* elements = FixedArray::cast(array->elements());
9685 if (elements->get(i) == element) return isolate->heap()->false_value();
9699 * The backend storage can be a fixed array for fast elements case,
9838 // Fast elements can't have lengths that are not representable by
9842 Handle<FixedArray> elements(FixedArray::cast(array->elements()));
9844 if (!elements->get(i)->IsTheHole()) element_count++;
9850 // Fast elements can't have lengths that are not representable by
9854 if (array->elements()->IsFixedArray()) {
9855 ASSERT(FixedArray::cast(array->elements())->length() == 0);
9858 Handle<FixedDoubleArray> elements(
9859 FixedDoubleArray::cast(array->elements()));
9861 if (!elements->is_the_hole(i)) element_count++;
9867 SeededNumberDictionary::cast(array->elements()));
9891 // inherited elements.
9904 ExternalArrayClass::cast(receiver->elements()));
9958 Handle<FixedArray> elements(FixedArray::cast(object->elements()));
9959 uint32_t length = static_cast<uint32_t>(elements->length());
9962 if (!elements->get(i)->IsTheHole()) {
9976 SeededNumberDictionary::cast(object->elements()));
9996 ExternalPixelArray::cast(object->elements())->length();
10001 ExternalByteArray::cast(object->elements())->length();
10006 ExternalUnsignedByteArray::cast(object->elements())->length();
10011 ExternalShortArray::cast(object->elements())->length();
10016 ExternalUnsignedShortArray::cast(object->elements())->length();
10021 ExternalIntArray::cast(object->elements())->length();
10026 ExternalUnsignedIntArray::cast(object->elements())->length();
10031 ExternalFloatArray::cast(object->elements())->length();
10036 ExternalDoubleArray::cast(object->elements())->length();
10069 * A helper function that visits elements of a JSArray in numerical
10087 // Run through the elements FixedArray and use HasElement and GetElement
10088 // to check the prototype for missing elements.
10089 Handle<FixedArray> elements(FixedArray::cast(receiver->elements()));
10091 ASSERT(fast_length <= elements->length());
10094 Handle<Object> element_value(elements->get(j), isolate);
10109 // Run through the elements FixedArray and use HasElement and GetElement
10110 // to check the prototype for missing elements.
10111 Handle<FixedDoubleArray> elements(
10112 FixedDoubleArray::cast(receiver->elements()));
10114 ASSERT(fast_length <= elements->length());
10117 if (!elements->is_the_hole(j)) {
10118 double double_value = elements->get_scalar(j);
10156 receiver->elements()));
10225 Handle<FixedArray> elements(FixedArray::cast(arguments->elements()));
10227 // Pass 1: estimate the length and number of elements of the result.
10230 // The number of elements is precise if there are no inherited elements.
10238 Handle<Object> obj(elements->get(i), isolate);
10280 // If estimated number of elements is more than half of length, a
10293 Handle<Object> obj(elements->get(i), isolate);
10306 // Empty fixed array indicates that there are no elements.
10307 if (array->elements()->IsFixedArray()) break;
10308 FixedDoubleArray* elements =
10309 FixedDoubleArray::cast(array->elements());
10311 if (elements->is_the_hole(i)) {
10315 double double_value = elements->get_scalar(i);
10323 FixedArray* elements(
10324 FixedArray::cast(array->elements()));
10326 Object* element = elements->get(i);
10355 // The backing storage array must have non-existing elements to preserve
10370 Handle<Object> obj(elements->get(i), isolate);
10408 // Moves all own elements of an object, that are below a limit, to positions
10412 // Returns the number of non-undefined elements collected.
10430 FixedArrayBase* new_elements = from->elements();
10448 // How many elements does this object/array have?
10453 HeapObject* elements = object->elements();
10454 if (elements->IsDictionary()) {
10455 int result = SeededNumberDictionary::cast(elements)->NumberOfElements();
10460 return Smi::FromInt(FixedArray::cast(elements)->length());
10466 // might have elements. Can either return an array of keys (positive integers
10475 if (array->elements()->IsDictionary()) {
10502 uint32_t actual_length = static_cast<uint32_t>(array->elements()->length());
14143 Handle<FixedArray> elements = factory->NewFixedArray(entry_count);
14162 elements->set(index++, *pair); \
14171 Handle<JSArray> result = factory->NewJSArrayWithElements(elements);
14220 // Properties test sitting with elements tests - not fooling anyone.