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/allocation.h" | 8 #include "src/allocation.h" |
9 #include "src/deoptimize-reason.h" | 9 #include "src/deoptimize-reason.h" |
10 #include "src/macro-assembler.h" | 10 #include "src/macro-assembler.h" |
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
350 | 350 |
351 SourcePosition position; | 351 SourcePosition position; |
352 DeoptimizeReason deopt_reason; | 352 DeoptimizeReason deopt_reason; |
353 int deopt_id; | 353 int deopt_id; |
354 | 354 |
355 static const int kNoDeoptId = -1; | 355 static const int kNoDeoptId = -1; |
356 }; | 356 }; |
357 | 357 |
358 static DeoptInfo GetDeoptInfo(Code* code, byte* from); | 358 static DeoptInfo GetDeoptInfo(Code* code, byte* from); |
359 | 359 |
360 static int ComputeSourcePosition(SharedFunctionInfo* shared, | 360 static int ComputeSourcePositionFromBaselineCode(SharedFunctionInfo* shared, |
361 BailoutId node_id); | 361 BailoutId node_id); |
| 362 static int ComputeSourcePositionFromBytecodeArray(SharedFunctionInfo* shared, |
| 363 BailoutId node_id); |
362 | 364 |
363 struct JumpTableEntry : public ZoneObject { | 365 struct JumpTableEntry : public ZoneObject { |
364 inline JumpTableEntry(Address entry, const DeoptInfo& deopt_info, | 366 inline JumpTableEntry(Address entry, const DeoptInfo& deopt_info, |
365 Deoptimizer::BailoutType type, bool frame) | 367 Deoptimizer::BailoutType type, bool frame) |
366 : label(), | 368 : label(), |
367 address(entry), | 369 address(entry), |
368 deopt_info(deopt_info), | 370 deopt_info(deopt_info), |
369 bailout_type(type), | 371 bailout_type(type), |
370 needs_frame(frame) {} | 372 needs_frame(frame) {} |
371 | 373 |
(...skipping 694 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1066 std::vector<Handle<Object> > expression_stack_; | 1068 std::vector<Handle<Object> > expression_stack_; |
1067 int source_position_; | 1069 int source_position_; |
1068 | 1070 |
1069 friend class Deoptimizer; | 1071 friend class Deoptimizer; |
1070 }; | 1072 }; |
1071 | 1073 |
1072 } // namespace internal | 1074 } // namespace internal |
1073 } // namespace v8 | 1075 } // namespace v8 |
1074 | 1076 |
1075 #endif // V8_DEOPTIMIZER_H_ | 1077 #endif // V8_DEOPTIMIZER_H_ |
OLD | NEW |