From d51ecde8c2e488fc299d6033bbc18202ee5058de Mon Sep 17 00:00:00 2001 From: whitequark Date: Sun, 29 Nov 2020 16:33:45 +0000 Subject: [PATCH] clean: keep $print cells, since they have unmodelled side effects. --- passes/opt/opt_clean.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/passes/opt/opt_clean.cc b/passes/opt/opt_clean.cc index cb2490dc7..4da67cf63 100644 --- a/passes/opt/opt_clean.cc +++ b/passes/opt/opt_clean.cc @@ -79,6 +79,9 @@ struct keep_cache_t if (!ignore_specify && cell->type.in(ID($specify2), ID($specify3), ID($specrule))) return true; + if (cell->type == ID($print)) + return true; + if (cell->has_keep_attr()) return true;