[llvm-dev] Fatpointer Pass already existing?

David Chisnall via llvm-dev llvm-dev at lists.llvm.org
Thu Jun 9 03:12:11 PDT 2016

On 9 Jun 2016, at 10:57, Pierre Gagelin via llvm-dev <llvm-dev at lists.llvm.org> wrote:
> After spending 2 months on LLVM generally speaking and more specifically on security passes (ASan, SAFECode, BoundsChecking) I wanted to know if there were an available implementation of strictly fat-pointer based approach to enforce bounds?
> If not, I wanted to implement one. I think it is interessant to have such a tool available even if there are better designs (SoftBound does have a fat-pointer approach with separated metadata accessible by hash table or shadow space which allows to have compatibility).

I had a student implement one a couple of years ago, though I don’t think his code will work with a recent LLVM.  Note that it’s quite difficult to do in the general case, because (for inline metadata) you must do whole-program analysis to know which allocations need to be bigger, which function signatures need changing to pass the metadata, and so on.  His work included generating ABI-compilant unsafe wrappers for the memory-save modified versions.  

It’s also difficult to get the atomicity guarantees that most code expects (i.e. that any thread will see either the before or after view of a pointer).


More information about the llvm-dev mailing list