From: Eddie Hung Date: Fri, 19 Jul 2019 20:58:50 +0000 (-0700) Subject: Do not access beyond bounds X-Git-Tag: working-ls180~1163^2~9 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=cb0fd0521531a69632102f5fad8cdc9996ed4dee;p=yosys.git Do not access beyond bounds --- diff --git a/passes/opt/wreduce.cc b/passes/opt/wreduce.cc index 294f0d57e..908a85d5b 100644 --- a/passes/opt/wreduce.cc +++ b/passes/opt/wreduce.cc @@ -372,7 +372,7 @@ struct WreduceWorker int i; for (i = 0; i < GetSize(sig); i++) { - if (B[i] != S0 && (sub || A[i] != S0)) + if (B.at(i, Sx) != S0 && (sub || A.at(i, Sx) != S0)) break; if (B[i] == S0) module->connect(sig[i], A[i]);