Dominic Schulz <dominic.schulz@...> writes:
> Can we just change this function to be this?
> (defun safe-method-specializers (method)
> (method-specializers method))
> It seems to be a little faster according to sprof in my application.
Briefly: no. The point of the SAFE-<accessor> functions is that users
of the MOP are allowed to define methods on those accessors, and also
those accessors are part of the protocol for computing some aspect of
method dispatch (e.g. effective method computation, or applicable
methods, or similar). Thus, we need the SAFE-<accessor> variants to be
able to break metacircles, where a user defines a method on some
accessor, the system needs to compute an effective method for that
accessor, and needs then to be able to call that accessor (but it can't
because the effective method hasn't been computed yet).
In the case of your application, I'd try looking at why method
specializers are being repeatedly reaccessed...