| 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 448 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 459 | 459 |
| 460 | 460 |
| 461 class FrameDescription { | 461 class FrameDescription { |
| 462 public: | 462 public: |
| 463 FrameDescription(uint32_t frame_size, | 463 FrameDescription(uint32_t frame_size, |
| 464 JSFunction* function); | 464 JSFunction* function); |
| 465 | 465 |
| 466 void* operator new(size_t size, uint32_t frame_size) { | 466 void* operator new(size_t size, uint32_t frame_size) { |
| 467 // Subtracts kPointerSize, as the member frame_content_ already supplies | 467 // Subtracts kPointerSize, as the member frame_content_ already supplies |
| 468 // the first element of the area to store the frame. | 468 // the first element of the area to store the frame. |
| 469 return malloc(size + frame_size - kPointerSize); | 469 return ::operator new(size + frame_size - kPointerSize); |
| 470 } | 470 } |
| 471 | 471 |
| 472 void operator delete(void* pointer, uint32_t frame_size) { | 472 void operator delete(void* pointer, uint32_t frame_size) { |
| 473 free(pointer); | 473 ::operator delete(pointer); |
| 474 } | 474 } |
| 475 | 475 |
| 476 void operator delete(void* description) { | 476 void operator delete(void* description) { |
| 477 free(description); | 477 ::operator delete(description); |
| 478 } | 478 } |
| 479 | 479 |
| 480 uint32_t GetFrameSize() const { | 480 uint32_t GetFrameSize() const { |
| 481 ASSERT(static_cast<uint32_t>(frame_size_) == frame_size_); | 481 ASSERT(static_cast<uint32_t>(frame_size_) == frame_size_); |
| 482 return static_cast<uint32_t>(frame_size_); | 482 return static_cast<uint32_t>(frame_size_); |
| 483 } | 483 } |
| 484 | 484 |
| 485 JSFunction* GetFunction() const { return function_; } | 485 JSFunction* GetFunction() const { return function_; } |
| 486 | 486 |
| 487 unsigned GetOffsetFromSlotIndex(int slot_index); | 487 unsigned GetOffsetFromSlotIndex(int slot_index); |
| (...skipping 434 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 922 Object** expression_stack_; | 922 Object** expression_stack_; |
| 923 int source_position_; | 923 int source_position_; |
| 924 | 924 |
| 925 friend class Deoptimizer; | 925 friend class Deoptimizer; |
| 926 }; | 926 }; |
| 927 #endif | 927 #endif |
| 928 | 928 |
| 929 } } // namespace v8::internal | 929 } } // namespace v8::internal |
| 930 | 930 |
| 931 #endif // V8_DEOPTIMIZER_H_ | 931 #endif // V8_DEOPTIMIZER_H_ |
| OLD | NEW |