Whenever I close a tab or window in Safari, my Mac will freeze temporarily.
The exact cause has not been identified, but it seems to be related to how Safari caches visited websites. Clearing Safari's history fixes the issue.