Andrey Grozin writes:
> Hi *,
>
> My key was going to expire soon. So, as usual, I have prolonged it for
> the next year (several days ago). I've sent it to the Gentoo
> keyserver. I've checked that the fingerpring of my key in LDAP
> coinsides with the fingerprint I see locally.
>
> Today I've
Hi *,
My key was going to expire soon. So, as usual, I have prolonged it for the
next year (several days ago). I've sent it to the Gentoo keyserver. I've
checked that the fingerpring of my key in LDAP coinsides with the
fingerprint I see locally.
Today I've tried to bump dev-lisp/sbcl to
On Tue, 2023-06-13 at 11:07 +0200, Ulrich Mueller wrote:
> > > > > > On Tue, 13 Jun 2023, Michał Górny wrote:
>
> > _pypi_normalize_name() {
> > local name=${1}
> > - local shopt_save=$(shopt -p extglob)
> > - shopt -s extglob
> > + local prev_extglob=-s
> > + if ! shopt -p extglob
> On Tue, 13 Jun 2023, Michał Górny wrote:
> _pypi_normalize_name() {
> local name=${1}
> - local shopt_save=$(shopt -p extglob)
> - shopt -s extglob
> + local prev_extglob=-s
> + if ! shopt -p extglob >/dev/null; then
> + prev_extglob=-u
> +
Suggested by Eli Schwartz. This gives roughly 5260 ops / s, over 550%
speedup.
The complete patch series therefore increases the speed from roughly
326 ops / s to 5260 ops / s, making the common case 16 times faster.
Closes: https://bugs.gentoo.org/908411
Closes:
Introduce an internal helper for _pypi_sdist_url that doesn't require
subshell, and therefore eliminate all subshells from global scope.
We're nearing 952 ops / s, further 39% speedup.
Signed-off-by: Michał Górny
---
eclass/pypi.eclass | 53 +-
1 file
Provide an internal helper to translate versions without a subshell,
and use it in the common case. Now the benchmark gives 685 ops / s,
which means it's another 28% speedup.
Signed-off-by: Michał Górny
---
eclass/pypi.eclass | 31 +--
1 file changed, 21
Provide an internal helper to normalize names without a subshell.
This gives 535 ops / s, so a further 44% speedup.
Signed-off-by: Michał Górny
---
eclass/pypi.eclass | 39 +++
1 file changed, 27 insertions(+), 12 deletions(-)
diff --git a/eclass/pypi.eclass
Instead of translating version two times, once in pypi_sdist_url
and then when setting S, do it once and store the result. This gives
roughly 371 ops / s, i.e. a 13% speedup.
Signed-off-by: Michał Górny
---
eclass/pypi.eclass | 10 ++
1 file changed, 6 insertions(+), 4 deletions(-)
The benchmark yield roughly 327 ops / s on my machine.
Signed-off-by: Michał Górny
---
eclass/tests/pypi-bench.sh | 23 +++
1 file changed, 23 insertions(+)
create mode 100755 eclass/tests/pypi-bench.sh
diff --git a/eclass/tests/pypi-bench.sh b/eclass/tests/pypi-bench.sh
Signed-off-by: Michał Górny
---
eclass/pypi.eclass | 22 +++---
1 file changed, 15 insertions(+), 7 deletions(-)
diff --git a/eclass/pypi.eclass b/eclass/pypi.eclass
index 13dd56fa4fec..732b0c6184ef 100644
--- a/eclass/pypi.eclass
+++ b/eclass/pypi.eclass
@@ -221,12 +221,20 @@
Hi,
Here's a set of patches that improve performance of pypi.eclass
by eliminating the subshells from the most common code paths. It comes
with a trivial benchmarking tool that shows roughly 16 times speedup
from the changes.
Thanks to Sam for bringing the problem up, and to Eli Schwartz for
12 matches
Mail list logo