attempting to fix memory consumption issues