| 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 3710 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3721 | 3721 |
| 3722 VisitForStackValue(args->at(0)); | 3722 VisitForStackValue(args->at(0)); |
| 3723 VisitForStackValue(args->at(1)); | 3723 VisitForStackValue(args->at(1)); |
| 3724 | 3724 |
| 3725 StringCompareStub stub; | 3725 StringCompareStub stub; |
| 3726 __ CallStub(&stub); | 3726 __ CallStub(&stub); |
| 3727 context()->Plug(eax); | 3727 context()->Plug(eax); |
| 3728 } | 3728 } |
| 3729 | 3729 |
| 3730 | 3730 |
| 3731 void FullCodeGenerator::EmitMathSin(CallRuntime* expr) { | |
| 3732 // Load the argument on the stack and call the stub. | |
| 3733 TranscendentalCacheStub stub(TranscendentalCache::SIN, | |
| 3734 TranscendentalCacheStub::TAGGED); | |
| 3735 ZoneList<Expression*>* args = expr->arguments(); | |
| 3736 ASSERT(args->length() == 1); | |
| 3737 VisitForStackValue(args->at(0)); | |
| 3738 __ CallStub(&stub); | |
| 3739 context()->Plug(eax); | |
| 3740 } | |
| 3741 | |
| 3742 | |
| 3743 void FullCodeGenerator::EmitMathCos(CallRuntime* expr) { | |
| 3744 // Load the argument on the stack and call the stub. | |
| 3745 TranscendentalCacheStub stub(TranscendentalCache::COS, | |
| 3746 TranscendentalCacheStub::TAGGED); | |
| 3747 ZoneList<Expression*>* args = expr->arguments(); | |
| 3748 ASSERT(args->length() == 1); | |
| 3749 VisitForStackValue(args->at(0)); | |
| 3750 __ CallStub(&stub); | |
| 3751 context()->Plug(eax); | |
| 3752 } | |
| 3753 | |
| 3754 | |
| 3755 void FullCodeGenerator::EmitMathTan(CallRuntime* expr) { | |
| 3756 // Load the argument on the stack and call the stub. | |
| 3757 TranscendentalCacheStub stub(TranscendentalCache::TAN, | |
| 3758 TranscendentalCacheStub::TAGGED); | |
| 3759 ZoneList<Expression*>* args = expr->arguments(); | |
| 3760 ASSERT(args->length() == 1); | |
| 3761 VisitForStackValue(args->at(0)); | |
| 3762 __ CallStub(&stub); | |
| 3763 context()->Plug(eax); | |
| 3764 } | |
| 3765 | |
| 3766 | |
| 3767 void FullCodeGenerator::EmitMathLog(CallRuntime* expr) { | 3731 void FullCodeGenerator::EmitMathLog(CallRuntime* expr) { |
| 3768 // Load the argument on the stack and call the stub. | 3732 // Load the argument on the stack and call the stub. |
| 3769 TranscendentalCacheStub stub(TranscendentalCache::LOG, | 3733 TranscendentalCacheStub stub(TranscendentalCache::LOG, |
| 3770 TranscendentalCacheStub::TAGGED); | 3734 TranscendentalCacheStub::TAGGED); |
| 3771 ZoneList<Expression*>* args = expr->arguments(); | 3735 ZoneList<Expression*>* args = expr->arguments(); |
| 3772 ASSERT(args->length() == 1); | 3736 ASSERT(args->length() == 1); |
| 3773 VisitForStackValue(args->at(0)); | 3737 VisitForStackValue(args->at(0)); |
| 3774 __ CallStub(&stub); | 3738 __ CallStub(&stub); |
| 3775 context()->Plug(eax); | 3739 context()->Plug(eax); |
| 3776 } | 3740 } |
| (...skipping 1227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5004 | 4968 |
| 5005 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), | 4969 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), |
| 5006 Assembler::target_address_at(call_target_address)); | 4970 Assembler::target_address_at(call_target_address)); |
| 5007 return OSR_AFTER_STACK_CHECK; | 4971 return OSR_AFTER_STACK_CHECK; |
| 5008 } | 4972 } |
| 5009 | 4973 |
| 5010 | 4974 |
| 5011 } } // namespace v8::internal | 4975 } } // namespace v8::internal |
| 5012 | 4976 |
| 5013 #endif // V8_TARGET_ARCH_IA32 | 4977 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |