Abstract, and Rationale Amirouche (09 Sep 2022 18:55 UTC)
Re: Abstract, and Rationale Marc Nieper-Wißkirchen (09 Sep 2022 19:02 UTC)
Re: Abstract, and Rationale Amirouche (09 Sep 2022 19:35 UTC)
Re: Abstract, and Rationale Marc Nieper-Wißkirchen (09 Sep 2022 19:51 UTC)
Re: Abstract, and Rationale John Cowan (09 Sep 2022 21:59 UTC)
Re: Abstract, and Rationale Marc Nieper-Wißkirchen (10 Sep 2022 07:03 UTC)
Re: Abstract, and Rationale Amirouche (10 Sep 2022 08:46 UTC)
Re: Abstract, and Rationale John Cowan (10 Sep 2022 10:41 UTC)

Re: Abstract, and Rationale Marc Nieper-Wißkirchen 10 Sep 2022 07:03 UTC

Am Fr., 9. Sept. 2022 um 23:59 Uhr schrieb John Cowan <xxxxxx@ccil.org>:

>
>> As a side remark: Using `iota` like this shouldn't be used with great care as it constructs a list in memory which is then discarded.
>
>
> Unless it is larger than the size of the GC nursery, it doesn't really cost anything.

Does it really not cost anything?

It does produce garbage in the GC nursery (unless the compiler is
"sufficiently smart"), so a minor GC will kick in earlier. This will
at least touch the then-live objects in the nursery. Depending on how
much the minor GC will be triggered, this should make a difference.
Python 2 offered `xrange' as a replacement for `range', for example.