Commit 71144e5a authored by mtrofin's avatar mtrofin Committed by Commit bot

[turbofan] Use correct block when tracing pending assessments in regalloc verifier

The verifier needs to use the block and assessments in that block corresponding to
a predecessor of a "pending" assessment. Not doing that causes incorrect
assessments when 2 locations are swapped.

BUG=665402

Review-Url: https://codereview.chromium.org/2515803002
Cr-Commit-Position: refs/heads/master@{#41159}
parent d0fe942d
......@@ -469,7 +469,9 @@ void RegisterAllocatorVerifier::ValidateFinalAssessment(
// is virtual_register.
const PendingAssessment* old = assessment->original_pending_assessment();
CHECK_NOT_NULL(old);
ValidatePendingAssessment(block_id, op, current_assessments, old,
RpoNumber old_block = old->origin()->rpo_number();
BlockAssessments* old_block_assessments = assessments_[old_block];
ValidatePendingAssessment(old_block, op, old_block_assessments, old,
virtual_register);
}
......
// Copyright 2016 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.
//
// Flags: --expose-wasm
load("test/mjsunit/wasm/wasm-constants.js");
load("test/mjsunit/wasm/wasm-module-builder.js");
var wire_bytes = readbuffer("test/mjsunit/regress/wasm/665402.wasm");
var module = new WebAssembly.Module(wire_bytes);
assertTrue(module != undefined);
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