git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] grep: skip UTF8 checks explicitly

From
Junio C Hamano <gitster@pobox.com>
Date
Jul 24, 2019, 16:08 UTC
Message-ID
<xmqq5znrs9d0.fsf@gitster-ct.c.googlers.com>
In-Reply-To
<nycvar.QRO.7.76.6.1907241248000.21907@tvgsbejvaqbjf.bet>
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
Show 6 quoted lines
> My reading of the situation is slightly different. I think
> PCRE_NO_UTF8_CHECK is off by default, but it only makes a difference in
> the non-JIT'ed code path. Since we use PCRE2's JIT when possible
> (because it leads to a quite nice performance improvement), we usually
> don't see those warnings. Carlo's patch makes the non-JIT'ed code path
> behave the same as our preferred code path.

You're right and we do want to make both codepaths behave the same way. The case we are having trouble with is without JIT, where the machinery to look for needle in a non-UTF8 binary haystack barfs and dies, which is unacceptable (imagine "git log --grep=..."), and we want the machinery to ignore random binary gunk just like the JIT codepath does.

Thanks.
Previous: Johannes SchindelinNext: Carlo Marcelo Arenas Belón
Message 7 of 26 in “grep: skip UTF8 checks explicitally”
  1. grep: skip UTF8 checks explicitallyCarlo Marcelo Arenas Belón, Jul 21, 2019
  2. Eric SunshineJul 21, 2019
  3. Johannes SchindelinJul 22, 2019
  4. grep: skip UTF8 checks explicitlyCarlo Marcelo Arenas Belón, Jul 22, 2019
  5. Junio C HamanoJul 24, 2019
  6. Johannes SchindelinJul 24, 2019
  7. Junio C HamanoJul 24, 2019
  8. grep: skip UTF8 checks explicitlyCarlo Marcelo Arenas Belón, Aug 28, 2019
  9. Carlo ArenasAug 28, 2019
  10. Carlo ArenasSep 9, 2019
  11. Junio C HamanoSep 9, 2019
  12. Ævar Arnfjörð BjarmasonJul 22, 2019
  13. Carlo ArenasJul 23, 2019
  14. Johannes SchindelinJul 23, 2019
  15. Carlo ArenasJul 24, 2019
  16. Johannes SchindelinJul 24, 2019
  17. Ævar Arnfjörð BjarmasonJul 24, 2019
  18. Junio C HamanoJul 24, 2019
  19. Johannes SchindelinJul 25, 2019
  20. Junio C HamanoJul 25, 2019
  21. Johannes SchindelinJul 25, 2019
  22. Ævar Arnfjörð BjarmasonJul 26, 2019
  23. Carlo ArenasJul 26, 2019
  24. Ævar Arnfjörð BjarmasonJul 26, 2019
  25. Junio C HamanoJul 26, 2019
  26. Ævar Arnfjörð BjarmasonJul 26, 2019

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.