OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 6631 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6642 CHECK_ALIVE(VisitArgumentList(call->arguments())); | 6642 CHECK_ALIVE(VisitArgumentList(call->arguments())); |
6643 HValue* context = environment()->LookupContext(); | 6643 HValue* context = environment()->LookupContext(); |
6644 HCallStub* result = | 6644 HCallStub* result = |
6645 new(zone()) HCallStub(context, CodeStub::TranscendentalCache, 1); | 6645 new(zone()) HCallStub(context, CodeStub::TranscendentalCache, 1); |
6646 result->set_transcendental_type(TranscendentalCache::COS); | 6646 result->set_transcendental_type(TranscendentalCache::COS); |
6647 Drop(1); | 6647 Drop(1); |
6648 return ast_context()->ReturnInstruction(result, call->id()); | 6648 return ast_context()->ReturnInstruction(result, call->id()); |
6649 } | 6649 } |
6650 | 6650 |
6651 | 6651 |
| 6652 void HGraphBuilder::GenerateMathTan(CallRuntime* call) { |
| 6653 ASSERT_EQ(1, call->arguments()->length()); |
| 6654 CHECK_ALIVE(VisitArgumentList(call->arguments())); |
| 6655 HValue* context = environment()->LookupContext(); |
| 6656 HCallStub* result = |
| 6657 new(zone()) HCallStub(context, CodeStub::TranscendentalCache, 1); |
| 6658 result->set_transcendental_type(TranscendentalCache::TAN); |
| 6659 Drop(1); |
| 6660 return ast_context()->ReturnInstruction(result, call->id()); |
| 6661 } |
| 6662 |
| 6663 |
6652 void HGraphBuilder::GenerateMathLog(CallRuntime* call) { | 6664 void HGraphBuilder::GenerateMathLog(CallRuntime* call) { |
6653 ASSERT_EQ(1, call->arguments()->length()); | 6665 ASSERT_EQ(1, call->arguments()->length()); |
6654 CHECK_ALIVE(VisitArgumentList(call->arguments())); | 6666 CHECK_ALIVE(VisitArgumentList(call->arguments())); |
6655 HValue* context = environment()->LookupContext(); | 6667 HValue* context = environment()->LookupContext(); |
6656 HCallStub* result = | 6668 HCallStub* result = |
6657 new(zone()) HCallStub(context, CodeStub::TranscendentalCache, 1); | 6669 new(zone()) HCallStub(context, CodeStub::TranscendentalCache, 1); |
6658 result->set_transcendental_type(TranscendentalCache::LOG); | 6670 result->set_transcendental_type(TranscendentalCache::LOG); |
6659 Drop(1); | 6671 Drop(1); |
6660 return ast_context()->ReturnInstruction(result, call->id()); | 6672 return ast_context()->ReturnInstruction(result, call->id()); |
6661 } | 6673 } |
(...skipping 550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7212 } | 7224 } |
7213 } | 7225 } |
7214 | 7226 |
7215 #ifdef DEBUG | 7227 #ifdef DEBUG |
7216 if (graph_ != NULL) graph_->Verify(false); // No full verify. | 7228 if (graph_ != NULL) graph_->Verify(false); // No full verify. |
7217 if (allocator_ != NULL) allocator_->Verify(); | 7229 if (allocator_ != NULL) allocator_->Verify(); |
7218 #endif | 7230 #endif |
7219 } | 7231 } |
7220 | 7232 |
7221 } } // namespace v8::internal | 7233 } } // namespace v8::internal |
OLD | NEW |