| OLD | NEW |
| 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 1067 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1078 case CodeStub::SubString: { | 1078 case CodeStub::SubString: { |
| 1079 SubStringStub stub; | 1079 SubStringStub stub; |
| 1080 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr); | 1080 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr); |
| 1081 break; | 1081 break; |
| 1082 } | 1082 } |
| 1083 case CodeStub::StringCompare: { | 1083 case CodeStub::StringCompare: { |
| 1084 StringCompareStub stub; | 1084 StringCompareStub stub; |
| 1085 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr); | 1085 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr); |
| 1086 break; | 1086 break; |
| 1087 } | 1087 } |
| 1088 case CodeStub::TranscendentalCache: { | |
| 1089 __ ldr(r0, MemOperand(sp, 0)); | |
| 1090 TranscendentalCacheStub stub(instr->transcendental_type(), | |
| 1091 TranscendentalCacheStub::TAGGED); | |
| 1092 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr); | |
| 1093 break; | |
| 1094 } | |
| 1095 default: | 1088 default: |
| 1096 UNREACHABLE(); | 1089 UNREACHABLE(); |
| 1097 } | 1090 } |
| 1098 } | 1091 } |
| 1099 | 1092 |
| 1100 | 1093 |
| 1101 void LCodeGen::DoUnknownOSRValue(LUnknownOSRValue* instr) { | 1094 void LCodeGen::DoUnknownOSRValue(LUnknownOSRValue* instr) { |
| 1102 GenerateOsrPrologue(); | 1095 GenerateOsrPrologue(); |
| 1103 } | 1096 } |
| 1104 | 1097 |
| (...skipping 2829 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3934 Register temp1 = ToRegister(instr->temp1()); | 3927 Register temp1 = ToRegister(instr->temp1()); |
| 3935 Register temp2 = ToRegister(instr->temp2()); | 3928 Register temp2 = ToRegister(instr->temp2()); |
| 3936 | 3929 |
| 3937 MathExpGenerator::EmitMathExp( | 3930 MathExpGenerator::EmitMathExp( |
| 3938 masm(), input, result, double_scratch1, double_scratch2, | 3931 masm(), input, result, double_scratch1, double_scratch2, |
| 3939 temp1, temp2, scratch0()); | 3932 temp1, temp2, scratch0()); |
| 3940 } | 3933 } |
| 3941 | 3934 |
| 3942 | 3935 |
| 3943 void LCodeGen::DoMathLog(LMathLog* instr) { | 3936 void LCodeGen::DoMathLog(LMathLog* instr) { |
| 3944 ASSERT(ToDoubleRegister(instr->result()).is(d2)); | 3937 // TODO(svenpanne) Implement me without the transcendental cache! |
| 3945 // Set the context register to a GC-safe fake value. Clobbering it is | |
| 3946 // OK because this instruction is marked as a call. | |
| 3947 __ mov(cp, Operand::Zero()); | |
| 3948 TranscendentalCacheStub stub(TranscendentalCache::LOG, | |
| 3949 TranscendentalCacheStub::UNTAGGED); | |
| 3950 CallCode(stub.GetCode(isolate()), RelocInfo::CODE_TARGET, instr); | |
| 3951 } | 3938 } |
| 3952 | 3939 |
| 3953 | 3940 |
| 3954 void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) { | 3941 void LCodeGen::DoInvokeFunction(LInvokeFunction* instr) { |
| 3955 ASSERT(ToRegister(instr->context()).is(cp)); | 3942 ASSERT(ToRegister(instr->context()).is(cp)); |
| 3956 ASSERT(ToRegister(instr->function()).is(r1)); | 3943 ASSERT(ToRegister(instr->function()).is(r1)); |
| 3957 ASSERT(instr->HasPointerMap()); | 3944 ASSERT(instr->HasPointerMap()); |
| 3958 | 3945 |
| 3959 Handle<JSFunction> known_function = instr->hydrogen()->known_function(); | 3946 Handle<JSFunction> known_function = instr->hydrogen()->known_function(); |
| 3960 if (known_function.is_null()) { | 3947 if (known_function.is_null()) { |
| (...skipping 1863 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5824 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index)); | 5811 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index)); |
| 5825 __ ldr(result, FieldMemOperand(scratch, | 5812 __ ldr(result, FieldMemOperand(scratch, |
| 5826 FixedArray::kHeaderSize - kPointerSize)); | 5813 FixedArray::kHeaderSize - kPointerSize)); |
| 5827 __ bind(&done); | 5814 __ bind(&done); |
| 5828 } | 5815 } |
| 5829 | 5816 |
| 5830 | 5817 |
| 5831 #undef __ | 5818 #undef __ |
| 5832 | 5819 |
| 5833 } } // namespace v8::internal | 5820 } } // namespace v8::internal |
| OLD | NEW |