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

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

Issue 214593005: Revert "Clean up runtime functions for Maths." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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 | « src/runtime.cc ('k') | src/x64/full-codegen-x64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 857 matching lines...) Expand 10 before | Expand all | Expand 10 after
868 // and may not have contained the exponent value in the first place when the 868 // and may not have contained the exponent value in the first place when the
869 // input was a smi. We reset it with exponent value before bailing out. 869 // input was a smi. We reset it with exponent value before bailing out.
870 __ j(not_equal, &done); 870 __ j(not_equal, &done);
871 __ Cvtlsi2sd(double_exponent, exponent); 871 __ Cvtlsi2sd(double_exponent, exponent);
872 872
873 // Returning or bailing out. 873 // Returning or bailing out.
874 Counters* counters = masm->isolate()->counters(); 874 Counters* counters = masm->isolate()->counters();
875 if (exponent_type_ == ON_STACK) { 875 if (exponent_type_ == ON_STACK) {
876 // The arguments are still on the stack. 876 // The arguments are still on the stack.
877 __ bind(&call_runtime); 877 __ bind(&call_runtime);
878 __ TailCallRuntime(Runtime::kHiddenMathPow, 2, 1); 878 __ TailCallRuntime(Runtime::kMath_pow_cfunction, 2, 1);
879 879
880 // The stub is called from non-optimized code, which expects the result 880 // The stub is called from non-optimized code, which expects the result
881 // as heap number in rax. 881 // as heap number in rax.
882 __ bind(&done); 882 __ bind(&done);
883 __ AllocateHeapNumber(rax, rcx, &call_runtime); 883 __ AllocateHeapNumber(rax, rcx, &call_runtime);
884 __ movsd(FieldOperand(rax, HeapNumber::kValueOffset), double_result); 884 __ movsd(FieldOperand(rax, HeapNumber::kValueOffset), double_result);
885 __ IncrementCounter(counters->math_pow(), 1); 885 __ IncrementCounter(counters->math_pow(), 1);
886 __ ret(2 * kPointerSize); 886 __ ret(2 * kPointerSize);
887 } else { 887 } else {
888 __ bind(&call_runtime); 888 __ bind(&call_runtime);
(...skipping 4332 matching lines...) Expand 10 before | Expand all | Expand 10 after
5221 return_value_operand, 5221 return_value_operand,
5222 NULL); 5222 NULL);
5223 } 5223 }
5224 5224
5225 5225
5226 #undef __ 5226 #undef __
5227 5227
5228 } } // namespace v8::internal 5228 } } // namespace v8::internal
5229 5229
5230 #endif // V8_TARGET_ARCH_X64 5230 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/runtime.cc ('k') | src/x64/full-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698