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

Side by Side Diff: src/x64/regexp-macro-assembler-x64.cc

Issue 11695006: Cleanup RelocInfo::NONE usage. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 11 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 262 matching lines...) Expand 10 before | Expand all | Expand 10 after
273 if (i + 8 <= n) { 273 if (i + 8 <= n) {
274 uint64_t combined_chars = 274 uint64_t combined_chars =
275 (static_cast<uint64_t>(str[i + 0]) << 0) || 275 (static_cast<uint64_t>(str[i + 0]) << 0) ||
276 (static_cast<uint64_t>(str[i + 1]) << 8) || 276 (static_cast<uint64_t>(str[i + 1]) << 8) ||
277 (static_cast<uint64_t>(str[i + 2]) << 16) || 277 (static_cast<uint64_t>(str[i + 2]) << 16) ||
278 (static_cast<uint64_t>(str[i + 3]) << 24) || 278 (static_cast<uint64_t>(str[i + 3]) << 24) ||
279 (static_cast<uint64_t>(str[i + 4]) << 32) || 279 (static_cast<uint64_t>(str[i + 4]) << 32) ||
280 (static_cast<uint64_t>(str[i + 5]) << 40) || 280 (static_cast<uint64_t>(str[i + 5]) << 40) ||
281 (static_cast<uint64_t>(str[i + 6]) << 48) || 281 (static_cast<uint64_t>(str[i + 6]) << 48) ||
282 (static_cast<uint64_t>(str[i + 7]) << 56); 282 (static_cast<uint64_t>(str[i + 7]) << 56);
283 __ movq(rax, combined_chars, RelocInfo::NONE); 283 __ movq(rax, combined_chars, RelocInfo::NONE64);
284 __ cmpq(rax, Operand(rbx, byte_offset + i)); 284 __ cmpq(rax, Operand(rbx, byte_offset + i));
285 i += 8; 285 i += 8;
286 } else if (i + 4 <= n) { 286 } else if (i + 4 <= n) {
287 uint32_t combined_chars = 287 uint32_t combined_chars =
288 (static_cast<uint32_t>(str[i + 0]) << 0) || 288 (static_cast<uint32_t>(str[i + 0]) << 0) ||
289 (static_cast<uint32_t>(str[i + 1]) << 8) || 289 (static_cast<uint32_t>(str[i + 1]) << 8) ||
290 (static_cast<uint32_t>(str[i + 2]) << 16) || 290 (static_cast<uint32_t>(str[i + 2]) << 16) ||
291 (static_cast<uint32_t>(str[i + 3]) << 24); 291 (static_cast<uint32_t>(str[i + 3]) << 24);
292 __ cmpl(Operand(rbx, byte_offset + i), Immediate(combined_chars)); 292 __ cmpl(Operand(rbx, byte_offset + i), Immediate(combined_chars));
293 i += 4; 293 i += 4;
294 } else { 294 } else {
295 __ cmpb(Operand(rbx, byte_offset + i), 295 __ cmpb(Operand(rbx, byte_offset + i),
296 Immediate(static_cast<int8_t>(str[i]))); 296 Immediate(static_cast<int8_t>(str[i])));
297 i++; 297 i++;
298 } 298 }
299 } else { 299 } else {
300 ASSERT(mode_ == UC16); 300 ASSERT(mode_ == UC16);
301 if (i + 4 <= n) { 301 if (i + 4 <= n) {
302 uint64_t combined_chars = *reinterpret_cast<const uint64_t*>(&str[i]); 302 uint64_t combined_chars = *reinterpret_cast<const uint64_t*>(&str[i]);
303 __ movq(rax, combined_chars, RelocInfo::NONE); 303 __ movq(rax, combined_chars, RelocInfo::NONE64);
304 __ cmpq(rax, 304 __ cmpq(rax,
305 Operand(rsi, rdi, times_1, byte_offset + i * sizeof(uc16))); 305 Operand(rsi, rdi, times_1, byte_offset + i * sizeof(uc16)));
306 i += 4; 306 i += 4;
307 } else if (i + 2 <= n) { 307 } else if (i + 2 <= n) {
308 uint32_t combined_chars = *reinterpret_cast<const uint32_t*>(&str[i]); 308 uint32_t combined_chars = *reinterpret_cast<const uint32_t*>(&str[i]);
309 __ cmpl(Operand(rsi, rdi, times_1, byte_offset + i * sizeof(uc16)), 309 __ cmpl(Operand(rsi, rdi, times_1, byte_offset + i * sizeof(uc16)),
310 Immediate(combined_chars)); 310 Immediate(combined_chars));
311 i += 2; 311 i += 2;
312 } else { 312 } else {
313 __ movzxwl(rax, 313 __ movzxwl(rax,
(...skipping 1221 matching lines...) Expand 10 before | Expand all | Expand 10 after
1535 } 1535 }
1536 } 1536 }
1537 1537
1538 #undef __ 1538 #undef __
1539 1539
1540 #endif // V8_INTERPRETED_REGEXP 1540 #endif // V8_INTERPRETED_REGEXP
1541 1541
1542 }} // namespace v8::internal 1542 }} // namespace v8::internal
1543 1543
1544 #endif // V8_TARGET_ARCH_X64 1544 #endif // V8_TARGET_ARCH_X64
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698