The non-intrusive ad-hoc borrowing scheme…

Ola Fosheim Grøstad ola.fosheim.grostad at
Fri Nov 22 18:35:48 UTC 2019

On Friday, 22 November 2019 at 17:54:53 UTC, Paulo Pinto wrote:
> You mean the optimization that gets slammed by state of the art 
> tracing GC implementations?

You can get the exact same performance from ARC as from Rust, 
because the concept is the same... but Swift is built on 
Objective-C's implementation. What is wrong here is to reference 
a specific implementation.

> If one cares about performance there are only two paths, linear 
> and affine type systems with their complexity for typical every 
> day coding, or tracing GCs.

Actually, no. That "benchmark" didn't really tell me anything 
interesting. It might be interesting for people wanting to 
implementing network drivers in a managed language, which is 
worrisome  for a large number of reasons... (I mean, why would 
you implement a tiny program of 1000 lines using a GC...)

> Reference counting GC are just the easy way to get automatic 
> memory management, and when one adds enough machinery to make 
> them compete with tracing GC in performance, they end up being 
> a tracing GC algorithm in disguise.

No, then you end up with C++ unique_ptr...

More information about the Digitalmars-d mailing list