From fa3ff32e845ca59113fbdc2044a7dece3da6c2c8 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Fri, 30 Sep 2022 09:23:06 -0700 Subject: Fix handling of unreachable selects in Directize (#5098) We ignored only unreachable conditions, but we must ignore the arms as well, or else we could error. --- src/passes/call-utils.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/passes/call-utils.h b/src/passes/call-utils.h index 175946c0e..7f2ebfda3 100644 --- a/src/passes/call-utils.h +++ b/src/passes/call-utils.h @@ -76,7 +76,7 @@ convertToDirectCalls(T* curr, return nullptr; } - if (select->condition->type == Type::unreachable) { + if (select->type == Type::unreachable) { // Leave this for DCE. return nullptr; } -- cgit v1.2.3