xclbinutil Utility
The xclbinutil
utility can create, modify,
and report xclbin
content information.
The available command options are shown in the following table.
Option | Description |
---|---|
-h [ --help
] |
Print help messages. |
-i [ --input
]<arg> |
Input file name. Reads xclbin into memory. |
-o [ --output
]<arg> |
Output file name. Writes in memory xclbin image to a file. |
-v [ --verbose
] |
Display verbose/debug information |
-q [ --quiet
] |
Minimize reporting information. |
--migrate-forward |
Migrate the xclbin archive forward to the new binary format. |
--remove-section<arg> |
Section name to remove. |
--add-section<arg> |
Section name to add. Format: <section>:<format>:<file> |
--dump-section<arg> |
Section to dump. Format: <section>:<format>:<file> |
--replace-section<arg> |
Section to replace. |
--key-value<arg> |
Key value pairs. Format: [USER|SYS]:<key>:<value> |
--remove-key<arg> |
Removes the given user key from the xclbin archive. |
--add-signature<arg> |
Adds a user defined signature to the given xclbin image. |
--remove-signature |
Removes the signature from the xclbin image. |
--get-signature |
Returns the user defined signature (if set) of the xclbin image. |
--info |
Report accelerator binary content. Including: generation and packaging data, kernel signatures, connectivity, clocks, sections, etc |
--list-names |
List all possible section names (standalone option). |
--version |
Version of this executable. |
--force |
Forces a file overwrite. |
The following are various use examples of the tool.
- Reporting xclbin information
xclbinutil --info --input binary_container_1.xclbin
- Extracting the bitstream image
xclbinutil --dump-section BITSTREAM:RAW:bitstream.bit --input binary_container_1.xclbin
- Extracting the build metadata
xclbinutil --dump-section BUILD_METADATA:HTML:buildMetadata.json --input binary_container_1.xclbin
- Removing a section
xclbinutil --remove-section BITSTREAM --input binary_container_1.xclbin --output binary_container_modified.xclbin
For most users, details about the contents and how the xclbin
was created is desired. This information can be obtained through
the --info
option and reports information on the
xclbin
, hardware platform, clocks, memory
configuration, kernel, and how the xclbin
was
generated.
The output of the xclbinutil
command
using the --info
option is shown below divided into
sections.
xclbinutil -i binary_container_1.xclbin --info
xclbin Information
Generated by: v++ (2020.1) on Mon Apr 13 20:19:40 MDT 2020
Version: 2.6.436
Kernels: CopyKernel
Signature:
Content: Bitstream
UUID (xclbin): d081de98-3fd3-4e9b-bab3-108b42c73101
UUID (IINTF): 862c7020a250293e32036f19956669e5
Sections: DEBUG_IP_LAYOUT, BITSTREAM, MEM_TOPOLOGY, IP_LAYOUT,
CONNECTIVITY, CLOCK_FREQ_TOPOLOGY, BUILD_METADATA,
EMBEDDED_METADATA, SYSTEM_METADATA, PARTITION_METADATA
Hardware Platform Information
Vendor: xilinx
Board: u200
Name: xdma
Version: 201830.1
Generated Version: Vivado 2018.3 (SW Build: 2388429)
Created: Wed Nov 14 20:06:10 2018
FPGA Device: xcu200
Board Vendor: xilinx.com
Board Name: xilinx.com:au200:1.0
Board Part: xilinx.com:au200:part0:1.0
Platform VBNV: xilinx_u200_xdma_201830_1
Static UUID: 00194bb3-707b-49c4-911e-a66899000b6b
Feature ROM TimeStamp: 1542252769
Clocks
Reports the maximum kernel clock frequencies available. Both the clock names and clock indexes are provided. The clock indexes are identical to those reported in platforminfo Utility.
Name: DATA_CLK
Index: 0
Type: DATA
Frequency: 300 MHz
Name: KERNEL_CLK
Index: 1
Type: KERNEL
Frequency: 500 MHz
Memory Configuration
Name: bank0
Index: 0
Type: MEM_DDR4
Base Address: 0x0
Address Size: 0x400000000
Bank Used: No
Name: bank1
Index: 1
Type: MEM_DDR4
Base Address: 0x400000000
Address Size: 0x400000000
Bank Used: Yes
Name: bank2
Index: 2
Type: MEM_DDR4
Base Address: 0x800000000
Address Size: 0x400000000
Bank Used: No
Name: bank3
Index: 3
Type: MEM_DDR4
Base Address: 0xc00000000
Address Size: 0x400000000
Bank Used: No
Name: PLRAM[0]
Index: 4
Type: MEM_DDR4
Base Address: 0x1000000000
Address Size: 0x20000
Bank Used: No
Name: PLRAM[1]
Index: 5
Type: MEM_DRAM
Base Address: 0x1000020000
Address Size: 0x20000
Bank Used: No
Name: PLRAM[2]
Index: 6
Type: MEM_DRAM
Base Address: 0x1000040000
Address Size: 0x20000
Bank Used: No
Kernel Information
For each kernel in the xclbin
, the function
definition, ports, and instance information is reported.
The following is an example of the reported function definition.
Definition
----------
Signature: krnl_vadd (int* a, int* b, int* c,
int const n_elements)
The following is an example of the reported ports.
Ports
-----
Port: M_AXI_GMEM
Mode: master
Range (bytes): 0xFFFFFFFF
Data Width: 32 bits
Port Type: addressable
Port: M_AXI_GMEM1
Mode: master
Range (bytes): 0xFFFFFFFF
Data Width: 32 bits
Port Type: addressable
Port: S_AXI_CONTROL
Mode: slave
Range (bytes): 0x1000
Data Width: 32 bits
Port Type: addressable
The following is an example of the reported instance(s) of the kernel.
Instance: krnl_vadd_1
Base Address: 0x0
Argument: a
Register Offset: 0x10
Port: M_AXI_GMEM
Memory: bank1 (MEM_DDR4)
Argument: b
Register Offset: 0x1C
Port: M_AXI_GMEM
Memory: bank1 (MEM_DDR4)
Argument: c
Register Offset: 0x28
Port: M_AXI_GMEM1
Memory: bank1 (MEM_DDR4)
Argument: n_elements
Register Offset: 0x34
Port: S_AXI_CONTROL
Memory: <not applicable>
Tool Generation Information
The utility also reports the v++
command
line used to generate the xclbin
. The Command Line section
gives the actual v++
command line used, while the Options
section displays each option used in the command line, but in a more readable format with
one option per line.
Generated By
------------
Command: v++
Version: 2018.3 - Tue Nov 20 19:42:42 MST 2018 (SW BUILD: 2394611)
Command Line: v++ -t hw_emu --platform /opt/xilinx/platforms/xilinx_u200_xdma_201830_1/xilinx_
u200_xdma_201830_1.xpfm --save-temps -l --connectivity.nk krnl_vadd:1
-g --messageDb binary_container_1.mdb
--temp_dir binary_container_1
--report_dir binary_container_1/reports --log_dir binary_container_1/logs
--remote_ip_cache /wrk/tutorials/ip_cache
-obinary_container_1.xclbin binary_container_1/krnl_vadd.o
Options: -t hw_emu
--platform /opt/xilinx/platforms/xilinx_u200_xdma_201830_1/xilinx_u200_xdma_201830_1.xpfm
--save-temps
-l
--connectivity.nk krnl_vadd:1
-g
--messageDb binary_container_1.mdb
--temp_dir binary_container_1
--report_dir binary_container_1/reports
--log_dir binary_container_1/logs
--remote_ip_cache /wrk/tutorials/ip_cache
-obinary_container_1.xclbin binary_container_1/krnl_vadd.o
==============================================================================
User Added Key Value Pairs
--------------------------
<empty>
==============================================================================