This commit adds two method for OpaqueFunctionsPool that use
a pointer to `llvm::Type` (or a class derived from `llvm::Type`) as key.
Both methods are used to initialize the pool with pre-existing functions
inside an `llvm::Module` that match a specific `FunctionTags::Tag`:
- `initializeFromReturnType` uses the return `llvm::Type` of the
function as key in the pool
- `initializeFromNthArgType` takes an additional argument which is an
index N, and uses the return `llvm::Type` of the N-th argument as a
key in the pool
These methods are useful for avoiding unnecessary proliferation of
opaque functions in an `llvm::Module`, re-using the existing ones
instead if they are already present.
FunctionTags goal is to solve the long-standing problem of identifying
what type of function are we dealing with. Is it a lifted function? An
helper?
Now we have a sane way to determine this using Metadata and a proper
API.
FunctionIsolation used to base its work on calls to the marker function
`function_call`, as opposed to information provided by the StackAnalysis
(i.e., `revng.member.type` along with `func.call`).
This also affected EnforceABI, which took care of finishing the work
left over by FunctionIsolation. This was hackish and inelegant.
This commit makes FunctionIsolation work exclusively employing
information from StackAnalysis and purges away code that is no longer
necessary from EnforceABI.