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

Side by Side Diff: src/arm/lithium-codegen-arm.cc

Issue 136613003: Demystified floating point ABI function names. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm/codegen-arm.cc ('k') | src/arm/macro-assembler-arm.h » ('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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 2110 matching lines...) Expand 10 before | Expand all | Expand 10 after
2121 __ vsub(result, left, right); 2121 __ vsub(result, left, right);
2122 break; 2122 break;
2123 case Token::MUL: 2123 case Token::MUL:
2124 __ vmul(result, left, right); 2124 __ vmul(result, left, right);
2125 break; 2125 break;
2126 case Token::DIV: 2126 case Token::DIV:
2127 __ vdiv(result, left, right); 2127 __ vdiv(result, left, right);
2128 break; 2128 break;
2129 case Token::MOD: { 2129 case Token::MOD: {
2130 __ PrepareCallCFunction(0, 2, scratch0()); 2130 __ PrepareCallCFunction(0, 2, scratch0());
2131 __ SetCallCDoubleArguments(left, right); 2131 __ MovToFloatParameters(left, right);
2132 __ CallCFunction( 2132 __ CallCFunction(
2133 ExternalReference::mod_two_doubles_operation(isolate()), 2133 ExternalReference::mod_two_doubles_operation(isolate()),
2134 0, 2); 2134 0, 2);
2135 // Move the result in the double result register. 2135 // Move the result in the double result register.
2136 __ GetCFunctionDoubleResult(result); 2136 __ MovFromFloatResult(result);
2137 break; 2137 break;
2138 } 2138 }
2139 default: 2139 default:
2140 UNREACHABLE(); 2140 UNREACHABLE();
2141 break; 2141 break;
2142 } 2142 }
2143 } 2143 }
2144 2144
2145 2145
2146 void LCodeGen::DoArithmeticT(LArithmeticT* instr) { 2146 void LCodeGen::DoArithmeticT(LArithmeticT* instr) {
(...skipping 1780 matching lines...) Expand 10 before | Expand all | Expand 10 after
3927 Register temp2 = ToRegister(instr->temp2()); 3927 Register temp2 = ToRegister(instr->temp2());
3928 3928
3929 MathExpGenerator::EmitMathExp( 3929 MathExpGenerator::EmitMathExp(
3930 masm(), input, result, double_scratch1, double_scratch2, 3930 masm(), input, result, double_scratch1, double_scratch2,
3931 temp1, temp2, scratch0()); 3931 temp1, temp2, scratch0());
3932 } 3932 }
3933 3933
3934 3934
3935 void LCodeGen::DoMathLog(LMathLog* instr) { 3935 void LCodeGen::DoMathLog(LMathLog* instr) {
3936 __ PrepareCallCFunction(0, 1, scratch0()); 3936 __ PrepareCallCFunction(0, 1, scratch0());
3937 __ SetCallCDoubleArguments(ToDoubleRegister(instr->value())); 3937 __ MovToFloatParameter(ToDoubleRegister(instr->value()));
3938 __ CallCFunction(ExternalReference::math_log_double_function(isolate()), 3938 __ CallCFunction(ExternalReference::math_log_double_function(isolate()),
3939 0, 1); 3939 0, 1);
3940 __ GetCFunctionDoubleResult(ToDoubleRegister(instr->result())); 3940 __ MovFromFloatResult(ToDoubleRegister(instr->result()));
3941 } 3941 }
3942 3942
3943 3943
3944 void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) { 3944 void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) {
3945 ASSERT(ToRegister(instr->context()).is(cp)); 3945 ASSERT(ToRegister(instr->context()).is(cp));
3946 ASSERT(ToRegister(instr->function()).is(r1)); 3946 ASSERT(ToRegister(instr->function()).is(r1));
3947 ASSERT(instr->HasPointerMap()); 3947 ASSERT(instr->HasPointerMap());
3948 3948
3949 Handle<JSFunction> known_function = instr->hydrogen()->known_function(); 3949 Handle<JSFunction> known_function = instr->hydrogen()->known_function();
3950 if (known_function.is_null()) { 3950 if (known_function.is_null()) {
(...skipping 1859 matching lines...) Expand 10 before | Expand all | Expand 10 after
5810 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index)); 5810 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index));
5811 __ ldr(result, FieldMemOperand(scratch, 5811 __ ldr(result, FieldMemOperand(scratch,
5812 FixedArray::kHeaderSize - kPointerSize)); 5812 FixedArray::kHeaderSize - kPointerSize));
5813 __ bind(&done); 5813 __ bind(&done);
5814 } 5814 }
5815 5815
5816 5816
5817 #undef __ 5817 #undef __
5818 5818
5819 } } // namespace v8::internal 5819 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/codegen-arm.cc ('k') | src/arm/macro-assembler-arm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698