OLD | NEW |
1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ | 5 #ifndef V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ |
6 #define V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ | 6 #define V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "src/arm64/assembler-arm64.h" | 10 #include "src/arm64/assembler-arm64.h" |
(...skipping 941 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
952 // Abort execution if argument is a smi, enabled via --debug-code. | 952 // Abort execution if argument is a smi, enabled via --debug-code. |
953 void AssertNotSmi(Register object, BailoutReason reason = kOperandIsASmi); | 953 void AssertNotSmi(Register object, BailoutReason reason = kOperandIsASmi); |
954 void AssertSmi(Register object, BailoutReason reason = kOperandIsNotASmi); | 954 void AssertSmi(Register object, BailoutReason reason = kOperandIsNotASmi); |
955 | 955 |
956 inline void ObjectTag(Register tagged_obj, Register obj); | 956 inline void ObjectTag(Register tagged_obj, Register obj); |
957 inline void ObjectUntag(Register untagged_obj, Register obj); | 957 inline void ObjectUntag(Register untagged_obj, Register obj); |
958 | 958 |
959 // Abort execution if argument is not a name, enabled via --debug-code. | 959 // Abort execution if argument is not a name, enabled via --debug-code. |
960 void AssertName(Register object); | 960 void AssertName(Register object); |
961 | 961 |
| 962 // Abort execution if argument is not a JSFunction, enabled via --debug-code. |
| 963 void AssertFunction(Register object); |
| 964 |
962 // Abort execution if argument is not undefined or an AllocationSite, enabled | 965 // Abort execution if argument is not undefined or an AllocationSite, enabled |
963 // via --debug-code. | 966 // via --debug-code. |
964 void AssertUndefinedOrAllocationSite(Register object, Register scratch); | 967 void AssertUndefinedOrAllocationSite(Register object, Register scratch); |
965 | 968 |
966 // Abort execution if argument is not a string, enabled via --debug-code. | 969 // Abort execution if argument is not a string, enabled via --debug-code. |
967 void AssertString(Register object); | 970 void AssertString(Register object); |
968 | 971 |
969 void JumpIfHeapNumber(Register object, Label* on_heap_number, | 972 void JumpIfHeapNumber(Register object, Label* on_heap_number, |
970 SmiCheckType smi_check_type = DONT_DO_SMI_CHECK); | 973 SmiCheckType smi_check_type = DONT_DO_SMI_CHECK); |
971 void JumpIfNotHeapNumber(Register object, Label* on_not_heap_number, | 974 void JumpIfNotHeapNumber(Register object, Label* on_not_heap_number, |
(...skipping 711 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1683 // * The exit frame is dropped. | 1686 // * The exit frame is dropped. |
1684 // * The stack pointer is reset to jssp. | 1687 // * The stack pointer is reset to jssp. |
1685 // | 1688 // |
1686 // The stack pointer must be csp on entry. | 1689 // The stack pointer must be csp on entry. |
1687 void LeaveExitFrame(bool save_doubles, | 1690 void LeaveExitFrame(bool save_doubles, |
1688 const Register& scratch, | 1691 const Register& scratch, |
1689 bool restore_context); | 1692 bool restore_context); |
1690 | 1693 |
1691 void LoadContext(Register dst, int context_chain_length); | 1694 void LoadContext(Register dst, int context_chain_length); |
1692 | 1695 |
| 1696 // Load the global proxy from the current context. |
| 1697 void LoadGlobalProxy(Register dst); |
| 1698 |
1693 // Emit code for a truncating division by a constant. The dividend register is | 1699 // Emit code for a truncating division by a constant. The dividend register is |
1694 // unchanged. Dividend and result must be different. | 1700 // unchanged. Dividend and result must be different. |
1695 void TruncatingDiv(Register result, Register dividend, int32_t divisor); | 1701 void TruncatingDiv(Register result, Register dividend, int32_t divisor); |
1696 | 1702 |
1697 // --------------------------------------------------------------------------- | 1703 // --------------------------------------------------------------------------- |
1698 // StatsCounter support | 1704 // StatsCounter support |
1699 | 1705 |
1700 void SetCounter(StatsCounter* counter, int value, Register scratch1, | 1706 void SetCounter(StatsCounter* counter, int value, Register scratch1, |
1701 Register scratch2); | 1707 Register scratch2); |
1702 void IncrementCounter(StatsCounter* counter, int value, Register scratch1, | 1708 void IncrementCounter(StatsCounter* counter, int value, Register scratch1, |
(...skipping 584 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2287 #error "Unsupported option" | 2293 #error "Unsupported option" |
2288 #define CODE_COVERAGE_STRINGIFY(x) #x | 2294 #define CODE_COVERAGE_STRINGIFY(x) #x |
2289 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) | 2295 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) |
2290 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) | 2296 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) |
2291 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> | 2297 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> |
2292 #else | 2298 #else |
2293 #define ACCESS_MASM(masm) masm-> | 2299 #define ACCESS_MASM(masm) masm-> |
2294 #endif | 2300 #endif |
2295 | 2301 |
2296 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ | 2302 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ |
OLD | NEW |