Record Class JitType.MpFloatJitType

java.lang.Object
java.lang.Record
ghidra.pcode.emu.jit.analysis.JitType.MpFloatJitType
Record Components:
size - the size in bytes
All Implemented Interfaces:
JitType
Enclosing interface:
JitType

public static record JitType.MpFloatJitType(int size) extends Record implements JitType
WIP: The p-code types for floats of size other than 4 and 8
  • Constructor Details

    • MpFloatJitType

      public MpFloatJitType(int size)
      Creates an instance of a MpFloatJitType record class.
      Parameters:
      size - the value for the size record component
  • Method Details

    • forSize

      public static JitType.MpFloatJitType forSize(int size)
      Get the type for a float of the given size other than 4 and 8
      Parameters:
      size - the size in bytes
      Returns:
      the type
      Throws:
      IllegalArgumentException - for size 4 or 8
    • pref

      public int pref()
      Description copied from interface: JitType
      The preference for this type. Smaller is more preferred.
      Specified by:
      pref in interface JitType
      Returns:
      the preference
    • nm

      public String nm()
      Description copied from interface: JitType
      Part of the name of a JVM local variable allocated for this type
      Specified by:
      nm in interface JitType
      Returns:
      the "type" part of a JVM local's name
    • ext

      public JitType.MpFloatJitType ext()
      Description copied from interface: JitType
      Extend this p-code type to the p-code type that fills its entire host JVM type.

      This is useful, e.g., when multiplying two int3 values using imul that the result might be an int4 and so may need additional conversion.

      Specified by:
      ext in interface JitType
      Returns:
      the extended type
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared with '=='.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • size

      public int size()
      Returns the value of the size record component.
      Specified by:
      size in interface JitType
      Returns:
      the value of the size record component