[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Matching regex case-sensitively in C strings?
From: |
Eli Zaretskii |
Subject: |
Re: Matching regex case-sensitively in C strings? |
Date: |
Wed, 09 Nov 2022 15:06:24 +0200 |
> From: Mattias Engdegård <mattiase@acm.org>
> Date: Wed, 9 Nov 2022 11:33:09 +0100
> Cc: Yuan Fu <casouri@gmail.com>, emacs-devel@gnu.org
>
> 8 nov. 2022 kl. 20.37 skrev Eli Zaretskii <eliz@gnu.org>:
>
> >> fast_c_string_match_ignore_case (Lisp_Object regexp,
> >> const char *string, ptrdiff_t len)
> >> {
> >> + return fast_c_string_match (regexp, string, len, true);
> >> +}
> >
> > I'm bothered that this function, which is supposed to be fast, will
> > now be slower due to an extra function call.
>
> You are right to worry about it, but there is actually no need for
> concern here: it's a tail call (and the extra argument is last) so
> it should compile to an unconditional jump (and setting a register).
That's not what I see here, even with -O2.
- Matching regex case-sensitively in C strings?, Yuan Fu, 2022/11/07
- Re: Matching regex case-sensitively in C strings?, Eli Zaretskii, 2022/11/07
- Re: Matching regex case-sensitively in C strings?, Yuan Fu, 2022/11/07
- Re: Matching regex case-sensitively in C strings?, Mattias Engdegård, 2022/11/08
- Re: Matching regex case-sensitively in C strings?, Eli Zaretskii, 2022/11/08
- Re: Matching regex case-sensitively in C strings?, Yuan Fu, 2022/11/08
- Re: Matching regex case-sensitively in C strings?, Eli Zaretskii, 2022/11/08
- Re: Matching regex case-sensitively in C strings?, Yuan Fu, 2022/11/08
- Re: Matching regex case-sensitively in C strings?, Mattias Engdegård, 2022/11/09
- Re: Matching regex case-sensitively in C strings?, Mattias Engdegård, 2022/11/09
- Re: Matching regex case-sensitively in C strings?,
Eli Zaretskii <=
- Re: Matching regex case-sensitively in C strings?, Mattias Engdegård, 2022/11/10
- Re: Matching regex case-sensitively in C strings?, Eli Zaretskii, 2022/11/10
- Re: Matching regex case-sensitively in C strings?, Robert Pluim, 2022/11/10
- Re: Matching regex case-sensitively in C strings?, Mattias Engdegård, 2022/11/10
- Re: Matching regex case-sensitively in C strings?, Yuan Fu, 2022/11/10