decompiler  1.0.0
Public Member Functions | Private Attributes | List of all members
ghidra::ResolveEdge Class Reference

A data-flow edge to which a resolved data-type can be assigned. More...

#include <unionresolve.hh>

Public Member Functions

 ResolveEdge (const Datatype *parent, const PcodeOp *op, int4 slot)
 Construct from components. More...
 
bool operator< (const ResolveEdge &op2) const
 Compare two edges. More...
 

Private Attributes

uint8 typeId
 Id of base data-type being resolved.
 
uintm opTime
 Id of PcodeOp edge.
 
int4 encoding
 Encoding of the slot and pointer-ness.
 

Detailed Description

A data-flow edge to which a resolved data-type can be assigned.

The edge is associated with the specific data-type that needs to be resolved, which is typically a union or a pointer to a union. The edge collapses different kinds of pointers to the same base union.

Constructor & Destructor Documentation

◆ ResolveEdge()

ghidra::ResolveEdge::ResolveEdge ( const Datatype parent,
const PcodeOp op,
int4  slot 
)

Construct from components.

Parameters
parentis a parent data-type that needs to be resolved
opis the PcodeOp reading/writing the parent data-type
slotis the slot (>=0 for input, -1 for output) accessing the parent

References ghidra::Datatype::getId(), ghidra::Datatype::getMetatype(), ghidra::PcodeOp::getTime(), ghidra::ScoreUnionFields::maxPasses, ghidra::ScoreUnionFields::maxTrials, ghidra::ScoreUnionFields::threshold, ghidra::TYPE_PARTIALUNION, and ghidra::TYPE_PTR.

Member Function Documentation

◆ operator<()

bool ghidra::ResolveEdge::operator< ( const ResolveEdge op2) const
inline

Compare two edges.

Compare based on the data-type, the slot, and the PcodeOp's unique id.

Parameters
op2is the other edge to compare with this
Returns
true if this should be ordered before the other edge

References encoding, opTime, and typeId.


The documentation for this class was generated from the following files: