internal/memoize: do not iterate all handles on generation destruction
internal/memoize: do not iterate all handles on generation destruction

This allows reducing critical section of `g.store.mu` as the vast
majority of entries do not rely on generation-based GC.

Change-Id: I985af0b38504ddedb22649290deac91797577b75
Reviewed-on: https://go-review.googlesource.com/c/tools/+/413656
Reviewed-by: David Chase <ae171625adc8645b8b79b7e405a6da5aba5341e0@google.com>
Reviewed-by: Alan Donovan <7069e9552f9d110b0a0f326b96f22f63fb99dfc1@google.com>
Run-TryBot: Robert Findley <9179eee875d1ee628c37fb47d7e749e855ffd21f@google.com>
Reviewed-by: Robert Findley <9179eee875d1ee628c37fb47d7e749e855ffd21f@google.com>
TryBot-Result: Gopher Robot <66cb808b70d30c07676d5e946fee83fd561249e5@golang.org>
gopls-CI: kokoro <2ac7b1f3fa578934c95181d4272be0d3bca00121@google.com>

golang/tools,golang/tools,golang/tools,golang/tools,golang/tools