Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(330)

Side by Side Diff: src/arm64/macro-assembler-arm64.h

Issue 271623002: Revert "Arm64: Ensure that csp is always aligned to 16 byte values even if jssp is not." and "Arm64… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/arm64/cpu-arm64.cc ('k') | src/arm64/macro-assembler-arm64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "v8globals.h" 10 #include "v8globals.h"
(...skipping 760 matching lines...) Expand 10 before | Expand all | Expand 10 after
771 Bic(csp, StackPointer(), sp_alignment - 1); 771 Bic(csp, StackPointer(), sp_alignment - 1);
772 SetStackPointer(csp); 772 SetStackPointer(csp);
773 } 773 }
774 774
775 // Push the system stack pointer (csp) down to allow the same to be done to 775 // Push the system stack pointer (csp) down to allow the same to be done to
776 // the current stack pointer (according to StackPointer()). This must be 776 // the current stack pointer (according to StackPointer()). This must be
777 // called _before_ accessing the memory. 777 // called _before_ accessing the memory.
778 // 778 //
779 // This is necessary when pushing or otherwise adding things to the stack, to 779 // This is necessary when pushing or otherwise adding things to the stack, to
780 // satisfy the AAPCS64 constraint that the memory below the system stack 780 // satisfy the AAPCS64 constraint that the memory below the system stack
781 // pointer is not accessed. The amount pushed will be increased as necessary 781 // pointer is not accessed.
782 // to ensure csp remains aligned to 16 bytes.
783 // 782 //
784 // This method asserts that StackPointer() is not csp, since the call does 783 // This method asserts that StackPointer() is not csp, since the call does
785 // not make sense in that context. 784 // not make sense in that context.
786 inline void BumpSystemStackPointer(const Operand& space); 785 inline void BumpSystemStackPointer(const Operand& space);
787 786
788 // Re-synchronizes the system stack pointer (csp) with the current stack
789 // pointer (according to StackPointer()). This function will ensure the
790 // new value of the system stack pointer is remains aligned to 16 bytes, and
791 // is lower than or equal to the value of the current stack pointer.
792 //
793 // This method asserts that StackPointer() is not csp, since the call does
794 // not make sense in that context.
795 inline void SyncSystemStackPointer();
796
797 // Helpers ------------------------------------------------------------------ 787 // Helpers ------------------------------------------------------------------
798 // Root register. 788 // Root register.
799 inline void InitializeRootRegister(); 789 inline void InitializeRootRegister();
800 790
801 void AssertFPCRState(Register fpcr = NoReg); 791 void AssertFPCRState(Register fpcr = NoReg);
802 void ConfigureFPCR(); 792 void ConfigureFPCR();
803 void CanonicalizeNaN(const FPRegister& dst, const FPRegister& src); 793 void CanonicalizeNaN(const FPRegister& dst, const FPRegister& src);
804 void CanonicalizeNaN(const FPRegister& reg) { 794 void CanonicalizeNaN(const FPRegister& reg) {
805 CanonicalizeNaN(reg, reg); 795 CanonicalizeNaN(reg, reg);
806 } 796 }
(...skipping 1216 matching lines...) Expand 10 before | Expand all | Expand 10 after
2023 // block of registers. 2013 // block of registers.
2024 // 2014 //
2025 // Note that size is per register, and is specified in bytes. 2015 // Note that size is per register, and is specified in bytes.
2026 void PushHelper(int count, int size, 2016 void PushHelper(int count, int size,
2027 const CPURegister& src0, const CPURegister& src1, 2017 const CPURegister& src0, const CPURegister& src1,
2028 const CPURegister& src2, const CPURegister& src3); 2018 const CPURegister& src2, const CPURegister& src3);
2029 void PopHelper(int count, int size, 2019 void PopHelper(int count, int size,
2030 const CPURegister& dst0, const CPURegister& dst1, 2020 const CPURegister& dst0, const CPURegister& dst1,
2031 const CPURegister& dst2, const CPURegister& dst3); 2021 const CPURegister& dst2, const CPURegister& dst3);
2032 2022
2033 // Perform necessary maintenance operations before a push or after a pop. 2023 // Perform necessary maintenance operations before a push or pop.
2034 // 2024 //
2035 // Note that size is specified in bytes. 2025 // Note that size is specified in bytes.
2036 void PushPreamble(Operand total_size); 2026 void PrepareForPush(Operand total_size);
2037 void PopPostamble(Operand total_size); 2027 void PrepareForPop(Operand total_size);
2038 2028
2039 void PushPreamble(int count, int size) { PushPreamble(count * size); } 2029 void PrepareForPush(int count, int size) { PrepareForPush(count * size); }
2040 void PopPostamble(int count, int size) { PopPostamble(count * size); } 2030 void PrepareForPop(int count, int size) { PrepareForPop(count * size); }
2041 2031
2042 // Call Printf. On a native build, a simple call will be generated, but if the 2032 // Call Printf. On a native build, a simple call will be generated, but if the
2043 // simulator is being used then a suitable pseudo-instruction is used. The 2033 // simulator is being used then a suitable pseudo-instruction is used. The
2044 // arguments and stack (csp) must be prepared by the caller as for a normal 2034 // arguments and stack (csp) must be prepared by the caller as for a normal
2045 // AAPCS64 call to 'printf'. 2035 // AAPCS64 call to 'printf'.
2046 // 2036 //
2047 // The 'type' argument specifies the type of the optional arguments. 2037 // The 'type' argument specifies the type of the optional arguments.
2048 void CallPrintf(CPURegister::RegisterType type = CPURegister::kNoRegister); 2038 void CallPrintf(CPURegister::RegisterType type = CPURegister::kNoRegister);
2049 2039
2050 // Helper for throwing exceptions. Compute a handler address and jump to 2040 // Helper for throwing exceptions. Compute a handler address and jump to
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
2294 #error "Unsupported option" 2284 #error "Unsupported option"
2295 #define CODE_COVERAGE_STRINGIFY(x) #x 2285 #define CODE_COVERAGE_STRINGIFY(x) #x
2296 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) 2286 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x)
2297 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) 2287 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__)
2298 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> 2288 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm->
2299 #else 2289 #else
2300 #define ACCESS_MASM(masm) masm-> 2290 #define ACCESS_MASM(masm) masm->
2301 #endif 2291 #endif
2302 2292
2303 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ 2293 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_
OLDNEW
« no previous file with comments | « src/arm64/cpu-arm64.cc ('k') | src/arm64/macro-assembler-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698