| OLD | NEW |
| 1 // Copyright 2013 the V8 project authors. All rights reserved. | 1 // Copyright 2013 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 1710 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1721 Register addr, | 1721 Register addr, |
| 1722 Register scratch1, | 1722 Register scratch1, |
| 1723 SaveFPRegsMode save_fp, | 1723 SaveFPRegsMode save_fp, |
| 1724 RememberedSetFinalAction and_then); | 1724 RememberedSetFinalAction and_then); |
| 1725 | 1725 |
| 1726 // Push and pop the registers that can hold pointers, as defined by the | 1726 // Push and pop the registers that can hold pointers, as defined by the |
| 1727 // RegList constant kSafepointSavedRegisters. | 1727 // RegList constant kSafepointSavedRegisters. |
| 1728 void PushSafepointRegisters(); | 1728 void PushSafepointRegisters(); |
| 1729 void PopSafepointRegisters(); | 1729 void PopSafepointRegisters(); |
| 1730 | 1730 |
| 1731 void PushSafepointFPRegisters(); | 1731 void PushSafepointRegistersAndDoubles(); |
| 1732 void PopSafepointFPRegisters(); | 1732 void PopSafepointRegistersAndDoubles(); |
| 1733 | 1733 |
| 1734 // Store value in register src in the safepoint stack slot for register dst. | 1734 // Store value in register src in the safepoint stack slot for register dst. |
| 1735 void StoreToSafepointRegisterSlot(Register src, Register dst) { | 1735 void StoreToSafepointRegisterSlot(Register src, Register dst) { |
| 1736 Poke(src, SafepointRegisterStackIndex(dst.code()) * kPointerSize); | 1736 Poke(src, SafepointRegisterStackIndex(dst.code()) * kPointerSize); |
| 1737 } | 1737 } |
| 1738 | 1738 |
| 1739 // Load the value of the src register from its safepoint stack slot | 1739 // Load the value of the src register from its safepoint stack slot |
| 1740 // into register dst. | 1740 // into register dst. |
| 1741 void LoadFromSafepointRegisterSlot(Register dst, Register src) { | 1741 void LoadFromSafepointRegisterSlot(Register dst, Register src) { |
| 1742 Peek(src, SafepointRegisterStackIndex(dst.code()) * kPointerSize); | 1742 Peek(src, SafepointRegisterStackIndex(dst.code()) * kPointerSize); |
| (...skipping 465 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2208 | 2208 |
| 2209 ~UseScratchRegisterScope(); | 2209 ~UseScratchRegisterScope(); |
| 2210 | 2210 |
| 2211 // Take a register from the appropriate temps list. It will be returned | 2211 // Take a register from the appropriate temps list. It will be returned |
| 2212 // automatically when the scope ends. | 2212 // automatically when the scope ends. |
| 2213 Register AcquireW() { return AcquireNextAvailable(available_).W(); } | 2213 Register AcquireW() { return AcquireNextAvailable(available_).W(); } |
| 2214 Register AcquireX() { return AcquireNextAvailable(available_).X(); } | 2214 Register AcquireX() { return AcquireNextAvailable(available_).X(); } |
| 2215 FPRegister AcquireS() { return AcquireNextAvailable(availablefp_).S(); } | 2215 FPRegister AcquireS() { return AcquireNextAvailable(availablefp_).S(); } |
| 2216 FPRegister AcquireD() { return AcquireNextAvailable(availablefp_).D(); } | 2216 FPRegister AcquireD() { return AcquireNextAvailable(availablefp_).D(); } |
| 2217 | 2217 |
| 2218 Register UnsafeAcquire(const Register& reg) { |
| 2219 return UnsafeAcquire(available_, reg); |
| 2220 } |
| 2221 |
| 2218 Register AcquireSameSizeAs(const Register& reg); | 2222 Register AcquireSameSizeAs(const Register& reg); |
| 2219 FPRegister AcquireSameSizeAs(const FPRegister& reg); | 2223 FPRegister AcquireSameSizeAs(const FPRegister& reg); |
| 2220 | 2224 |
| 2221 private: | 2225 private: |
| 2222 static CPURegister AcquireNextAvailable(CPURegList* available); | 2226 static CPURegister AcquireNextAvailable(CPURegList* available); |
| 2227 static CPURegister UnsafeAcquire(CPURegList* available, |
| 2228 const CPURegister& reg); |
| 2223 | 2229 |
| 2224 // Available scratch registers. | 2230 // Available scratch registers. |
| 2225 CPURegList* available_; // kRegister | 2231 CPURegList* available_; // kRegister |
| 2226 CPURegList* availablefp_; // kFPRegister | 2232 CPURegList* availablefp_; // kFPRegister |
| 2227 | 2233 |
| 2228 // The state of the available lists at the start of this scope. | 2234 // The state of the available lists at the start of this scope. |
| 2229 RegList old_available_; // kRegister | 2235 RegList old_available_; // kRegister |
| 2230 RegList old_availablefp_; // kFPRegister | 2236 RegList old_availablefp_; // kFPRegister |
| 2231 }; | 2237 }; |
| 2232 | 2238 |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2294 #error "Unsupported option" | 2300 #error "Unsupported option" |
| 2295 #define CODE_COVERAGE_STRINGIFY(x) #x | 2301 #define CODE_COVERAGE_STRINGIFY(x) #x |
| 2296 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) | 2302 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) |
| 2297 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) | 2303 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) |
| 2298 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> | 2304 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> |
| 2299 #else | 2305 #else |
| 2300 #define ACCESS_MASM(masm) masm-> | 2306 #define ACCESS_MASM(masm) masm-> |
| 2301 #endif | 2307 #endif |
| 2302 | 2308 |
| 2303 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ | 2309 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ |
| OLD | NEW |