libfringe
libfringe copied to clipboard
automated verification of clobbers
I'd like to have some form of automated verification that we're not unintentionally modifying processor state that we're not declaring as clobbered. Preferably, we would automatically generate a list of processor state from a third-party source (such as Capstone) and use this to generate our clobber lists.
Additionally, we could pattern-match the stack-swap code in real programs, and use this to statically check for state being carried across contexts.
A good start would be to look at the list of clobbers supported by clang for each architecture: https://github.com/llvm-mirror/clang/blob/master/lib/Basic/Targets.cpp (search for GCCRegNames)