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

Side by Side Diff: src/mips/code-stubs-mips.cc

Issue 7068002: MIPS: Fixed two bugs related to double function calls. (Closed)
Patch Set: Created 9 years, 7 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
« no previous file with comments | « no previous file | src/mips/macro-assembler-mips.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 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 3421 matching lines...) Expand 10 before | Expand all | Expand 10 after
3432 // an untagged smi. Allocate a heap number and call a 3432 // an untagged smi. Allocate a heap number and call a
3433 // C function for integer exponents. The register containing 3433 // C function for integer exponents. The register containing
3434 // the heap number is callee-saved. 3434 // the heap number is callee-saved.
3435 __ AllocateHeapNumber(heapnumber, 3435 __ AllocateHeapNumber(heapnumber,
3436 scratch, 3436 scratch,
3437 scratch2, 3437 scratch2,
3438 heapnumbermap, 3438 heapnumbermap,
3439 &call_runtime); 3439 &call_runtime);
3440 __ push(ra); 3440 __ push(ra);
3441 __ PrepareCallCFunction(3, scratch); 3441 __ PrepareCallCFunction(3, scratch);
3442 __ SetCallCDoubleArguments(double_base, double_exponent); 3442 __ SetCallCDoubleArguments(double_base, exponent);
3443 __ CallCFunction( 3443 __ CallCFunction(
3444 ExternalReference::power_double_int_function(masm->isolate()), 4); 3444 ExternalReference::power_double_int_function(masm->isolate()), 3);
3445 __ pop(ra); 3445 __ pop(ra);
3446 __ GetCFunctionDoubleResult(double_result); 3446 __ GetCFunctionDoubleResult(double_result);
3447 __ sdc1(double_result, 3447 __ sdc1(double_result,
3448 FieldMemOperand(heapnumber, HeapNumber::kValueOffset)); 3448 FieldMemOperand(heapnumber, HeapNumber::kValueOffset));
3449 __ mov(v0, heapnumber); 3449 __ mov(v0, heapnumber);
3450 __ DropAndRet(2 * kPointerSize); 3450 __ DropAndRet(2 * kPointerSize);
3451 3451
3452 __ bind(&exponent_not_smi); 3452 __ bind(&exponent_not_smi);
3453 __ lw(scratch, FieldMemOperand(exponent, JSObject::kMapOffset)); 3453 __ lw(scratch, FieldMemOperand(exponent, JSObject::kMapOffset));
3454 __ Branch(&call_runtime, ne, scratch, Operand(heapnumbermap)); 3454 __ Branch(&call_runtime, ne, scratch, Operand(heapnumbermap));
(...skipping 3192 matching lines...) Expand 10 before | Expand all | Expand 10 after
6647 __ mov(result, zero_reg); 6647 __ mov(result, zero_reg);
6648 __ Ret(); 6648 __ Ret();
6649 } 6649 }
6650 6650
6651 6651
6652 #undef __ 6652 #undef __
6653 6653
6654 } } // namespace v8::internal 6654 } } // namespace v8::internal
6655 6655
6656 #endif // V8_TARGET_ARCH_MIPS 6656 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « no previous file | src/mips/macro-assembler-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698