Changeset 246380 in webkit
- Timestamp:
- Jun 12, 2019, 3:20:56 PM (7 years ago)
- Location:
- branches/safari-607-branch/Source/JavaScriptCore
- Files:
-
- 2 edited
-
ChangeLog (modified) (1 diff)
-
runtime/JSObject.cpp (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/safari-607-branch/Source/JavaScriptCore/ChangeLog
r246379 r246380 1 2019-06-12 Null <null@apple.com> 2 3 Cherry-pick r246084. rdar://problem/51656856 4 5 Unreviewed, update exception scope for putByIndexBeyondVectorLength 6 https://bugs.webkit.org/show_bug.cgi?id=198477 7 8 * runtime/JSObject.cpp: 9 (JSC::JSObject::putByIndexBeyondVectorLength): 10 11 git-svn-id: https://svn.webkit.org/repository/webkit/trunk@246084 268f45cc-cd09-0410-ab3c-d52691b4dbfc 12 13 2019-06-04 Yusuke Suzuki <ysuzuki@apple.com> 14 15 Unreviewed, update exception scope for putByIndexBeyondVectorLength 16 https://bugs.webkit.org/show_bug.cgi?id=198477 17 18 * runtime/JSObject.cpp: 19 (JSC::JSObject::putByIndexBeyondVectorLength): 20 1 21 2019-06-12 Null <null@apple.com> 2 22 -
branches/safari-607-branch/Source/JavaScriptCore/runtime/JSObject.cpp
r246378 r246380 2869 2869 { 2870 2870 VM& vm = exec->vm(); 2871 auto scope = DECLARE_THROW_SCOPE(vm); 2871 2872 2872 2873 RELEASE_ASSERT_WITH_SECURITY_IMPLICATION(!isCopyOnWrite(indexingMode())); … … 2878 2879 case ALL_BLANK_INDEXING_TYPES: { 2879 2880 if (indexingShouldBeSparse(vm)) { 2880 returnputByIndexBeyondVectorLengthWithArrayStorage(2881 RELEASE_AND_RETURN(scope, putByIndexBeyondVectorLengthWithArrayStorage( 2881 2882 exec, i, value, shouldThrow, 2882 ensureArrayStorageExistsAndEnterDictionaryIndexingMode(vm)) ;2883 ensureArrayStorageExistsAndEnterDictionaryIndexingMode(vm))); 2883 2884 } 2884 2885 if (indexIsSufficientlyBeyondLengthForSparseMap(i, 0) || i >= MIN_SPARSE_ARRAY_INDEX) { 2885 return putByIndexBeyondVectorLengthWithArrayStorage( 2886 exec, i, value, shouldThrow, createArrayStorage(vm, 0, 0)); 2886 RELEASE_AND_RETURN(scope, putByIndexBeyondVectorLengthWithArrayStorage(exec, i, value, shouldThrow, createArrayStorage(vm, 0, 0))); 2887 2887 } 2888 2888 if (needsSlowPutIndexing(vm)) { 2889 2889 // Convert the indexing type to the SlowPutArrayStorage and retry. 2890 2890 createArrayStorage(vm, i + 1, getNewVectorLength(vm, 0, 0, 0, i + 1)); 2891 return putByIndex(this, exec, i, value, shouldThrow);2891 RELEASE_AND_RETURN(scope, putByIndex(this, exec, i, value, shouldThrow)); 2892 2892 } 2893 2893 … … 2902 2902 2903 2903 case ALL_INT32_INDEXING_TYPES: 2904 return putByIndexBeyondVectorLengthWithoutAttributes<Int32Shape>(exec, i, value);2904 RELEASE_AND_RETURN(scope, putByIndexBeyondVectorLengthWithoutAttributes<Int32Shape>(exec, i, value)); 2905 2905 2906 2906 case ALL_DOUBLE_INDEXING_TYPES: 2907 return putByIndexBeyondVectorLengthWithoutAttributes<DoubleShape>(exec, i, value);2907 RELEASE_AND_RETURN(scope, putByIndexBeyondVectorLengthWithoutAttributes<DoubleShape>(exec, i, value)); 2908 2908 2909 2909 case ALL_CONTIGUOUS_INDEXING_TYPES: 2910 return putByIndexBeyondVectorLengthWithoutAttributes<ContiguousShape>(exec, i, value);2910 RELEASE_AND_RETURN(scope, putByIndexBeyondVectorLengthWithoutAttributes<ContiguousShape>(exec, i, value)); 2911 2911 2912 2912 case NonArrayWithSlowPutArrayStorage: 2913 2913 case ArrayWithSlowPutArrayStorage: { 2914 2914 // No own property present in the vector, but there might be in the sparse map! 2915 auto scope = DECLARE_THROW_SCOPE(vm);2916 2915 SparseArrayValueMap* map = arrayStorage()->m_sparseMap.get(); 2917 2916 bool putResult = false; … … 2922 2921 return putResult; 2923 2922 } 2924 scope.release();2925 2923 FALLTHROUGH; 2926 2924 } … … 2928 2926 case NonArrayWithArrayStorage: 2929 2927 case ArrayWithArrayStorage: 2930 return putByIndexBeyondVectorLengthWithArrayStorage(exec, i, value, shouldThrow, arrayStorage());2928 RELEASE_AND_RETURN(scope, putByIndexBeyondVectorLengthWithArrayStorage(exec, i, value, shouldThrow, arrayStorage())); 2931 2929 2932 2930 default:
Note:
See TracChangeset
for help on using the changeset viewer.