Skip to content

Comment on Everyone says assembly is untyped—everyone is wrong

Comments

Would there be any benefit from implementing types at the CPU level? Has it been tried?

Like say adding an 8-bit type flag to each instruction, and keeping a table of which memory ranges have which type, then only allowing compatible instructions on that memory?

Yes it's been done a bunch of times in the past, see https://en.wikipedia.org/wiki/Tagged_architecture. Probably most notably lisp machines which the sibling comment mentioned.

Lisp machines come to mind, like the Symbolics 3600.

AboutSource Built by g1lg1l

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