turn-off-jit-on-request.patch 1.0 KB

1234567891011121314151617181920212223242526272829303132
  1. From: Дмитрий Потапов <orivej@yandex-team.ru>
  2. Date: Sun, 14 Feb 2021 19:43:48 +0300
  3. Subject: [PATCH] Conditional PCRE JIT compilation.
  4. PCRE JIT adds ≈104KB to binary size which can be critical for embedded software, so we need turn off switch which can be overriden in ya.make.
  5. REVIEW: 1640869
  6. --- a/config.h
  7. +++ b/config.h
  8. @@ -293,8 +293,10 @@
  9. backward compatibility; new code need not use it. */
  10. #define STDC_HEADERS 1
  11. +#ifdef ARCADIA_PCRE_ENABLE_JIT
  12. /* Define to any value to enable support for Just-In-Time compiling. */
  13. #define SUPPORT_JIT /**/
  14. +#endif
  15. /* Define to any value to allow pcregrep to be linked with libbz2, so that it
  16. is able to handle .bz2 files. */
  17. @@ -319,8 +321,10 @@
  18. /* Define to any value to enable the 8 bit PCRE library. */
  19. #define SUPPORT_PCRE8 /**/
  20. +#ifdef ARCADIA_PCRE_ENABLE_JIT
  21. /* Define to any value to enable JIT support in pcregrep. */
  22. #define SUPPORT_PCREGREP_JIT /**/
  23. +#endif
  24. /* Define to any value to enable support for Unicode properties. */
  25. #define SUPPORT_UCP /**/