ROSE 0.11.145.192
|
Base class for matching function padding.
Function padding is bytes that appear immediately prior to the entry address of a function usually in order to align the function on a suitable boundary. Some assemblers emit zero bytes, others emit no-op instructions, and still others emit combinations of no-ops and zeros. It's conceivable that some compiler might even emit random garbage.
#include <Rose/BinaryAnalysis/Partitioner2/Modules.h>
Public Types | |
using | Ptr = FunctionPaddingMatcherPtr |
Shared-ownership pointer to a FunctionPaddingMatcher. | |
Public Member Functions | |
virtual rose_addr_t | match (const PartitionerConstPtr &, rose_addr_t anchor)=0 |
Attempt to match padding. | |
Public Member Functions inherited from Sawyer::SharedObject | |
SharedObject () | |
Default constructor. | |
SharedObject (const SharedObject &) | |
Copy constructor. | |
virtual | ~SharedObject () |
Virtual destructor. | |
SharedObject & | operator= (const SharedObject &) |
Assignment. | |
Shared-ownership pointer to a FunctionPaddingMatcher.
See Shared ownership.
|
pure virtual |
Attempt to match padding.
Attempts to match function padding that ends at the address immediately prior to anchor
. If a match is successful then the return value is the starting address for the padding and must be less than anchor
. When no match is found then anchor
is returned. The size of the matched padding is always anchor-retval
where retval
is the returned value.
Implemented in Rose::BinaryAnalysis::Partitioner2::ModulesM68k::MatchFunctionPadding.