| Index: src/arm/full-codegen-arm.cc
|
| diff --git a/src/arm/full-codegen-arm.cc b/src/arm/full-codegen-arm.cc
|
| index 7716e858d8222960e3de17ffbad84e51f5a30a08..41f02be2594fc88ce829390880104cd853402ce8 100644
|
| --- a/src/arm/full-codegen-arm.cc
|
| +++ b/src/arm/full-codegen-arm.cc
|
| @@ -4366,7 +4366,10 @@ void FullCodeGenerator::EmitUnaryOperation(UnaryOperation* expr,
|
| const char* comment) {
|
| // TODO(svenpanne): Allowing format strings in Comment would be nice here...
|
| Comment cmt(masm_, comment);
|
| - UnaryOpStub stub(expr->op());
|
| + bool can_overwrite = expr->expression()->ResultOverwriteAllowed();
|
| + UnaryOverwriteMode overwrite =
|
| + can_overwrite ? UNARY_OVERWRITE : UNARY_NO_OVERWRITE;
|
| + UnaryOpStub stub(expr->op(), overwrite);
|
| // UnaryOpStub expects the argument to be in the
|
| // accumulator register r0.
|
| VisitForAccumulatorValue(expr->expression());
|
|
|