cpython/Tools/build
Eric Snow 4f71f1680d
[3.12] gh-106931: Intern Statically Allocated Strings Globally (gh-107272) (gh-110713)
We tried this before with a dict and for all interned strings.  That ran into problems due to interpreter isolation.  However, exclusively using a per-interpreter cache caused some inconsistency that can eliminate the benefit of interning.  Here we circle back to using a global cache, but only for statically allocated strings.  We also use a more-basic _Py_hashtable_t for that global cache instead of a dict.

Ideally we would only have the global cache, but the optional isolation of each interpreter's allocator means that a non-static string object must not outlive its interpreter.  Thus we would have to store a copy of each such interned string in the global cache, tied to the main interpreter.

(cherry-picked from commit b72947a8d2)
2023-11-27 23:51:12 +00:00
..
check_extension_modules.py gh-97669: Create Tools/build/ directory (#97963) 2022-10-17 12:01:00 +02:00
deepfreeze.py [3.12] gh-106931: Intern Statically Allocated Strings Globally (gh-107272) (gh-110713) 2023-11-27 23:51:12 +00:00
freeze_modules.py [3.12] gh-108740: Fix "make regen-all" race condition (#108741) (#109019) 2023-09-08 15:19:20 +02:00
generate_global_objects.py gh-102500: Implement PEP 688 (#102521) 2023-05-04 07:59:46 -07:00
generate_levenshtein_examples.py gh-99016: Make build scripts compatible with Python 3.8 (GH-99017) 2022-11-02 20:30:09 +02:00
generate_opcode_h.py gh-103963: fix 'make regen-opcode' in out-of-tree builds (#104177) 2023-05-04 17:45:56 +00:00
generate_re_casefix.py gh-97669: Create Tools/build/ directory (#97963) 2022-10-17 12:01:00 +02:00
generate_sre_constants.py gh-97669: Create Tools/build/ directory (#97963) 2022-10-17 12:01:00 +02:00
generate_stdlib_module_names.py gh-98040: Remove just the imp module (#98573) 2023-04-28 16:17:58 -07:00
generate_token.py gh-102856: Initial implementation of PEP 701 (#102855) 2023-04-19 11:18:16 -05:00
parse_html5_entities.py gh-97669: Create Tools/build/ directory (#97963) 2022-10-17 12:01:00 +02:00
regen-configure.sh [3.12] gh-112088: Run autoreconf in GHA check_generated_files (GH-112090) (#112159) 2023-11-16 15:55:40 +01:00
smelly.py gh-97669: Create Tools/build/ directory (#97963) 2022-10-17 12:01:00 +02:00
stable_abi.py [3.12] gh-102304: doc: Add links to Stable ABI and Limited C API (#105345) (#105371) 2023-06-06 13:11:28 +00:00
umarshal.py [3.12] Fix the long64 reader in umarshal.py (GH-107828) (#107849) 2023-08-11 11:59:45 +02:00
update_file.py gh-97669: Create Tools/build/ directory (#97963) 2022-10-17 12:01:00 +02:00
verify_ensurepip_wheels.py [3.12] gh-109002: Ensure only one wheel for each vendored package (GH-109003) (#109005) 2023-09-06 20:01:36 +02:00