Skip to content

Comment on Emacs internals: Tagged pointers vs. C++ std:variant and LLVM (Part 3)

Comments

Drawn in by the Emacs, learnt something new about C and C++, thank you for this! Very readable article for someone who doesn't feel too confident with low-level bits.

Btw, is this representation the reason why OCaml's ints are not as big as C ints?

Also interesting that the Haskell pointer tagging you link to[0] was done the way it was to avoid CPU branch misprediction, and that the old way which it replaced was "the source of half of the branch misprediction events". I wonder how "branch prediction friendly" current Haskell is.

[0] https://simonmar.github.io/bib/papers/ptr-tagging.pdf

AboutSource Built by g1lg1l

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