[PATCH] MIR Serialization: Initial serialization of stack objects.

Duncan P. N. Exon Smith dexonsmith at apple.com
Fri Jul 10 10:18:38 PDT 2015


> On 2015-Jul-09, at 15:15, Alex L <arphaman at gmail.com> wrote:
> 
> Hello,
> 
> This patch implements the initial serialization of stack objects from the MachineFrameInfo class. It can only serialize the ordinary stack objects (including ordinary spill slots), but it doesn't serialize variable sized or fixed stack objects yet.
> 
> The stack objects are serialized using a YAML sequence of YAML inline mappings. Each mapping ha s the object's ID, type, size, offset and alignment. Example:
> 
>   stack:
>     - { id: 0, offset: -12, size: 4, alignment: 4 }
>     - { id: 1, offset: -24, size: 8, alignment: 8 }
>     - { id: 2, type: spill-slot, offset: -32, size: 4, alignment: 4 }
> 
> The stack objects are a part of machine function's YAML mapping.
> 
> The follow up patches will serialize the variable sized and fixed stack objects. The variable sized stack objects will use a different type to distinguish them from ordinary stack objects, but the fixed stack objects will use a different YAML sequence of fixed stack objects, Example:
> 
> fixedStack:
>   - { id: 0, offset: 0, size: 4, alignment: 4, isImmutable: true, isAliased: false }
> stack:
>   - { id: 0, offset: -8, size: 4, alignment: 4 }
> 
> The machine operands will reference the stack objects using the following syntax:
>   
>     %<id>[.<name>]
> 
> Thanks,
> Alex
> <0001-MIR-Serialization-Initial-serialization-of-stack-obj.patch>

LGTM!





More information about the llvm-commits mailing list