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

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

Issue 296113008: Allow HPushArgument to handle more than one argument. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebase, and use int instead of unsigned 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/lithium-codegen-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 596 matching lines...) Expand 10 before | Expand all | Expand 10 after
607 607
608 ~PushPopQueue() { 608 ~PushPopQueue() {
609 ASSERT(queued_.empty()); 609 ASSERT(queued_.empty());
610 } 610 }
611 611
612 void Queue(const CPURegister& rt) { 612 void Queue(const CPURegister& rt) {
613 size_ += rt.SizeInBytes(); 613 size_ += rt.SizeInBytes();
614 queued_.push_back(rt); 614 queued_.push_back(rt);
615 } 615 }
616 616
617 void PushQueued(); 617 enum PreambleDirective {
618 WITH_PREAMBLE,
619 SKIP_PREAMBLE
620 };
621 void PushQueued(PreambleDirective preamble_directive = WITH_PREAMBLE);
618 void PopQueued(); 622 void PopQueued();
619 623
620 private: 624 private:
621 MacroAssembler* masm_; 625 MacroAssembler* masm_;
622 int size_; 626 int size_;
623 std::vector<CPURegister> queued_; 627 std::vector<CPURegister> queued_;
624 }; 628 };
625 629
626 // Poke 'src' onto the stack. The offset is in bytes. 630 // Poke 'src' onto the stack. The offset is in bytes.
627 // 631 //
(...skipping 1377 matching lines...) Expand 10 before | Expand all | Expand 10 after
2005 2009
2006 // Return true if the sequence is a young sequence geneated by 2010 // Return true if the sequence is a young sequence geneated by
2007 // EmitFrameSetupForCodeAgePatching. Otherwise, this method asserts that the 2011 // EmitFrameSetupForCodeAgePatching. Otherwise, this method asserts that the
2008 // sequence is a code age sequence (emitted by EmitCodeAgeSequence). 2012 // sequence is a code age sequence (emitted by EmitCodeAgeSequence).
2009 static bool IsYoungSequence(Isolate* isolate, byte* sequence); 2013 static bool IsYoungSequence(Isolate* isolate, byte* sequence);
2010 2014
2011 // Jumps to found label if a prototype map has dictionary elements. 2015 // Jumps to found label if a prototype map has dictionary elements.
2012 void JumpIfDictionaryInPrototypeChain(Register object, Register scratch0, 2016 void JumpIfDictionaryInPrototypeChain(Register object, Register scratch0,
2013 Register scratch1, Label* found); 2017 Register scratch1, Label* found);
2014 2018
2019 // Perform necessary maintenance operations before a push or after a pop.
2020 //
2021 // Note that size is specified in bytes.
2022 void PushPreamble(Operand total_size);
2023 void PopPostamble(Operand total_size);
2024
2025 void PushPreamble(int count, int size) { PushPreamble(count * size); }
2026 void PopPostamble(int count, int size) { PopPostamble(count * size); }
2027
2015 private: 2028 private:
2016 // Helpers for CopyFields. 2029 // Helpers for CopyFields.
2017 // These each implement CopyFields in a different way. 2030 // These each implement CopyFields in a different way.
2018 void CopyFieldsLoopPairsHelper(Register dst, Register src, unsigned count, 2031 void CopyFieldsLoopPairsHelper(Register dst, Register src, unsigned count,
2019 Register scratch1, Register scratch2, 2032 Register scratch1, Register scratch2,
2020 Register scratch3, Register scratch4, 2033 Register scratch3, Register scratch4,
2021 Register scratch5); 2034 Register scratch5);
2022 void CopyFieldsUnrolledPairsHelper(Register dst, Register src, unsigned count, 2035 void CopyFieldsUnrolledPairsHelper(Register dst, Register src, unsigned count,
2023 Register scratch1, Register scratch2, 2036 Register scratch1, Register scratch2,
2024 Register scratch3, Register scratch4); 2037 Register scratch3, Register scratch4);
2025 void CopyFieldsUnrolledHelper(Register dst, Register src, unsigned count, 2038 void CopyFieldsUnrolledHelper(Register dst, Register src, unsigned count,
2026 Register scratch1, Register scratch2, 2039 Register scratch1, Register scratch2,
2027 Register scratch3); 2040 Register scratch3);
2028 2041
2029 // The actual Push and Pop implementations. These don't generate any code 2042 // The actual Push and Pop implementations. These don't generate any code
2030 // other than that required for the push or pop. This allows 2043 // other than that required for the push or pop. This allows
2031 // (Push|Pop)CPURegList to bundle together run-time assertions for a large 2044 // (Push|Pop)CPURegList to bundle together run-time assertions for a large
2032 // block of registers. 2045 // block of registers.
2033 // 2046 //
2034 // Note that size is per register, and is specified in bytes. 2047 // Note that size is per register, and is specified in bytes.
2035 void PushHelper(int count, int size, 2048 void PushHelper(int count, int size,
2036 const CPURegister& src0, const CPURegister& src1, 2049 const CPURegister& src0, const CPURegister& src1,
2037 const CPURegister& src2, const CPURegister& src3); 2050 const CPURegister& src2, const CPURegister& src3);
2038 void PopHelper(int count, int size, 2051 void PopHelper(int count, int size,
2039 const CPURegister& dst0, const CPURegister& dst1, 2052 const CPURegister& dst0, const CPURegister& dst1,
2040 const CPURegister& dst2, const CPURegister& dst3); 2053 const CPURegister& dst2, const CPURegister& dst3);
2041 2054
2042 // Perform necessary maintenance operations before a push or after a pop.
2043 //
2044 // Note that size is specified in bytes.
2045 void PushPreamble(Operand total_size);
2046 void PopPostamble(Operand total_size);
2047
2048 void PushPreamble(int count, int size) { PushPreamble(count * size); }
2049 void PopPostamble(int count, int size) { PopPostamble(count * size); }
2050
2051 // Call Printf. On a native build, a simple call will be generated, but if the 2055 // Call Printf. On a native build, a simple call will be generated, but if the
2052 // simulator is being used then a suitable pseudo-instruction is used. The 2056 // simulator is being used then a suitable pseudo-instruction is used. The
2053 // arguments and stack (csp) must be prepared by the caller as for a normal 2057 // arguments and stack (csp) must be prepared by the caller as for a normal
2054 // AAPCS64 call to 'printf'. 2058 // AAPCS64 call to 'printf'.
2055 // 2059 //
2056 // The 'args' argument should point to an array of variable arguments in their 2060 // The 'args' argument should point to an array of variable arguments in their
2057 // proper PCS registers (and in calling order). The argument registers can 2061 // proper PCS registers (and in calling order). The argument registers can
2058 // have mixed types. The format string (x0) should not be included. 2062 // have mixed types. The format string (x0) should not be included.
2059 void CallPrintf(int arg_count = 0, const CPURegister * args = NULL); 2063 void CallPrintf(int arg_count = 0, const CPURegister * args = NULL);
2060 2064
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after
2305 #error "Unsupported option" 2309 #error "Unsupported option"
2306 #define CODE_COVERAGE_STRINGIFY(x) #x 2310 #define CODE_COVERAGE_STRINGIFY(x) #x
2307 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) 2311 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x)
2308 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) 2312 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__)
2309 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> 2313 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm->
2310 #else 2314 #else
2311 #define ACCESS_MASM(masm) masm-> 2315 #define ACCESS_MASM(masm) masm->
2312 #endif 2316 #endif
2313 2317
2314 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_ 2318 #endif // V8_ARM64_MACRO_ASSEMBLER_ARM64_H_
OLDNEW
« no previous file with comments | « src/arm64/lithium-codegen-arm64.cc ('k') | src/arm64/macro-assembler-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698