Shared Buffers Constraint - 2024.2 English - UG1603

AI Engine-ML Kernel and Graph Programming Guide (UG1603)

Document ID
UG1603
Release Date
2024-11-28
Version
2024.2 English

This constrains a shared buffer to a specific address on a specific memory tile. The address can be specified in one of three different ways:

  • Column, row, and offset, where the tile is specified by column and row and the offset address is relative to the tile, starting at zero with a maximum value of 524288 (512k).
  • Column, row, and bankId, where the bank ID is relative to the memory tile and can take a value between 0 and 15.
  • Offset, that can be between zero and 524288 (512k) and is relative to the memory tile allocated by the compiler.
  • Number of columns (same as number of columns of the AI Engine-ML array) and rows (1 or 2) is different from device to device.
Note: One, or more shared buffers can be constrained for a port.

Syntax

"memTileBufferInfo": [<address>, <(optional) address>]
<address> ::= <offset_address> | <bank_address> | <offset_address>
<tile_address> ::= {
  "column": integer,
  "row": integer,
  "offset": integer
}
<bank_address> ::= {
  "column": integer,
  "row": integer,
  "bankId": integer
}
<offset_address> ::= {
  "offset": integer
}

Example:

{
  "PortConstraints": {
  "GMatMult.MMult.mtxA_ns.out[0]": {
    "buffers": [{
      "column": 6,
       "row": 0,
      "bankId": 2,
      "offset": 0
    }, {
      "column": 6,
      "row": 0,
      "bankId": 3,
      "offset": 0
    }]
  },
  "GMatMult.MMult.mtxC_ns.in[0]": {
    "buffers": [{
      "column": 7,
      "row": 1,
      "bankId": 1,
      "offset": 0
    }, {
      "column": 7,
      "row": 1,
      "bankId": 0,
      "offset": 0
    }]
  }
  }
}