3.5.1.18.5 AXI4 Target Interface vs Legacy AXI4 Slave Interface

The AXI4 target interface and the legacy AXI4 slave interface are similar features --- implement memories (in the form of RAMs or registers) behind the interfaces, and allow an AXI4 initiator (or called AXI4 master/manager) to access the memories in a memory-mapped manner. There are however some differences in their limitations and where the interface pragmas can be applied,

  • The axi_target interface pragma can be applied to module control, scalar arguments, and pointer arguments but cannot be applied to global variables. The legacy axi_slave interface pragma can only be applied to at most one global struct variable (all memories that need to be made accessible through the legacy AXI4 slave interface must be "wrapped" in the same struct variable).
  • Both interfaces support incremental burst transfer (fixed burst and wrapping burst are not supported). For the AXI4 target interface, a burst transaction cannot access more than one argument. For the legacy AXI4 slave interface, a burst transaction can cover any continuous addresses within the address range of the interface.
  • The AXI4 target interface is only accessible when the HLS module is not running. The legacy AXI4 slave interface's concurrent_access option can allow the external logic to read/write the AXI4 slave interface while the SmartHLS module is running.
  • Byte-enable writes (via the WSTRB port) are supported by both interfaces, however the legacy AXI4 slave interface requires the write strobe to be aligned to the struct elements (see 3.5.1.18.3.4 Legacy AXI4 Slave Interface for more details).
  • The legacy AXI4 slave interface ignores the AxSIZE signal and always assumes an AxSIZE value of 3 (8 bytes per transfer). The AXI4 target interface supports any AxSIZE that is not bigger than 3 (because the data bus width is 64-bit, or 8-bytes wide).
  • When the AXI4 target interface is used, are generated to allow convenient accesses from an attached processor. There is no driver functions for the legacy AXI4 slave interface.