OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 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 569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
580 Register scratch); | 580 Register scratch); |
581 | 581 |
582 // ------------------------------------------------------------------------- | 582 // ------------------------------------------------------------------------- |
583 // JavaScript invokes | 583 // JavaScript invokes |
584 | 584 |
585 // Invoke the JavaScript function code by either calling or jumping. | 585 // Invoke the JavaScript function code by either calling or jumping. |
586 void InvokeCode(Register code, | 586 void InvokeCode(Register code, |
587 const ParameterCount& expected, | 587 const ParameterCount& expected, |
588 const ParameterCount& actual, | 588 const ParameterCount& actual, |
589 InvokeFlag flag, | 589 InvokeFlag flag, |
590 CallWrapper* call_wrapper = NULL); | 590 const CallWrapper& call_wrapper = NullCallWrapper()); |
591 | 591 |
592 void InvokeCode(Handle<Code> code, | 592 void InvokeCode(Handle<Code> code, |
593 const ParameterCount& expected, | 593 const ParameterCount& expected, |
594 const ParameterCount& actual, | 594 const ParameterCount& actual, |
595 RelocInfo::Mode rmode, | 595 RelocInfo::Mode rmode, |
596 InvokeFlag flag); | 596 InvokeFlag flag); |
597 | 597 |
598 // Invoke the JavaScript function in the given register. Changes the | 598 // Invoke the JavaScript function in the given register. Changes the |
599 // current context to the context in the function before invoking. | 599 // current context to the context in the function before invoking. |
600 void InvokeFunction(Register function, | 600 void InvokeFunction(Register function, |
601 const ParameterCount& actual, | 601 const ParameterCount& actual, |
602 InvokeFlag flag, | 602 InvokeFlag flag, |
603 CallWrapper* call_wrapper = NULL); | 603 const CallWrapper& call_wrapper = NullCallWrapper()); |
604 | 604 |
605 void InvokeFunction(JSFunction* function, | 605 void InvokeFunction(JSFunction* function, |
606 const ParameterCount& actual, | 606 const ParameterCount& actual, |
607 InvokeFlag flag); | 607 InvokeFlag flag); |
608 | 608 |
609 | 609 |
610 void IsObjectJSObjectType(Register heap_object, | 610 void IsObjectJSObjectType(Register heap_object, |
611 Register map, | 611 Register map, |
612 Register scratch, | 612 Register scratch, |
613 Label* fail); | 613 Label* fail); |
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
763 void CallCFunction(ExternalReference function, int num_arguments); | 763 void CallCFunction(ExternalReference function, int num_arguments); |
764 void CallCFunction(Register function, Register scratch, int num_arguments); | 764 void CallCFunction(Register function, Register scratch, int num_arguments); |
765 | 765 |
766 // Jump to the builtin routine. | 766 // Jump to the builtin routine. |
767 void JumpToExternalReference(const ExternalReference& builtin); | 767 void JumpToExternalReference(const ExternalReference& builtin); |
768 | 768 |
769 // Invoke specified builtin JavaScript function. Adds an entry to | 769 // Invoke specified builtin JavaScript function. Adds an entry to |
770 // the unresolved list if the name does not resolve. | 770 // the unresolved list if the name does not resolve. |
771 void InvokeBuiltin(Builtins::JavaScript id, | 771 void InvokeBuiltin(Builtins::JavaScript id, |
772 InvokeFlag flag, | 772 InvokeFlag flag, |
773 CallWrapper* call_wrapper = NULL); | 773 const CallWrapper& call_wrapper = NullCallWrapper()); |
774 | 774 |
775 // Store the code object for the given builtin in the target register and | 775 // Store the code object for the given builtin in the target register and |
776 // setup the function in a1. | 776 // setup the function in a1. |
777 void GetBuiltinEntry(Register target, Builtins::JavaScript id); | 777 void GetBuiltinEntry(Register target, Builtins::JavaScript id); |
778 | 778 |
779 // Store the function for the given builtin in the target register. | 779 // Store the function for the given builtin in the target register. |
780 void GetBuiltinFunction(Register target, Builtins::JavaScript id); | 780 void GetBuiltinFunction(Register target, Builtins::JavaScript id); |
781 | 781 |
782 struct Unresolved { | 782 struct Unresolved { |
783 int pc; | 783 int pc; |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
946 Register r1 = zero_reg, const Operand& r2 = Operand(zero_reg), | 946 Register r1 = zero_reg, const Operand& r2 = Operand(zero_reg), |
947 BranchDelaySlot bd = PROTECT); | 947 BranchDelaySlot bd = PROTECT); |
948 | 948 |
949 // Helper functions for generating invokes. | 949 // Helper functions for generating invokes. |
950 void InvokePrologue(const ParameterCount& expected, | 950 void InvokePrologue(const ParameterCount& expected, |
951 const ParameterCount& actual, | 951 const ParameterCount& actual, |
952 Handle<Code> code_constant, | 952 Handle<Code> code_constant, |
953 Register code_reg, | 953 Register code_reg, |
954 Label* done, | 954 Label* done, |
955 InvokeFlag flag, | 955 InvokeFlag flag, |
956 CallWrapper* call_wrapper = NULL); | 956 const CallWrapper& call_wrapper = NullCallWrapper()); |
957 | 957 |
958 // Get the code for the given builtin. Returns if able to resolve | 958 // Get the code for the given builtin. Returns if able to resolve |
959 // the function in the 'resolved' flag. | 959 // the function in the 'resolved' flag. |
960 Handle<Code> ResolveBuiltin(Builtins::JavaScript id, bool* resolved); | 960 Handle<Code> ResolveBuiltin(Builtins::JavaScript id, bool* resolved); |
961 | 961 |
962 // Activation support. | 962 // Activation support. |
963 void EnterFrame(StackFrame::Type type); | 963 void EnterFrame(StackFrame::Type type); |
964 void LeaveFrame(StackFrame::Type type); | 964 void LeaveFrame(StackFrame::Type type); |
965 | 965 |
966 void InitializeNewString(Register string, | 966 void InitializeNewString(Register string, |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1032 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) | 1032 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) |
1033 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> | 1033 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> |
1034 #else | 1034 #else |
1035 #define ACCESS_MASM(masm) masm-> | 1035 #define ACCESS_MASM(masm) masm-> |
1036 #endif | 1036 #endif |
1037 | 1037 |
1038 } } // namespace v8::internal | 1038 } } // namespace v8::internal |
1039 | 1039 |
1040 #endif // V8_MIPS_MACRO_ASSEMBLER_MIPS_H_ | 1040 #endif // V8_MIPS_MACRO_ASSEMBLER_MIPS_H_ |
1041 | 1041 |
OLD | NEW |