gc
Languages and libraries
garbage collector library
SHOW HN2019
192points
60comments
#201of 2,195 in 2019
Top 10%of 2019 by points
How HN took it
CuriousMostly questions and neutral comments
0 positive, 8 neutral or asking, 0 mixed, 0 critical, out of 8 comments about the project. Thread score 0.00.
The thread, comment by comment
Each row is a top-level comment and its replies, in HN's order. Select a cell to open that comment on HN.
positive neutral or mixed critical about another commenter or something else the maker
What HN said
What people liked
Good for learning and a clean implementation of mark-and-sweep.
From 2 comments
Second paragraph in README: > The focus of gc is to provide a conceptually clean implementation of a mark-and-sweep GC, without delving into the depths of architecture-specific…
hu3 on HNCool! Thanks for this - and the link to orangeduck’s work (which further points to Cello.)
kickscondor on HN
Objections
Conservative stack scanning can keep memory alive by coincidence and is slow.
From 2 comments
How about efficiency? Looks like the collector has to scan through all allocated memory and the whole stack to check whether there could be a pointer. And if any data looks like…
Rochus on HNTypically, new garbage collected languages use the Boehm garbage collector (GC for C) in early versions, and then implement their own once they have time to fully optimize their…
gwbas1c on HN
Adding or writing a GC for C is strange or pointless to some.
From 2 comments
Writing a GC for C is pretty strange.
jeen02 on HNI have to second GP, writing a GC for C is strange. Not because it is written in C, but for C. State of the art efficient and low latency GC pose requirements on the memory…
funcDropShadow on HN
Requests
Support for compiling TypeScript or AssemblyScript to WASM.
From 1 comment
Can it help with compiling Typescript to WASM? i.e. in https://github.com/AssemblyScript/assemblyscript
touchpadder on HN
Questions
What is the use case for a garbage collector in C?
From 1 comment
Just out of interest for people not familiar with C, latest goings on there etc, what's the usecase where you'd want a garbage collector in C? My (very surface level)…
davnicwil on HN
How does it differ from the Boehm GC?
From 1 comment
How about efficiency? Looks like the collector has to scan through all allocated memory and the whole stack to check whether there could be a pointer. And if any data looks like…
Rochus on HN
Alternatives named
Boehm GC
From 2 comments
Typically, new garbage collected languages use the Boehm garbage collector (GC for C) in early versions, and then implement their own once they have time to fully optimize their…
gwbas1c on HNThe Boehm GC seems to do both internally.
shakna on HN
Cello
From 1 comment
Cool! Thanks for this - and the link to orangeduck’s work (which further points to Cello.)
kickscondor on HN
PureRC in AssemblyScript
From 1 comment
AssemblyScript already has tiny hybrid garbage collector (PureRC) which use deferred ARC and GC only for cyclic references:…
maxgraey on HN