diff --git a/loopy/types.py b/loopy/types.py
index 4ed6aa0ffe6aab8ec9fbdde5721b13658d9059cb..67c1c8257b583afe23c184def86cd5e0cd75faac 100644
--- a/loopy/types.py
+++ b/loopy/types.py
@@ -92,6 +92,9 @@ class NumpyType(LoopyType):
     def __hash__(self):
         return hash(self.dtype)
 
+    def update_persistent_hash(self, key_hash, key_builder):
+        key_builder.rec(key_hash, self.dtype)
+
     def __eq__(self, other):
         return (
                 type(self) == type(other)
@@ -168,6 +171,10 @@ class AtomicNumpyType(NumpyType, AtomicType):
     def __hash__(self):
         return 0xa7031c ^ hash(self.dtype)
 
+    def update_persistent_hash(self, key_hash, key_builder):
+        key_builder.rec(key_hash, 0xa7031c)
+        key_builder.rec(key_hash, self.dtype)
+
     def __repr__(self):
         return "atomic:%s" % repr(self.dtype)