ORC: prepare for another patent-pending optimization (#15996)

* ORC: prepare for another patent-pending optimization

* bugfix

* '=copy' for refs can take a cyclic parameter for more ORC optimizations

* ORC: exploit the common 'it = it.next' pattern

* can't hurt to check for nil

* use an algorithm that is not obviously broken

* restore the test case

* final cleanups for --gc:orc
This commit is contained in:
Andreas Rumpf 2020-11-18 22:31:06 +01:00 • committed by GitHub
commit b9eb91cbb5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 147 additions and 39 deletions

View file

@ -1,5 +1,5 @@
discard """
outputsub: "(allocCount: 4016, deallocCount: 4014)"
outputsub: "(allocCount: 4014, deallocCount: 4012)"
cmd: "nim c --gc:orc -d:nimAllocStats $file"
"""