Show / Hide Table of Contents

    Class LoadPrototype

    A prototype for load instructions that dereference pointers.

    Inheritance
    System.Object
    InstructionPrototype
    LoadPrototype
    Inherited Members
    InstructionPrototype.Members
    InstructionPrototype.Instantiate(IReadOnlyList<ValueTag>)
    InstructionPrototype.IsPrototypeOf(Instruction)
    InstructionPrototype.AssertIsPrototypeOf(Instruction, String)
    InstructionPrototype.AssertIsPrototypeOf(Instruction)
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Flame.Compiler.Instructions
    Assembly: Flame.Compiler.dll
    Syntax
    public sealed class LoadPrototype : InstructionPrototype

    Properties

    | Improve this Doc View Source

    Alignment

    Gets the pointer alignment of pointers loaded by this prototype.

    Declaration
    public Alignment Alignment { get; }
    Property Value
    Type Description
    Alignment

    The pointer alignment of pointers loaded by this prototype.

    | Improve this Doc View Source

    IsVolatile

    Tests if instances of this load prototype are volatile operations. Volatile operations may not be reordered with regard to each other.

    Declaration
    public bool IsVolatile { get; }
    Property Value
    Type Description
    System.Boolean

    true if this is a prototype for volatile loads; otherwise, false.

    | Improve this Doc View Source

    ParameterCount

    Gets the number of arguments this instruction takes when instantiated.

    Declaration
    public override int ParameterCount { get; }
    Property Value
    Type Description
    System.Int32

    The number of arguments this instruction takes.

    Overrides
    InstructionPrototype.ParameterCount
    | Improve this Doc View Source

    ResultType

    Gets the type of value produced instantiations of this prototype.

    Declaration
    public override IType ResultType { get; }
    Property Value
    Type Description
    IType

    A type of value.

    Overrides
    InstructionPrototype.ResultType

    Methods

    | Improve this Doc View Source

    CheckConformance(Instruction, MethodBody)

    Checks if a particular instance of this prototype conforms to the rules for this instruction prototype.

    Declaration
    public override IReadOnlyList<string> CheckConformance(Instruction instance, MethodBody body)
    Parameters
    Type Name Description
    Instruction instance

    An instance of this prototype.

    MethodBody body

    The method body that defines the instruction.

    Returns
    Type Description
    System.Collections.Generic.IReadOnlyList<System.String>

    A list of conformance errors in the instruction.

    Overrides
    InstructionPrototype.CheckConformance(Instruction, MethodBody)
    | Improve this Doc View Source

    Create(IType, Boolean, Alignment)

    Gets or creates a load instruction prototype for a particular element type.

    Declaration
    public static LoadPrototype Create(IType elementType, bool isVolatile = false, Alignment alignment = default(Alignment))
    Parameters
    Type Name Description
    IType elementType

    The type of element to load from a pointer.

    System.Boolean isVolatile

    Tells if instances of the load prototype are volatile operations. Volatile operations may not be reordered with regard to each other.

    Alignment alignment

    The pointer alignment of pointers loaded by the prototype.

    Returns
    Type Description
    LoadPrototype

    A load instruction prototype.

    | Improve this Doc View Source

    GetPointer(Instruction)

    Gets the pointer that is loaded by an instance of this prototype.

    Declaration
    public ValueTag GetPointer(Instruction instance)
    Parameters
    Type Name Description
    Instruction instance

    An instance of this prototype.

    Returns
    Type Description
    ValueTag

    The pointer whose pointee is loaded.

    | Improve this Doc View Source

    Instantiate(ValueTag)

    Creates an instance of this load prototype.

    Declaration
    public Instruction Instantiate(ValueTag pointer)
    Parameters
    Type Name Description
    ValueTag pointer

    A pointer to the value to load.

    Returns
    Type Description
    Instruction

    A load instruction.

    | Improve this Doc View Source

    Map(MemberMapping)

    Applies a member mapping to this instruction prototype.

    Declaration
    public override InstructionPrototype Map(MemberMapping mapping)
    Parameters
    Type Name Description
    MemberMapping mapping

    A member mapping.

    Returns
    Type Description
    InstructionPrototype

    A transformed instruction prototype.

    Overrides
    InstructionPrototype.Map(MemberMapping)
    | Improve this Doc View Source

    WithAlignment(Alignment)

    Gets a variant of this load prototype with a particular alignment.

    Declaration
    public LoadPrototype WithAlignment(Alignment alignment)
    Parameters
    Type Name Description
    Alignment alignment

    The alignment to assign to the load.

    Returns
    Type Description
    LoadPrototype

    A load prototype that copies all properties from this one, except for its alignment, which is set to alignment.

    | Improve this Doc View Source

    WithVolatility(Boolean)

    Gets a variant of this load prototype with a particular volatility.

    Declaration
    public LoadPrototype WithVolatility(bool isVolatile)
    Parameters
    Type Name Description
    System.Boolean isVolatile

    The volatility to assign to the load.

    Returns
    Type Description
    LoadPrototype

    A load prototype that copies all properties from this one, except for its volatility, which is set to isVolatile.

    • Improve this Doc
    • View Source
    Back to top Generated by DocFX