Commit e8188a2d authored by bradnelson's avatar bradnelson Committed by Commit bot

[wasm][asm.js] Exclude zero left hand side in arm64 isel.

BUG=641885
R=titzer@chromium.org,rossberg@chromium.org

Review-Url: https://codereview.chromium.org/2620953002
Cr-Commit-Position: refs/heads/master@{#42190}
parent e88e668e
......@@ -1069,6 +1069,7 @@ bool TryEmitBitfieldExtract32(InstructionSelector* selector, Node* node) {
// OP is >>> or >> and (K & 0x1f) != 0.
Int32BinopMatcher mleft(m.left().node());
if (mleft.right().HasValue() && m.right().HasValue() &&
(mleft.right().Value() & 0x1f) != 0 &&
(mleft.right().Value() & 0x1f) == (m.right().Value() & 0x1f)) {
DCHECK(m.IsWord32Shr() || m.IsWord32Sar());
ArchOpcode opcode = m.IsWord32Sar() ? kArm64Sbfx32 : kArm64Ubfx32;
......
// Copyright 2017 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
var __f_2 = (function __f_4() {
"use asm";
function __f_2(i) {
i = i|0;
i = i << -2147483648 >> -1073741824;
return i|0;
}
return { __f_2: __f_2 };
})().__f_2;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment