In building interpreters, it is useful to be able to stash extra information in pointers, e.g. using low-order bits that would otherwise be all zero from alignment, or high order bits that would otherwise have fixed values. These tricks are used in some lisp and javascript implementations.jdb wrote: ↑Mon Mar 19, 2018 10:45 pmOk, so "database engines that memory map inordinately huge database files" is one valid reason. Any more?Heater wrote: ↑Mon Mar 19, 2018 9:30 pmIt is not.
There are some odd things that need a 64 bit address space.
I believe MongoDB is one. If your database is bigger than 2GB.
CockroachDB can get by with 32 bits but needs tweaking to do so.
Of course nobody in their right mind is going to be using a Pi for huge databases. Except for experimentation.
The problem with 32 bit pointers is that high-order bits eat too much in to address space, limiting the usable memory size. With 64 bit pointers there is lots of room for this extra information, even if memory is limited to 4GB. Of course it is always possible to allocate extra space in objects to contain the information, but that increases memory traffic.