Fixed python MapElementTypeToDType for boolean type. (#8222)
diff --git a/bindings/python/iree/runtime/hal.cc b/bindings/python/iree/runtime/hal.cc
index d6be403..a4c7768 100644
--- a/bindings/python/iree/runtime/hal.cc
+++ b/bindings/python/iree/runtime/hal.cc
@@ -287,10 +287,7 @@
dtype_code = "d";
break;
case IREE_HAL_ELEMENT_TYPE_VALUE(IREE_HAL_NUMERICAL_TYPE_INTEGER, 1):
- // Due to layering issues it is not uncommon to get i1 buffer views
- // and we just silently promote them to i8 since that is what they are.
- // Really i1 should not exist at this boundary.
- dtype_code = "b";
+ dtype_code = "?";
break;
default:
throw RaiseValueError("Unsupported VM Buffer -> numpy dtype mapping");