Chromium Code Reviews| 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 492 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 503 | 503 |
| 504 double GetDoubleFrameSlot(unsigned offset) { | 504 double GetDoubleFrameSlot(unsigned offset) { |
| 505 intptr_t* ptr = GetFrameSlotPointer(offset); | 505 intptr_t* ptr = GetFrameSlotPointer(offset); |
| 506 return read_double_value(reinterpret_cast<Address>(ptr)); | 506 return read_double_value(reinterpret_cast<Address>(ptr)); |
| 507 } | 507 } |
| 508 | 508 |
| 509 void SetFrameSlot(unsigned offset, intptr_t value) { | 509 void SetFrameSlot(unsigned offset, intptr_t value) { |
| 510 *GetFrameSlotPointer(offset) = value; | 510 *GetFrameSlotPointer(offset) = value; |
| 511 } | 511 } |
| 512 | 512 |
| 513 void SetCallerPc(unsigned offset, intptr_t value) { | |
|
danno
2013/07/18 10:51:24
A difference copy of this routine should be in the
haitao.feng
2013/07/18 12:18:20
Done.
| |
| 514 if (kPCOnStackSize != kPointerSize) { | |
| 515 ASSERT(kPCOnStackSize == kPointerSize + kPointerSize); | |
| 516 SetFrameSlot(offset + kPointerSize, 0); | |
|
danno
2013/07/18 10:51:24
This assumes little endianess, I would much prefer
haitao.feng
2013/07/18 12:18:20
Done.
| |
| 517 } | |
| 518 SetFrameSlot(offset, value); | |
| 519 } | |
| 520 | |
| 521 void SetCallerFp(unsigned offset, intptr_t value) { | |
|
danno
2013/07/18 10:51:24
Same as above, there should be a different impleme
haitao.feng
2013/07/18 12:18:20
Done.
| |
| 522 if (kFPOnStackSize != kPointerSize) { | |
| 523 ASSERT(kFPOnStackSize == kPointerSize + kPointerSize); | |
| 524 SetFrameSlot(offset + kPointerSize, 0); | |
| 525 } | |
| 526 SetFrameSlot(offset, value); | |
| 527 } | |
| 528 | |
| 513 intptr_t GetRegister(unsigned n) const { | 529 intptr_t GetRegister(unsigned n) const { |
| 514 ASSERT(n < ARRAY_SIZE(registers_)); | 530 ASSERT(n < ARRAY_SIZE(registers_)); |
| 515 return registers_[n]; | 531 return registers_[n]; |
| 516 } | 532 } |
| 517 | 533 |
| 518 double GetDoubleRegister(unsigned n) const { | 534 double GetDoubleRegister(unsigned n) const { |
| 519 ASSERT(n < ARRAY_SIZE(double_registers_)); | 535 ASSERT(n < ARRAY_SIZE(double_registers_)); |
| 520 return double_registers_[n]; | 536 return double_registers_[n]; |
| 521 } | 537 } |
| 522 | 538 |
| (...skipping 423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 946 Object** expression_stack_; | 962 Object** expression_stack_; |
| 947 int source_position_; | 963 int source_position_; |
| 948 | 964 |
| 949 friend class Deoptimizer; | 965 friend class Deoptimizer; |
| 950 }; | 966 }; |
| 951 #endif | 967 #endif |
| 952 | 968 |
| 953 } } // namespace v8::internal | 969 } } // namespace v8::internal |
| 954 | 970 |
| 955 #endif // V8_DEOPTIMIZER_H_ | 971 #endif // V8_DEOPTIMIZER_H_ |
| OLD | NEW |