Interface InjectPayload

  • All Known Implementing Classes:
    InjectPayloadCallfixup, InjectPayloadCallother, InjectPayloadSleigh

    public interface InjectPayload
    InjectPayload encapsulates a semantic (p-code) override which can be injected into analyses that work with p-code (Decompiler, SymbolicPropagator) The payload typically replaces either a subroutine call or a userop
    • Method Detail

      • getName

        java.lang.String getName()
        Returns:
        formal name for this injection
      • getType

        int getType()
        Returns:
        the type of this injection: CALLFIXUP_TYPE, CALLMECHANISM_TYPE, etc.
      • getSource

        java.lang.String getSource()
        Returns:
        a String describing the source of this payload
      • getParamShift

        int getParamShift()
        Returns:
        number of parameters from the original call which should be truncated
      • inject

        void inject​(InjectContext context,
                    PcodeEmit emit)
        Given a context, send the p-code payload to the emitter
        Parameters:
        context - is the context for injection
        emit - is the object accumulating the final p-code
      • getPcode

        PcodeOp[] getPcode​(Program program,
                           InjectContext con)
        A convenience function wrapping the inject method, to produce the final set of PcodeOp objects in an array
        Parameters:
        program - is the Program for which injection is happening
        con - is the context for injection
        Returns:
        the array of PcodeOps
      • isFallThru

        boolean isFallThru()
        Returns:
        true if the injected p-code falls thru