AARCHMRS Schema 2.7.4

↚ Home

Mapping.MapArray object

Provides mapping between Registers, RegisterBlocks, and Field types and individual bits within Registers like Map, except it is expandable based on an index.

When expanded, the values defined in the indexes property are used to generate multiple Map objects, one for each index.

object

Properties Type Description
_meta Meta

Metadata

See Meta for more information.
_type
Enum
Mapping.MapArray
condition Traits.HasCondition

This condition must be true for the mapping to exist.

See definitions.condition in Traits.HasCondition for more information.
index_variable Traits.HasIndexes
See definitions.index_variable in Traits.HasIndexes for more information.
indexes Traits.HasIndexes
See definitions.indexes in Traits.HasIndexes for more information.
maps Map
See definitions.maps in Map for more information.
Additional Properties
Not Allowed
◊ Required
Properties marked with ◊ are required properties.
Examples
{
    "_type": "Mapping.MapArray", 
    "condition": {
        "_type": "AST.Function", 
        "arguments": [
            {
                "_type": "AST.Identifier", 
                "value": "EL1"
            }
        ], 
        "name": "IsFeatureImplemented"
    }, 
    "indexes": [
        {
            "_type": "Range", 
            "start": 4, 
            "width": 1
        }
    ], 
    "index_variable": "x", 
    "maps": [
        {
            "_type": "AST.SquareOp", 
            "arguments": [
                {
                    "_type": "AST.Slice", 
                    "left": {
                        "_type": "AST.Integer", 
                        "value": 31
                    }, 
                    "right": {
                        "_type": "AST.Integer", 
                        "value": 0
                    }
                }
            ], 
            "var": {
                "_type": "Types.RegisterType", 
                "value": {
                    "instance": null, 
                    "name": "REG<x>", 
                    "slices": null, 
                    "state": "AArch64"
                }
            }
        }, 
        {
            "_type": "AST.SquareOp", 
            "arguments": [
                {
                    "_type": "AST.Slice", 
                    "left": {
                        "_type": "AST.Integer", 
                        "value": 31
                    }, 
                    "right": {
                        "_type": "AST.Integer", 
                        "value": 0
                    }
                }
            ], 
            "var": {
                "_type": "AST.Identifier", 
                "value": "REG<x>"
            }
        }
    ]
}

Schema http://json-schema.org/draft-04/schema#

{
  "title": "MapArray",
  "additionalProperties": false,
  "properties": {
    "_meta": {
      "$ref": "../Meta.json",
      "info": [
        "Metadata"
      ]
    },
    "_type": {
      "enum": [
        "Mapping.MapArray"
      ]
    },
    "maps": {
      "$ref": "Map.json#/definitions/maps"
    },
    "condition": {
      "$ref": "../Traits/HasCondition.json#/definitions/condition",
      "info": [
        "This condition must be true for the mapping to exist."
      ]
    },
    "indexes": {
      "$ref": "../Traits/HasIndexes.json#/definitions/indexes"
    },
    "index_variable": {
      "$ref": "../Traits/HasIndexes.json#/definitions/index_variable"
    }
  },
  "examples": [
    {
      "_type": "Mapping.MapArray",
      "condition": {
        "_type": "AST.Function",
        "arguments": [
          {
            "_type": "AST.Identifier",
            "value": "EL1"
          }
        ],
        "name": "IsFeatureImplemented"
      },
      "indexes": [
        {
          "_type": "Range",
          "start": 4,
          "width": 1
        }
      ],
      "index_variable": "x",
      "maps": [
        {
          "_type": "AST.SquareOp",
          "arguments": [
            {
              "_type": "AST.Slice",
              "left": {
                "_type": "AST.Integer",
                "value": 31
              },
              "right": {
                "_type": "AST.Integer",
                "value": 0
              }
            }
          ],
          "var": {
            "_type": "Types.RegisterType",
            "value": {
              "instance": null,
              "name": "REG",
              "slices": null,
              "state": "AArch64"
            }
          }
        },
        {
          "_type": "AST.SquareOp",
          "arguments": [
            {
              "_type": "AST.Slice",
              "left": {
                "_type": "AST.Integer",
                "value": 31
              },
              "right": {
                "_type": "AST.Integer",
                "value": 0
              }
            }
          ],
          "var": {
            "_type": "AST.Identifier",
            "value": "REG"
          }
        }
      ]
    }
  ],
  "required": [
    "maps",
    "indexes",
    "index_variable"
  ],
  "type": "object",
  "$schema": "http://json-schema.org/draft-04/schema#",
  "info": [
    "Provides mapping between Registers, RegisterBlocks, and Field types and individual bits within Registers like Map, except it is expandable based on an index.",
    "When expanded, the values defined in the `indexes` property are used to generate multiple Map objects, one for each index."
  ]
}