Hello Andy!

Andy Wingo <wi...@pobox.com> writes:

> On Tue 22 Jun 2010 23:32, l...@gnu.org (Ludovic Courtès) writes:
>
>> Andy Wingo <wi...@pobox.com> writes:
>>
>>> Nasty, but OK I guess if you need it. Why not also add a fast path for
>>> scm_is_eq (s1, s2), or for comparing stringbufs, or something ?
>>
>> Hmm yes.  Though if there are too many fast paths the whole thing ends
>> up being slow.  ;-)
>
>> I don’t expect (eq? s1 s2) and (eq? (string-buf s1) (string-buf s2)) to
>> be common enough to warrant a more specific special case, though.
>
> Does it affect your original case at all?

No, I was just comparing strings not eq?.

> In any event, it doesn't involve a memory dereference, only a
> branch. It's a cheap check.

Even cheaper to not do it.  :-)

Thanks,
Ludo’.

Reply via email to