[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#37321: 27.0.50; Excessive gc in a use case (el-search)
From: |
Eli Zaretskii |
Subject: |
bug#37321: 27.0.50; Excessive gc in a use case (el-search) |
Date: |
Wed, 09 Oct 2019 18:33:12 +0300 |
> From: Michael Heerdegen <michael_heerdegen@web.de>
> Cc: eggert@cs.ucla.edu, 37321@debbugs.gnu.org
> Date: Wed, 09 Oct 2019 16:47:58 +0200
>
> > AFAIK, the latter can only be done by changing your algorithms to
> > produce less garbage.
>
> I tried to find out what code produces the most garbage. It turned out
> that ca. 50% of garbage was generated by code that prevents infinite
> recursion when recursing into nested structures. I use hash tables to
> collect visited objects, and the hash tables cause the garbage. I tried
> to reuse hash tables and clear them after each use, but this makes the
> code much slower than what I win from gc.
>
> But 99,9% of el-searched code isn't cyclic, so the effort is for nothing
> most of the time. Is there an efficient way to find out if a given
> object is cyclic?
The hare/tortoise method we use in data.c?
Or maybe you could make your search non-recursive by using an
internal queue of requests (like in BFS vs DFS)?
(I wrote that based on 5 sec of thought, so maybe it makes no sense at
all.)
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Michael Heerdegen, 2019/10/08
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Eli Zaretskii, 2019/10/08
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Michael Heerdegen, 2019/10/08
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Eli Zaretskii, 2019/10/08
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Michael Heerdegen, 2019/10/08
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Eli Zaretskii, 2019/10/08
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Michael Heerdegen, 2019/10/08
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Eli Zaretskii, 2019/10/08
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Michael Heerdegen, 2019/10/09
- bug#37321: 27.0.50; Excessive gc in a use case (el-search),
Eli Zaretskii <=
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Paul Eggert, 2019/10/09
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Michael Heerdegen, 2019/10/10
- bug#37321: 27.0.50; Excessive gc in a use case (el-search), Michael Heerdegen, 2019/10/08