Commit fb2643c8 authored by bmeurer's avatar bmeurer Committed by Commit bot

[turbofan] Truncation of Bit/Word8/16 to Word32 is a no-op.

TEST=mjsunit/compiler/regress-445859
BUG=chromium:445859
LOG=y
R=jarin@chromium.org

Review URL: https://codereview.chromium.org/828313002

Cr-Commit-Position: refs/heads/master@{#25951}
parent cf866b7c
......@@ -181,7 +181,7 @@ class RepresentationSelector {
} else {
// In the change phase, insert a change before the use if necessary.
MachineTypeUnion output = GetInfo(input)->output;
if ((output & kRepWord32) == 0) {
if ((output & (kRepBit | kRepWord8 | kRepWord16 | kRepWord32)) == 0) {
// Output representation doesn't match usage.
TRACE((" truncate-to-int32: #%d:%s(@%d #%d:%s) ", node->id(),
node->op()->mnemonic(), index, input->id(),
......
// Copyright 2014 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 foo = (function Module(global, env, buffer) {
"use asm";
var i8 = new global.Int8Array(buffer);
function foo() { i8[0] += 4294967295; }
return { foo: foo };
})(this, {}, new ArrayBuffer(64 * 1024)).foo;
foo();
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