News for hackers. Stuff that matters.
Re:Virtual Memory Tricks by andrewmu on Tuesday November 07, 2017 @06:55AM (#15642620)
One use is tagged pointers, using the top unused address bits for e.g. type information (https://en.wikipedia.org/wiki/Tagged_pointer)
Re:Virtual Memory Tricks by nemanjaboric on Tuesday November 07, 2017 @09:22AM (#15643547)
We're using this technique to stuff the file descriptor with the accompanying object for the epoll registration, so one can check if the (reusable) object was reused for something else while registered with other file descriptor in the epoll: https://github.com/sociomantic-tsunami/ocean/blob/ee4f78d527...
Re:Virtual Memory Tricks by FRex on Tuesday November 07, 2017 @08:29AM (#15643151)
LuaJIT is where I originally ran into this. It uses both NaN tagging with C doubles and tagged pointers with 64 bit pointers.