diff --git a/debug/accuracy_tools/msprobe/core/common/utils.py b/debug/accuracy_tools/msprobe/core/common/utils.py index 50ad9e84c7dbd61b50d8faf70993953bba6ef73a..88e37958e8cdf80dfd150969669e1dd7aeac3d67 100644 --- a/debug/accuracy_tools/msprobe/core/common/utils.py +++ b/debug/accuracy_tools/msprobe/core/common/utils.py @@ -447,6 +447,7 @@ def recursion_depth_decorator(func_info): @wraps(func) def wrapper(*args, **kwargs): func_id = id(func) + global recursion_depth recursion_depth[func_id] += 1 if recursion_depth[func_id] > Const.MAX_DEPTH: msg = f"call {func_info} exceeds the recursion limit."