OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 10387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
10398 MaybeObject* JSObject::SetElementWithoutInterceptor(uint32_t index, | 10398 MaybeObject* JSObject::SetElementWithoutInterceptor(uint32_t index, |
10399 Object* value, | 10399 Object* value, |
10400 PropertyAttributes attr, | 10400 PropertyAttributes attr, |
10401 StrictModeFlag strict_mode, | 10401 StrictModeFlag strict_mode, |
10402 bool check_prototype, | 10402 bool check_prototype, |
10403 SetPropertyMode set_mode) { | 10403 SetPropertyMode set_mode) { |
10404 ASSERT(HasDictionaryElements() || | 10404 ASSERT(HasDictionaryElements() || |
10405 HasDictionaryArgumentsElements() || | 10405 HasDictionaryArgumentsElements() || |
10406 (attr & (DONT_DELETE | DONT_ENUM | READ_ONLY)) == 0); | 10406 (attr & (DONT_DELETE | DONT_ENUM | READ_ONLY)) == 0); |
10407 Isolate* isolate = GetIsolate(); | 10407 Isolate* isolate = GetIsolate(); |
| 10408 if (FLAG_trace_array_abuse) { |
| 10409 if (IsExternalArrayElementsKind(GetElementsKind())) { |
| 10410 CheckArrayAbuse(this, "external elements write", index); |
| 10411 } |
| 10412 } |
10408 switch (GetElementsKind()) { | 10413 switch (GetElementsKind()) { |
10409 case FAST_SMI_ELEMENTS: | 10414 case FAST_SMI_ELEMENTS: |
10410 case FAST_ELEMENTS: | 10415 case FAST_ELEMENTS: |
10411 case FAST_HOLEY_SMI_ELEMENTS: | 10416 case FAST_HOLEY_SMI_ELEMENTS: |
10412 case FAST_HOLEY_ELEMENTS: | 10417 case FAST_HOLEY_ELEMENTS: |
10413 return SetFastElement(index, value, strict_mode, check_prototype); | 10418 return SetFastElement(index, value, strict_mode, check_prototype); |
10414 case FAST_DOUBLE_ELEMENTS: | 10419 case FAST_DOUBLE_ELEMENTS: |
10415 case FAST_HOLEY_DOUBLE_ELEMENTS: | 10420 case FAST_HOLEY_DOUBLE_ELEMENTS: |
10416 return SetFastDoubleElement(index, value, strict_mode, check_prototype); | 10421 return SetFastDoubleElement(index, value, strict_mode, check_prototype); |
10417 case EXTERNAL_PIXEL_ELEMENTS: { | 10422 case EXTERNAL_PIXEL_ELEMENTS: { |
(...skipping 3474 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
13892 set_year(Smi::FromInt(year), SKIP_WRITE_BARRIER); | 13897 set_year(Smi::FromInt(year), SKIP_WRITE_BARRIER); |
13893 set_month(Smi::FromInt(month), SKIP_WRITE_BARRIER); | 13898 set_month(Smi::FromInt(month), SKIP_WRITE_BARRIER); |
13894 set_day(Smi::FromInt(day), SKIP_WRITE_BARRIER); | 13899 set_day(Smi::FromInt(day), SKIP_WRITE_BARRIER); |
13895 set_weekday(Smi::FromInt(weekday), SKIP_WRITE_BARRIER); | 13900 set_weekday(Smi::FromInt(weekday), SKIP_WRITE_BARRIER); |
13896 set_hour(Smi::FromInt(hour), SKIP_WRITE_BARRIER); | 13901 set_hour(Smi::FromInt(hour), SKIP_WRITE_BARRIER); |
13897 set_min(Smi::FromInt(min), SKIP_WRITE_BARRIER); | 13902 set_min(Smi::FromInt(min), SKIP_WRITE_BARRIER); |
13898 set_sec(Smi::FromInt(sec), SKIP_WRITE_BARRIER); | 13903 set_sec(Smi::FromInt(sec), SKIP_WRITE_BARRIER); |
13899 } | 13904 } |
13900 | 13905 |
13901 } } // namespace v8::internal | 13906 } } // namespace v8::internal |
OLD | NEW |