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

Side by Side Diff: src/s390/macro-assembler-s390.cc

Issue 2756733002: s390: Unify Visit(Word/Float)(32/64)(Unary/Bin)Op (Closed)
Patch Set: remove unnecessary check Created 3 years, 9 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 | « src/compiler/s390/instruction-selector-s390.cc ('k') | 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 <assert.h> // For assert 5 #include <assert.h> // For assert
6 #include <limits.h> // For LONG_MIN, LONG_MAX. 6 #include <limits.h> // For LONG_MIN, LONG_MAX.
7 7
8 #if V8_TARGET_ARCH_S390 8 #if V8_TARGET_ARCH_S390
9 9
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 5342 matching lines...) Expand 10 before | Expand all | Expand 10 after
5353 5353
5354 void MacroAssembler::Popcnt32(Register dst, Register src) { 5354 void MacroAssembler::Popcnt32(Register dst, Register src) {
5355 DCHECK(!src.is(r0)); 5355 DCHECK(!src.is(r0));
5356 DCHECK(!dst.is(r0)); 5356 DCHECK(!dst.is(r0));
5357 5357
5358 popcnt(dst, src); 5358 popcnt(dst, src);
5359 ShiftRight(r0, dst, Operand(16)); 5359 ShiftRight(r0, dst, Operand(16));
5360 ar(dst, r0); 5360 ar(dst, r0);
5361 ShiftRight(r0, dst, Operand(8)); 5361 ShiftRight(r0, dst, Operand(8));
5362 ar(dst, r0); 5362 ar(dst, r0);
5363 LoadlB(dst, dst); 5363 llgcr(dst, dst);
5364 } 5364 }
5365 5365
5366 #ifdef V8_TARGET_ARCH_S390X 5366 #ifdef V8_TARGET_ARCH_S390X
5367 void MacroAssembler::Popcnt64(Register dst, Register src) { 5367 void MacroAssembler::Popcnt64(Register dst, Register src) {
5368 DCHECK(!src.is(r0)); 5368 DCHECK(!src.is(r0));
5369 DCHECK(!dst.is(r0)); 5369 DCHECK(!dst.is(r0));
5370 5370
5371 popcnt(dst, src); 5371 popcnt(dst, src);
5372 ShiftRightP(r0, dst, Operand(32)); 5372 ShiftRightP(r0, dst, Operand(32));
5373 AddP(dst, r0); 5373 AddP(dst, r0);
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
5460 } 5460 }
5461 if (mag.shift > 0) ShiftRightArith(result, result, Operand(mag.shift)); 5461 if (mag.shift > 0) ShiftRightArith(result, result, Operand(mag.shift));
5462 ExtractBit(r0, dividend, 31); 5462 ExtractBit(r0, dividend, 31);
5463 AddP(result, r0); 5463 AddP(result, r0);
5464 } 5464 }
5465 5465
5466 } // namespace internal 5466 } // namespace internal
5467 } // namespace v8 5467 } // namespace v8
5468 5468
5469 #endif // V8_TARGET_ARCH_S390 5469 #endif // V8_TARGET_ARCH_S390
OLDNEW
« no previous file with comments | « src/compiler/s390/instruction-selector-s390.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698