The change from LAMBDA to NAMED-LAMBDA causes the given lambda expression never (or rarely) to be structurally similar to anything already cached. This completely defeats the cache, which I think was probably unintentional.
whereas if you back out the change, and print *fgens* before and after ...
*fgens* => #<HASH-TABLE :TEST EQUAL :COUNT 22 {100034D4B3}>
...
*fgens* => #<HASH-TABLE :TEST EQUAL :COUNT 23 {100034D4B3}>
The change from LAMBDA to NAMED-LAMBDA causes the given lambda expression never (or rarely) to be structurally similar to anything already cached. This completely defeats the cache, which I think was probably unintentional.
SB-PCL> *fgens* generic- function- warning #'muffle-warning))
#<HASH-TABLE :TEST EQUAL :COUNT 21 {100034D4B3}>
SB-PCL> (handler-bind ((implicit-
(loop for i below 500
do (eval `(defmethod ,(symbolicate "F" (write-to-string i)) ((a cons)) (list ,i a)))))
NIL
SB-PCL> *fgens*
#<HASH-TABLE :TEST EQUAL :COUNT 521 {100034D4B3}>
whereas if you back out the change, and print *fgens* before and after ...
*fgens* => #<HASH-TABLE :TEST EQUAL :COUNT 22 {100034D4B3}>
...
*fgens* => #<HASH-TABLE :TEST EQUAL :COUNT 23 {100034D4B3}>