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

Unified Diff: runtime/vm/intermediate_language_mips.cc

Issue 149603003: Fix stack height assertion code and free up a bit in the Function tag bits. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | runtime/vm/intermediate_language_x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intermediate_language_mips.cc
===================================================================
--- runtime/vm/intermediate_language_mips.cc (revision 32017)
+++ runtime/vm/intermediate_language_mips.cc (working copy)
@@ -82,24 +82,18 @@
Register result = locs()->in(0).reg();
ASSERT(result == V0);
#if defined(DEBUG)
- // TODO(srdjan): Fix for functions with finally clause.
- // A finally clause may leave a previously pushed return value if it
- // has its own return instruction. Method that have finally are currently
- // not optimized.
- if (!compiler->HasFinally()) {
- Label stack_ok;
- __ Comment("Stack Check");
- __ TraceSimMsg("Stack Check");
- const intptr_t fp_sp_dist =
- (kFirstLocalSlotFromFp + 1 - compiler->StackSize()) * kWordSize;
- ASSERT(fp_sp_dist <= 0);
- __ subu(CMPRES1, SP, FP);
+ Label stack_ok;
+ __ Comment("Stack Check");
+ __ TraceSimMsg("Stack Check");
+ const intptr_t fp_sp_dist =
+ (kFirstLocalSlotFromFp + 1 - compiler->StackSize()) * kWordSize;
+ ASSERT(fp_sp_dist <= 0);
+ __ subu(CMPRES1, SP, FP);
- __ BranchEqual(CMPRES1, fp_sp_dist, &stack_ok);
- __ break_(0);
+ __ BranchEqual(CMPRES1, fp_sp_dist, &stack_ok);
+ __ break_(0);
- __ Bind(&stack_ok);
- }
+ __ Bind(&stack_ok);
#endif
__ LeaveDartFrameAndReturn();
}
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | runtime/vm/intermediate_language_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698