You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2021/02/22 21:43:40 UTC

[GitHub] [tvm] areusch commented on a change in pull request #7481: Fix stack overflow when partially-__init__ Node raises exception.

areusch commented on a change in pull request #7481:
URL: https://github.com/apache/tvm/pull/7481#discussion_r580612333



##########
File path: python/tvm/_ffi/_ctypes/object.py
##########
@@ -106,6 +106,11 @@ class ObjectBase(object):
 
     def __del__(self):
         if _LIB is not None:
+            try:
+                handle = self.handle

Review comment:
       I thought about that but I think hasattr() is slow and this way we only enter the slow case when bad things happen




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org