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

Side by Side Diff: src/a64/assembler-a64.h

Issue 140893010: A64: Relax assert in register copy ctor. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/a64
Patch Set: Created 6 years, 10 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 | « no previous file | no next file » | 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 // 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 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 Register() { 122 Register() {
123 reg_code = 0; 123 reg_code = 0;
124 reg_size = 0; 124 reg_size = 0;
125 reg_type = CPURegister::kNoRegister; 125 reg_type = CPURegister::kNoRegister;
126 } 126 }
127 127
128 Register(const CPURegister& r) { // NOLINT(runtime/explicit) 128 Register(const CPURegister& r) { // NOLINT(runtime/explicit)
129 reg_code = r.reg_code; 129 reg_code = r.reg_code;
130 reg_size = r.reg_size; 130 reg_size = r.reg_size;
131 reg_type = r.reg_type; 131 reg_type = r.reg_type;
132 ASSERT(IsValid()); 132 ASSERT(IsValid() || IsNone());
133 } 133 }
134 134
135 bool IsValid() const { 135 bool IsValid() const {
136 ASSERT(IsRegister() || IsNone()); 136 ASSERT(IsRegister() || IsNone());
137 return IsValidRegister(); 137 return IsValidRegister();
138 } 138 }
139 139
140 static Register XRegFromCode(unsigned code); 140 static Register XRegFromCode(unsigned code);
141 static Register WRegFromCode(unsigned code); 141 static Register WRegFromCode(unsigned code);
142 142
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 FPRegister() { 225 FPRegister() {
226 reg_code = 0; 226 reg_code = 0;
227 reg_size = 0; 227 reg_size = 0;
228 reg_type = CPURegister::kNoRegister; 228 reg_type = CPURegister::kNoRegister;
229 } 229 }
230 230
231 FPRegister(const CPURegister& r) { // NOLINT(runtime/explicit) 231 FPRegister(const CPURegister& r) { // NOLINT(runtime/explicit)
232 reg_code = r.reg_code; 232 reg_code = r.reg_code;
233 reg_size = r.reg_size; 233 reg_size = r.reg_size;
234 reg_type = r.reg_type; 234 reg_type = r.reg_type;
235 ASSERT(IsValid()); 235 ASSERT(IsValid() || IsNone());
236 } 236 }
237 237
238 bool IsValid() const { 238 bool IsValid() const {
239 ASSERT(IsFPRegister() || IsNone()); 239 ASSERT(IsFPRegister() || IsNone());
240 return IsValidFPRegister(); 240 return IsValidFPRegister();
241 } 241 }
242 242
243 static FPRegister SRegFromCode(unsigned code); 243 static FPRegister SRegFromCode(unsigned code);
244 static FPRegister DRegFromCode(unsigned code); 244 static FPRegister DRegFromCode(unsigned code);
245 245
(...skipping 1803 matching lines...) Expand 10 before | Expand all | Expand 10 after
2049 class EnsureSpace BASE_EMBEDDED { 2049 class EnsureSpace BASE_EMBEDDED {
2050 public: 2050 public:
2051 explicit EnsureSpace(Assembler* assembler) { 2051 explicit EnsureSpace(Assembler* assembler) {
2052 assembler->CheckBuffer(); 2052 assembler->CheckBuffer();
2053 } 2053 }
2054 }; 2054 };
2055 2055
2056 } } // namespace v8::internal 2056 } } // namespace v8::internal
2057 2057
2058 #endif // V8_A64_ASSEMBLER_A64_H_ 2058 #endif // V8_A64_ASSEMBLER_A64_H_
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698