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

Side by Side Diff: src/objects.cc

Issue 1312413002: Move runtime helper for JSSet and JSMap onto objects. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 3 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/objects.h ('k') | src/runtime/runtime.h » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 #include "src/objects.h" 5 #include "src/objects.h"
6 6
7 #include <iomanip> 7 #include <iomanip>
8 #include <sstream> 8 #include <sstream>
9 9
10 #include "src/accessors.h" 10 #include "src/accessors.h"
(...skipping 15109 matching lines...) Expand 10 before | Expand all | Expand 10 after
15120 template void 15120 template void
15121 OrderedHashTableIterator<JSMapIterator, OrderedHashMap>::MoveNext(); 15121 OrderedHashTableIterator<JSMapIterator, OrderedHashMap>::MoveNext();
15122 15122
15123 template Object* 15123 template Object*
15124 OrderedHashTableIterator<JSMapIterator, OrderedHashMap>::CurrentKey(); 15124 OrderedHashTableIterator<JSMapIterator, OrderedHashMap>::CurrentKey();
15125 15125
15126 template void 15126 template void
15127 OrderedHashTableIterator<JSMapIterator, OrderedHashMap>::Transition(); 15127 OrderedHashTableIterator<JSMapIterator, OrderedHashMap>::Transition();
15128 15128
15129 15129
15130 void JSSet::Initialize(Handle<JSSet> set, Isolate* isolate) {
15131 Handle<OrderedHashSet> table = isolate->factory()->NewOrderedHashSet();
15132 set->set_table(*table);
15133 }
15134
15135
15136 void JSSet::Clear(Handle<JSSet> set) {
15137 Handle<OrderedHashSet> table(OrderedHashSet::cast(set->table()));
15138 table = OrderedHashSet::Clear(table);
15139 set->set_table(*table);
15140 }
15141
15142
15143 void JSMap::Initialize(Handle<JSMap> map, Isolate* isolate) {
15144 Handle<OrderedHashMap> table = isolate->factory()->NewOrderedHashMap();
15145 map->set_table(*table);
15146 }
15147
15148
15149 void JSMap::Clear(Handle<JSMap> map) {
15150 Handle<OrderedHashMap> table(OrderedHashMap::cast(map->table()));
15151 table = OrderedHashMap::Clear(table);
15152 map->set_table(*table);
15153 }
15154
15155
15130 // Check if there is a break point at this code position. 15156 // Check if there is a break point at this code position.
15131 bool DebugInfo::HasBreakPoint(int code_position) { 15157 bool DebugInfo::HasBreakPoint(int code_position) {
15132 // Get the break point info object for this code position. 15158 // Get the break point info object for this code position.
15133 Object* break_point_info = GetBreakPointInfo(code_position); 15159 Object* break_point_info = GetBreakPointInfo(code_position);
15134 15160
15135 // If there is no break point info object or no break points in the break 15161 // If there is no break point info object or no break points in the break
15136 // point info object there is no break point at this code position. 15162 // point info object there is no break point at this code position.
15137 if (break_point_info->IsUndefined()) return false; 15163 if (break_point_info->IsUndefined()) return false;
15138 return BreakPointInfo::cast(break_point_info)->GetBreakPointCount() > 0; 15164 return BreakPointInfo::cast(break_point_info)->GetBreakPointCount() > 0;
15139 } 15165 }
(...skipping 562 matching lines...) Expand 10 before | Expand all | Expand 10 after
15702 if (cell->value() != *new_value) { 15728 if (cell->value() != *new_value) {
15703 cell->set_value(*new_value); 15729 cell->set_value(*new_value);
15704 Isolate* isolate = cell->GetIsolate(); 15730 Isolate* isolate = cell->GetIsolate();
15705 cell->dependent_code()->DeoptimizeDependentCodeGroup( 15731 cell->dependent_code()->DeoptimizeDependentCodeGroup(
15706 isolate, DependentCode::kPropertyCellChangedGroup); 15732 isolate, DependentCode::kPropertyCellChangedGroup);
15707 } 15733 }
15708 } 15734 }
15709 15735
15710 } // namespace internal 15736 } // namespace internal
15711 } // namespace v8 15737 } // namespace v8
OLDNEW
« no previous file with comments | « src/objects.h ('k') | src/runtime/runtime.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698