OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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_X64_MACRO_ASSEMBLER_X64_H_ | 5 #ifndef V8_X64_MACRO_ASSEMBLER_X64_H_ |
6 #define V8_X64_MACRO_ASSEMBLER_X64_H_ | 6 #define V8_X64_MACRO_ASSEMBLER_X64_H_ |
7 | 7 |
8 #include "src/assembler.h" | 8 #include "src/assembler.h" |
9 #include "src/bailout-reason.h" | 9 #include "src/bailout-reason.h" |
10 #include "src/base/flags.h" | 10 #include "src/base/flags.h" |
(...skipping 909 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
920 // This method must not be used with heap object references. The stored | 920 // This method must not be used with heap object references. The stored |
921 // address is not GC safe. Use the handle version instead. | 921 // address is not GC safe. Use the handle version instead. |
922 DCHECK(rmode > RelocInfo::LAST_GCED_ENUM); | 922 DCHECK(rmode > RelocInfo::LAST_GCED_ENUM); |
923 movp(dst, ptr, rmode); | 923 movp(dst, ptr, rmode); |
924 } | 924 } |
925 | 925 |
926 void Move(Register dst, Handle<Object> value, RelocInfo::Mode rmode) { | 926 void Move(Register dst, Handle<Object> value, RelocInfo::Mode rmode) { |
927 AllowDeferredHandleDereference using_raw_address; | 927 AllowDeferredHandleDereference using_raw_address; |
928 DCHECK(!RelocInfo::IsNone(rmode)); | 928 DCHECK(!RelocInfo::IsNone(rmode)); |
929 DCHECK(value->IsHeapObject()); | 929 DCHECK(value->IsHeapObject()); |
| 930 DCHECK(!isolate()->heap()->InNewSpace(*value)); |
930 movp(dst, reinterpret_cast<void*>(value.location()), rmode); | 931 movp(dst, reinterpret_cast<void*>(value.location()), rmode); |
931 } | 932 } |
932 | 933 |
933 void Move(XMMRegister dst, uint32_t src); | 934 void Move(XMMRegister dst, uint32_t src); |
934 void Move(XMMRegister dst, uint64_t src); | 935 void Move(XMMRegister dst, uint64_t src); |
935 void Move(XMMRegister dst, float src) { Move(dst, bit_cast<uint32_t>(src)); } | 936 void Move(XMMRegister dst, float src) { Move(dst, bit_cast<uint32_t>(src)); } |
936 void Move(XMMRegister dst, double src) { Move(dst, bit_cast<uint64_t>(src)); } | 937 void Move(XMMRegister dst, double src) { Move(dst, bit_cast<uint64_t>(src)); } |
937 | 938 |
938 #define AVX_OP2_WITH_TYPE(macro_name, name, src_type) \ | 939 #define AVX_OP2_WITH_TYPE(macro_name, name, src_type) \ |
939 void macro_name(XMMRegister dst, src_type src) { \ | 940 void macro_name(XMMRegister dst, src_type src) { \ |
(...skipping 833 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1773 } \ | 1774 } \ |
1774 masm-> | 1775 masm-> |
1775 #else | 1776 #else |
1776 #define ACCESS_MASM(masm) masm-> | 1777 #define ACCESS_MASM(masm) masm-> |
1777 #endif | 1778 #endif |
1778 | 1779 |
1779 } // namespace internal | 1780 } // namespace internal |
1780 } // namespace v8 | 1781 } // namespace v8 |
1781 | 1782 |
1782 #endif // V8_X64_MACRO_ASSEMBLER_X64_H_ | 1783 #endif // V8_X64_MACRO_ASSEMBLER_X64_H_ |
OLD | NEW |