Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(269)

Side by Side Diff: src/jump-target.cc

Issue 42118: Tweak an assertion in the jump target destructor so that it only... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2009 the V8 project authors. All rights reserved. 1 // Copyright 2009 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 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 void JumpTarget::Initialize(CodeGenerator* cgen, Directionality direction) { 63 void JumpTarget::Initialize(CodeGenerator* cgen, Directionality direction) {
64 ASSERT(cgen != NULL); 64 ASSERT(cgen != NULL);
65 ASSERT(cgen_ == NULL); 65 ASSERT(cgen_ == NULL);
66 cgen_ = cgen; 66 cgen_ = cgen;
67 masm_ = cgen->masm(); 67 masm_ = cgen->masm();
68 direction_ = direction; 68 direction_ = direction;
69 } 69 }
70 70
71 71
72 void JumpTarget::Unuse() { 72 void JumpTarget::Unuse() {
73 ASSERT(!is_linked()); 73 // We should not deallocate jump targets that have unresolved jumps
74 // to them. In the event of a compile-time stack overflow or an
75 // unitialized jump target, we don't care.
76 ASSERT(!is_linked() || cgen_ == NULL || cgen_->HasStackOverflow());
74 #ifdef DEBUG 77 #ifdef DEBUG
75 for (int i = 0; i < reaching_frames_.length(); i++) { 78 for (int i = 0; i < reaching_frames_.length(); i++) {
76 ASSERT(reaching_frames_[i] == NULL); 79 ASSERT(reaching_frames_[i] == NULL);
77 } 80 }
78 #endif 81 #endif
79 delete entry_frame_; 82 delete entry_frame_;
80 83
81 Reset(); 84 Reset();
82 } 85 }
83 86
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after
648 temp.CopyTo(this); 651 temp.CopyTo(this);
649 temp.Reset(); // So the destructor does not deallocate virtual frames. 652 temp.Reset(); // So the destructor does not deallocate virtual frames.
650 653
651 #ifdef DEBUG 654 #ifdef DEBUG
652 is_shadowing_ = false; 655 is_shadowing_ = false;
653 #endif 656 #endif
654 } 657 }
655 658
656 659
657 } } // namespace v8::internal 660 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698