Enum Class Opnd.MpIntToMpInt

java.lang.Object
java.lang.Enum<Opnd.MpIntToMpInt>
ghidra.pcode.emu.jit.gen.opnd.Opnd.MpIntToMpInt
All Implemented Interfaces:
Opnd.MpToMpConv<Types.TInt,JitType.IntJitType,JitType.MpIntJitType,Types.TInt,JitType.IntJitType,JitType.MpIntJitType>, Serializable, Comparable<Opnd.MpIntToMpInt>, Constable
Enclosing interface:
Opnd<T extends JitType>

Converter from mp-int to mp-int
  • Enum Constant Details

  • Method Details

    • values

      public static Opnd.MpIntToMpInt[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Opnd.MpIntToMpInt valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • convertOpndToOpnd

      public <N extends Emitter.Next> Opnd.OpndEm<JitType.MpIntJitType,N> convertOpndToOpnd(Emitter<N> em, Opnd<JitType.MpIntJitType> from, JitType.MpIntJitType to, Opnd.Ext ext, Scope scope)
      Description copied from interface: Opnd.MpToMpConv
      Convert an operand in locals to another in locals

      NOTE: This may be accomplished in part be re-using legs from the source operand in the destination operand

      Specified by:
      convertOpndToOpnd in interface Opnd.MpToMpConv<Types.TInt,JitType.IntJitType,JitType.MpIntJitType,Types.TInt,JitType.IntJitType,JitType.MpIntJitType>
      Type Parameters:
      N - the tail of the stack (...)
      Parameters:
      em - the emitter
      from - the source operand
      to - the destination p-code type
      ext - the kind of extension to apply
      scope - a scope for generated temporary variables
      Returns:
      the resulting operand and emitter with ...
    • doGenArrExt

      public static <N extends Emitter.Next> Emitter<N> doGenArrExt(Emitter<N> em, Local<Types.TRef<int[]>> arr, int legsOut, int defLegs, Opnd.Ext ext, Scope scope)
      Emit code that extends a value to fill the rest of an array

      For sign extension, this will assume the last filled element of the array so far is the leg having the sign bit. It shifts and extends that bit to fill a new temporary leg and uses it to fill the remaining more-significant legs. NOTE: legsOut may be less than the actual size of the array, since slack elements may have been allocated.

      Type Parameters:
      N - the tail of the stack (...)
      Parameters:
      em - the emitter
      arr - a handle to the local containing the array
      legsOut - the number of output legs
      defLegs - the number of legs already filled
      ext - the kind of extension to apply
      scope - a scope for generated temporary variables
      Returns:
      the emitter with ...
    • convertOpndToArray

      public <N extends Emitter.Next> Emitter<Emitter.Ent<N,Types.TRef<int[]>>> convertOpndToArray(Emitter<N> em, Opnd<JitType.MpIntJitType> from, JitType.MpIntJitType to, Opnd.Ext ext, Scope scope, int slack)
      Description copied from interface: Opnd.MpToMpConv
      Convert an operand in locals to an array
      Specified by:
      convertOpndToArray in interface Opnd.MpToMpConv<Types.TInt,JitType.IntJitType,JitType.MpIntJitType,Types.TInt,JitType.IntJitType,JitType.MpIntJitType>
      Type Parameters:
      N - the tail of the stack (...)
      Parameters:
      em - the emitter
      from - the source operand
      to - the destination p-code type
      ext - the kind of extension to apply
      scope - a scope for generated temporary variables
      slack - the number of extra (more significant) elements to allocate in the array
      Returns:
      the emitter with ..., arrayref