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

Side by Side Diff: src/s390/simulator-s390.cc

Issue 2270523002: S390: Implemente Multiply-Logical (ML) for simulator (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 4 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
« 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 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 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 #include <stdarg.h> 5 #include <stdarg.h>
6 #include <stdlib.h> 6 #include <stdlib.h>
7 #include <cmath> 7 #include <cmath>
8 8
9 #if V8_TARGET_ARCH_S390 9 #if V8_TARGET_ARCH_S390
10 10
(...skipping 11434 matching lines...) Expand 10 before | Expand all | Expand 10 after
11445 DECODE_RXY_A_INSTRUCTION(r1, x2, b2, d2); 11445 DECODE_RXY_A_INSTRUCTION(r1, x2, b2, d2);
11446 int64_t b2_val = (b2 == 0) ? 0 : get_register(b2); 11446 int64_t b2_val = (b2 == 0) ? 0 : get_register(b2);
11447 int64_t x2_val = (x2 == 0) ? 0 : get_register(x2); 11447 int64_t x2_val = (x2 == 0) ? 0 : get_register(x2);
11448 intptr_t d2_val = d2; 11448 intptr_t d2_val = d2;
11449 uint16_t mem_val = ReadHU(b2_val + d2_val + x2_val, instr); 11449 uint16_t mem_val = ReadHU(b2_val + d2_val + x2_val, instr);
11450 set_low_register(r1, mem_val); 11450 set_low_register(r1, mem_val);
11451 return length; 11451 return length;
11452 } 11452 }
11453 11453
11454 EVALUATE(ML) { 11454 EVALUATE(ML) {
11455 UNIMPLEMENTED(); 11455 DCHECK_OPCODE(ML);
11456 USE(instr); 11456 DECODE_RXY_A_INSTRUCTION(r1, x2, b2, d2);
11457 return 0; 11457 int64_t x2_val = (x2 == 0) ? 0 : get_register(x2);
11458 int64_t b2_val = (b2 == 0) ? 0 : get_register(b2);
11459 DCHECK(r1 % 2 == 0);
11460 uint32_t mem_val = ReadWU(b2_val + x2_val + d2, instr);
11461 uint32_t r1_val = get_low_register<uint32_t>(r1 + 1);
11462 uint64_t product =
11463 static_cast<uint64_t>(r1_val) * static_cast<uint64_t>(mem_val);
11464 uint32_t high_bits = product >> 32;
11465 r1_val = high_bits;
11466 uint32_t low_bits = product & 0x00000000FFFFFFFF;
11467 set_low_register(r1, high_bits);
11468 set_low_register(r1 + 1, low_bits);
11469 return length;
11458 } 11470 }
11459 11471
11460 EVALUATE(DL) { 11472 EVALUATE(DL) {
11461 UNIMPLEMENTED(); 11473 UNIMPLEMENTED();
11462 USE(instr); 11474 USE(instr);
11463 return 0; 11475 return 0;
11464 } 11476 }
11465 11477
11466 EVALUATE(ALC) { 11478 EVALUATE(ALC) {
11467 UNIMPLEMENTED(); 11479 UNIMPLEMENTED();
(...skipping 1154 matching lines...) Expand 10 before | Expand all | Expand 10 after
12622 return 0; 12634 return 0;
12623 } 12635 }
12624 12636
12625 #undef EVALUATE 12637 #undef EVALUATE
12626 12638
12627 } // namespace internal 12639 } // namespace internal
12628 } // namespace v8 12640 } // namespace v8
12629 12641
12630 #endif // USE_SIMULATOR 12642 #endif // USE_SIMULATOR
12631 #endif // V8_TARGET_ARCH_S390 12643 #endif // V8_TARGET_ARCH_S390
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