OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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_DEOPTIMIZER_H_ | 5 #ifndef V8_DEOPTIMIZER_H_ |
6 #define V8_DEOPTIMIZER_H_ | 6 #define V8_DEOPTIMIZER_H_ |
7 | 7 |
8 #include "src/v8.h" | 8 #include "src/v8.h" |
9 | 9 |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
170 static void DeoptimizeAll(Isolate* isolate); | 170 static void DeoptimizeAll(Isolate* isolate); |
171 | 171 |
172 // Deoptimize code associated with the given global object. | 172 // Deoptimize code associated with the given global object. |
173 static void DeoptimizeGlobalObject(JSObject* object); | 173 static void DeoptimizeGlobalObject(JSObject* object); |
174 | 174 |
175 // Deoptimizes all optimized code that has been previously marked | 175 // Deoptimizes all optimized code that has been previously marked |
176 // (via code->set_marked_for_deoptimization) and unlinks all functions that | 176 // (via code->set_marked_for_deoptimization) and unlinks all functions that |
177 // refer to that code. | 177 // refer to that code. |
178 static void DeoptimizeMarkedCode(Isolate* isolate); | 178 static void DeoptimizeMarkedCode(Isolate* isolate); |
179 | 179 |
180 static void PatchStackForMarkedCode(Isolate* isolate); | |
181 | |
182 // Visit all the known optimized functions in a given isolate. | 180 // Visit all the known optimized functions in a given isolate. |
183 static void VisitAllOptimizedFunctions( | 181 static void VisitAllOptimizedFunctions( |
184 Isolate* isolate, OptimizedFunctionVisitor* visitor); | 182 Isolate* isolate, OptimizedFunctionVisitor* visitor); |
185 | 183 |
186 // The size in bytes of the code required at a lazy deopt patch site. | 184 // The size in bytes of the code required at a lazy deopt patch site. |
187 static int patch_size(); | 185 static int patch_size(); |
188 | 186 |
189 ~Deoptimizer(); | 187 ~Deoptimizer(); |
190 | 188 |
191 void MaterializeHeapObjects(JavaScriptFrameIterator* it); | 189 void MaterializeHeapObjects(JavaScriptFrameIterator* it); |
(...skipping 776 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
968 Object** parameters_; | 966 Object** parameters_; |
969 Object** expression_stack_; | 967 Object** expression_stack_; |
970 int source_position_; | 968 int source_position_; |
971 | 969 |
972 friend class Deoptimizer; | 970 friend class Deoptimizer; |
973 }; | 971 }; |
974 | 972 |
975 } } // namespace v8::internal | 973 } } // namespace v8::internal |
976 | 974 |
977 #endif // V8_DEOPTIMIZER_H_ | 975 #endif // V8_DEOPTIMIZER_H_ |
OLD | NEW |