Commit 4892cd63 authored by jkummerow's avatar jkummerow Committed by Commit bot

[turbofan] Add a CHECK for max node input count

This is a temporary band-aid to turn an uncontrolled segfault into
a safe crash. The proper fix will probably be to abort compilation.

BUG=chromium:582702

Review-Url: https://codereview.chromium.org/2021433003
Cr-Commit-Position: refs/heads/master@{#36554}
parent c3ffc92d
......@@ -815,6 +815,9 @@ class Instruction final {
DCHECK(output_count == 0 || outputs != nullptr);
DCHECK(input_count == 0 || inputs != nullptr);
DCHECK(temp_count == 0 || temps != nullptr);
// TODO(jarin/mstarzinger): Handle this gracefully. See crbug.com/582702.
CHECK(InputCountField::is_valid(input_count));
size_t total_extra_ops = output_count + input_count + temp_count;
if (total_extra_ops != 0) total_extra_ops--;
int size = static_cast<int>(
......
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