A deep structural memoization utility for objects to reuse identical shapes and references efficiently.