Skip to content

Comment on YJIT: Building a New JIT Compiler for CRubyparent

Comments

MRI has more primitives of sort, but they're an implementation detail. Ruby itself conceptually only have objects.

MRI however implements some of them (integers, floats, symbols, true, false, nil, I might have forgotten one or two) using type tagged values instead of pointers to objects.

Type-tagging is easier to make fast for a highly gc'd dynamic language, as it reduces gc pressure substantially to not have to allocate lots of small objects without massive amounts of complex optimisations.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.