nir/search: Log Boolean constants instead of asserting
authorIan Romanick <ian.d.romanick@intel.com>
Mon, 24 Jun 2019 21:49:17 +0000 (14:49 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Sat, 29 Jun 2019 01:56:19 +0000 (18:56 -0700)
Reviewed-by: Connor Abbott <cwabbott0@gmail.com>
src/compiler/nir/nir_search.c

index 2179ca0a3116b0af413c42cbabeb58e63b9dc8c8..1f68f78afa337aef12c7f791807b6fab26a85297 100644 (file)
@@ -561,6 +561,9 @@ MAYBE_UNUSED static void dump_value(const nir_search_value *val)
       case nir_type_uint:
          printf("0x%"PRIx64, sconst->data.u);
          break;
+      case nir_type_bool:
+         printf("%s", sconst->data.u != 0 ? "True" : "False");
+         break;
       default:
          unreachable("bad const type");
       }