Dynamic protocol performance
Damien Cassou
damien.cassou at gmail.com
Thu Feb 7 13:16:11 UTC 2008
On Feb 7, 2008 10:32 AM, Zulq Alam <me at zulq.net> wrote:
> Damien Cassou wrote:
>
> > - messages you send but for which there is no implementation (even if
> > you do not implement a #subclassResponsibility)
>
> Ahh.. OK, thanks. So these are implicitly required. Mostly I would be
> interested in the explicit case and rarely in the implicit case.
This is because you are used to not having this information I guess.
Imagine, you code a method #m and, during its writing, you notice you
want another method #m2 to do part of the job. You can code #m and
send #m2, then, in your browser on the Dynamic Protocol Required, you
can click on the method #m2 and start coding it.
> I think it would be better to make two protocols, "explicitly required"
> and "implicitly required" (maybe with better names). What do you think?
I think it will be confusing but you may have a different opinion.
Just implement what you prefer.
> The performance of the implicit protocol wont be proportional to the
> number of selectors and will be bad so it could specify a pain threshold
> of 0. Therefore, it's calculation would always be deferred.
I agree.
> > I think RequiredSelectors does its job well (the algorithm is complex
> > and is the subject of an scientific article). We probably have to use
> > it in some way. Maybe we just have to set up an interest on this
> > class, I don't know.
>
> Declaring interest wont help with initial access. Here the only options
> you have are to (a) optimize #requiredSelectors, (b) never do it, (c) do
> it asynchronously, (d) do it only when you really must. I have gone for
> option (d) for simplicity. I may have a look at (a) when I get some time.
>
> Thanks,
> Zulq.
>
>
>
--
Damien Cassou
More information about the Squeak-dev
mailing list
|