From ce2f5dd37514794fed1a98acec84fac9f85f8e2e Mon Sep 17 00:00:00 2001 From: Joel Dice Date: Thu, 3 Jan 2008 14:28:29 -0700 Subject: [PATCH] fix use of clobbered stack register in multianewarray --- src/compile.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/compile.cpp b/src/compile.cpp index b188245932..c6a2dbc135 100644 --- a/src/compile.cpp +++ b/src/compile.cpp @@ -2997,12 +2997,17 @@ compile(MyThread* t, Frame* initialFrame, unsigned ip) if (UNLIKELY(t->exception)) return; PROTECT(t, class_); + Operand* stack = c->temporary(); + c->mov(c->stack(), stack); + c->indirectCall (c->constant(reinterpret_cast(makeMultidimensionalArray)), frame->trace(0, false), - 4, c->thread(), frame->append(class_), c->stack(), + 4, c->thread(), frame->append(class_), stack, c->constant(dimensions)); + c->release(stack); + Operand* result = ::result(c); frame->pop(dimensions);