From b3775b5e4e150439276ad3d34f1bb564b28e8ef5 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Fri, 6 Oct 2023 16:41:13 -0700 Subject: Automatically discard global effects in the rare passes that add effects (#5999) All logging/instrumentation passes need to do this, to avoid us using stale global effects that are too low (too high is not optimal either, but at least it cannot cause bugs). --- src/passes/SpillPointers.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/passes/SpillPointers.cpp') diff --git a/src/passes/SpillPointers.cpp b/src/passes/SpillPointers.cpp index f496b8c79..3af7039cd 100644 --- a/src/passes/SpillPointers.cpp +++ b/src/passes/SpillPointers.cpp @@ -37,6 +37,9 @@ struct SpillPointers : public WalkerPass>> { bool isFunctionParallel() override { return true; } + // Adds writes to memory. + bool addsEffects() override { return true; } + std::unique_ptr create() override { return std::make_unique(); } -- cgit v1.2.3