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

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

Issue 113343003: Remove the last remnants of the TranscendentalCache. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased Created 7 years 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/mips/full-codegen-mips.cc ('k') | src/mips/lithium-mips.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 1027 matching lines...) Expand 10 before | Expand all | Expand 10 after
1038 case CodeStub::SubString: { 1038 case CodeStub::SubString: {
1039 SubStringStub stub; 1039 SubStringStub stub;
1040 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr); 1040 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr);
1041 break; 1041 break;
1042 } 1042 }
1043 case CodeStub::StringCompare: { 1043 case CodeStub::StringCompare: {
1044 StringCompareStub stub; 1044 StringCompareStub stub;
1045 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr); 1045 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr);
1046 break; 1046 break;
1047 } 1047 }
1048 case CodeStub::TranscendentalCache: {
1049 __ lw(a0, MemOperand(sp, 0));
1050 TranscendentalCacheStub stub(instr->transcendental_type(),
1051 TranscendentalCacheStub::TAGGED);
1052 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr);
1053 break;
1054 }
1055 default: 1048 default:
1056 UNREACHABLE(); 1049 UNREACHABLE();
1057 } 1050 }
1058 } 1051 }
1059 1052
1060 1053
1061 void LCodeGen::DoUnknownOSRValue(LUnknownOSRValue* instr) { 1054 void LCodeGen::DoUnknownOSRValue(LUnknownOSRValue* instr) {
1062 GenerateOsrPrologue(); 1055 GenerateOsrPrologue();
1063 } 1056 }
1064 1057
(...skipping 873 matching lines...) Expand 10 before | Expand all | Expand 10 after
1938 __ div_d(result, left, right); 1931 __ div_d(result, left, right);
1939 break; 1932 break;
1940 case Token::MOD: { 1933 case Token::MOD: {
1941 // Save a0-a3 on the stack. 1934 // Save a0-a3 on the stack.
1942 RegList saved_regs = a0.bit() | a1.bit() | a2.bit() | a3.bit(); 1935 RegList saved_regs = a0.bit() | a1.bit() | a2.bit() | a3.bit();
1943 __ MultiPush(saved_regs); 1936 __ MultiPush(saved_regs);
1944 1937
1945 __ PrepareCallCFunction(0, 2, scratch0()); 1938 __ PrepareCallCFunction(0, 2, scratch0());
1946 __ SetCallCDoubleArguments(left, right); 1939 __ SetCallCDoubleArguments(left, right);
1947 __ CallCFunction( 1940 __ CallCFunction(
1948 ExternalReference::double_fp_operation(Token::MOD, isolate()), 1941 ExternalReference::mod_two_doubles_operation(isolate()),
1949 0, 2); 1942 0, 2);
1950 // Move the result in the double result register. 1943 // Move the result in the double result register.
1951 __ GetCFunctionDoubleResult(result); 1944 __ GetCFunctionDoubleResult(result);
1952 1945
1953 // Restore saved register. 1946 // Restore saved register.
1954 __ MultiPop(saved_regs); 1947 __ MultiPop(saved_regs);
1955 break; 1948 break;
1956 } 1949 }
1957 default: 1950 default:
1958 UNREACHABLE(); 1951 UNREACHABLE();
(...skipping 1898 matching lines...) Expand 10 before | Expand all | Expand 10 after
3857 Register temp1 = ToRegister(instr->temp1()); 3850 Register temp1 = ToRegister(instr->temp1());
3858 Register temp2 = ToRegister(instr->temp2()); 3851 Register temp2 = ToRegister(instr->temp2());
3859 3852
3860 MathExpGenerator::EmitMathExp( 3853 MathExpGenerator::EmitMathExp(
3861 masm(), input, result, double_scratch1, double_scratch2, 3854 masm(), input, result, double_scratch1, double_scratch2,
3862 temp1, temp2, scratch0()); 3855 temp1, temp2, scratch0());
3863 } 3856 }
3864 3857
3865 3858
3866 void LCodeGen::DoMathLog(LMathLog* instr) { 3859 void LCodeGen::DoMathLog(LMathLog* instr) {
3867 ASSERT(ToDoubleRegister(instr->result()).is(f4)); 3860 __ PrepareCallCFunction(0, 1, scratch0());
3868 // Set the context register to a GC-safe fake value. Clobbering it is 3861 __ SetCallCDoubleArguments(ToDoubleRegister(instr->value()));
3869 // OK because this instruction is marked as a call. 3862 __ CallCFunction(ExternalReference::math_log_double_function(isolate()),
3870 __ mov(cp, zero_reg); 3863 0, 1);
3871 TranscendentalCacheStub stub(TranscendentalCache::LOG, 3864 __ GetCFunctionDoubleResult(ToDoubleRegister(instr->result()));
3872 TranscendentalCacheStub::UNTAGGED);
3873 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr);
3874 } 3865 }
3875 3866
3876 3867
3877 void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) { 3868 void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) {
3878 ASSERT(ToRegister(instr->context()).is(cp)); 3869 ASSERT(ToRegister(instr->context()).is(cp));
3879 ASSERT(ToRegister(instr->function()).is(a1)); 3870 ASSERT(ToRegister(instr->function()).is(a1));
3880 ASSERT(instr->HasPointerMap()); 3871 ASSERT(instr->HasPointerMap());
3881 3872
3882 Handle<JSFunction> known_function = instr->hydrogen()->known_function(); 3873 Handle<JSFunction> known_function = instr->hydrogen()->known_function();
3883 if (known_function.is_null()) { 3874 if (known_function.is_null()) {
(...skipping 1934 matching lines...) Expand 10 before | Expand all | Expand 10 after
5818 __ Subu(scratch, result, scratch); 5809 __ Subu(scratch, result, scratch);
5819 __ lw(result, FieldMemOperand(scratch, 5810 __ lw(result, FieldMemOperand(scratch,
5820 FixedArray::kHeaderSize - kPointerSize)); 5811 FixedArray::kHeaderSize - kPointerSize));
5821 __ bind(&done); 5812 __ bind(&done);
5822 } 5813 }
5823 5814
5824 5815
5825 #undef __ 5816 #undef __
5826 5817
5827 } } // namespace v8::internal 5818 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/mips/full-codegen-mips.cc ('k') | src/mips/lithium-mips.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698