| Index: src/full-codegen.h
|
| ===================================================================
|
| --- src/full-codegen.h (revision 9827)
|
| +++ src/full-codegen.h (working copy)
|
| @@ -83,7 +83,6 @@
|
| scope_(NULL),
|
| nesting_stack_(NULL),
|
| loop_depth_(0),
|
| - stack_height_(0),
|
| context_(NULL),
|
| bailout_entries_(0),
|
| stack_checks_(2), // There's always at least one.
|
| @@ -539,35 +538,6 @@
|
| loop_depth_--;
|
| }
|
|
|
| -#if defined(V8_TARGET_ARCH_IA32)
|
| - int stack_height() { return stack_height_; }
|
| - void set_stack_height(int depth) { stack_height_ = depth; }
|
| - void increment_stack_height() { stack_height_++; }
|
| - void increment_stack_height(int delta) { stack_height_ += delta; }
|
| - void decrement_stack_height() {
|
| - if (FLAG_verify_stack_height) {
|
| - ASSERT(stack_height_ > 0);
|
| - }
|
| - stack_height_--;
|
| - }
|
| - void decrement_stack_height(int delta) {
|
| - stack_height_-= delta;
|
| - if (FLAG_verify_stack_height) {
|
| - ASSERT(stack_height_ >= 0);
|
| - }
|
| - }
|
| - // Call this function only if FLAG_verify_stack_height is true.
|
| - void verify_stack_height(); // Generates a runtime check of esp - ebp.
|
| -#else
|
| - int stack_height() { return 0; }
|
| - void set_stack_height(int depth) {}
|
| - void increment_stack_height() {}
|
| - void increment_stack_height(int delta) {}
|
| - void decrement_stack_height() {}
|
| - void decrement_stack_height(int delta) {}
|
| - void verify_stack_height() {}
|
| -#endif // V8_TARGET_ARCH_IA32
|
| -
|
| MacroAssembler* masm() { return masm_; }
|
|
|
| class ExpressionContext;
|
| @@ -630,10 +600,6 @@
|
|
|
| virtual ~ExpressionContext() {
|
| codegen_->set_new_context(old_);
|
| - if (FLAG_verify_stack_height) {
|
| - ASSERT_EQ(expected_stack_height_, codegen()->stack_height());
|
| - codegen()->verify_stack_height();
|
| - }
|
| }
|
|
|
| Isolate* isolate() const { return codegen_->isolate(); }
|
| @@ -687,7 +653,6 @@
|
| FullCodeGenerator* codegen() const { return codegen_; }
|
| MacroAssembler* masm() const { return masm_; }
|
| MacroAssembler* masm_;
|
| - int expected_stack_height_; // The expected stack height esp - ebp on exit.
|
|
|
| private:
|
| const ExpressionContext* old_;
|
| @@ -697,9 +662,7 @@
|
| class AccumulatorValueContext : public ExpressionContext {
|
| public:
|
| explicit AccumulatorValueContext(FullCodeGenerator* codegen)
|
| - : ExpressionContext(codegen) {
|
| - expected_stack_height_ = codegen->stack_height();
|
| - }
|
| + : ExpressionContext(codegen) { }
|
|
|
| virtual void Plug(bool flag) const;
|
| virtual void Plug(Register reg) const;
|
| @@ -720,9 +683,7 @@
|
| class StackValueContext : public ExpressionContext {
|
| public:
|
| explicit StackValueContext(FullCodeGenerator* codegen)
|
| - : ExpressionContext(codegen) {
|
| - expected_stack_height_ = codegen->stack_height() + 1;
|
| - }
|
| + : ExpressionContext(codegen) { }
|
|
|
| virtual void Plug(bool flag) const;
|
| virtual void Plug(Register reg) const;
|
| @@ -751,9 +712,7 @@
|
| condition_(condition),
|
| true_label_(true_label),
|
| false_label_(false_label),
|
| - fall_through_(fall_through) {
|
| - expected_stack_height_ = codegen->stack_height();
|
| - }
|
| + fall_through_(fall_through) { }
|
|
|
| static const TestContext* cast(const ExpressionContext* context) {
|
| ASSERT(context->IsTest());
|
| @@ -790,11 +749,8 @@
|
| class EffectContext : public ExpressionContext {
|
| public:
|
| explicit EffectContext(FullCodeGenerator* codegen)
|
| - : ExpressionContext(codegen) {
|
| - expected_stack_height_ = codegen->stack_height();
|
| - }
|
| + : ExpressionContext(codegen) { }
|
|
|
| -
|
| virtual void Plug(bool flag) const;
|
| virtual void Plug(Register reg) const;
|
| virtual void Plug(Label* materialize_true, Label* materialize_false) const;
|
| @@ -817,7 +773,6 @@
|
| Label return_label_;
|
| NestedStatement* nesting_stack_;
|
| int loop_depth_;
|
| - int stack_height_;
|
| const ExpressionContext* context_;
|
| ZoneList<BailoutEntry> bailout_entries_;
|
| ZoneList<BailoutEntry> stack_checks_;
|
|
|