]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commit
Performance within instances()
authorMike Bayer <mike_mp@zzzcomputing.com>
Thu, 23 Feb 2017 19:40:00 +0000 (14:40 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Thu, 23 Feb 2017 21:56:20 +0000 (16:56 -0500)
commitfe1cabb88a060378c839bda53992882f67b525c7
tree618907c2edc5d9ec183e850eab5a958e789da042
parent4c5cfa8bc6cc5dba9a3d8f28abc01f652c0c952e
Performance within instances()

Continuing from Ie43beecf37945b2bb7fff0aaa597a597293daa18,
also observed is the overhead of PathRegsitry memoized token
functions, as these paths are not cached in the case of
long joinedloader chains.  The memoizations here were made
with short paths in mind, and have been replaced with
an inlined straight create of these paths up front, producing
callcounts very similar to 0.8. Combined with the previous
optimizations, 1.1 now runs the "joined eager load of one row"
worst case test in about 40% fewer calls than 0.8 and 60%
fewer than 1.1.5.

Change-Id: Ib5e1c1345a1dd8edfbdb3fed06eb717d4e164d31
Fixes: #3915
doc/build/changelog/changelog_11.rst
lib/sqlalchemy/orm/interfaces.py
lib/sqlalchemy/orm/path_registry.py
test/aaa_profiling/test_orm.py
test/profiles.txt