Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 9 additions & 5 deletions docs/driver/compile.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,20 +28,24 @@ Disable fast math optimization

.. option:: --exhaustive-tune

Perform an exhaustive search to find the fastest version of generated kernels for selected backend
Exhaustively search for best tuning parameters for kernels

.. option:: --fp16

Quantize for fp16
Quantize for FP16

.. option:: --bf16

Quantize for bf16
Quantize for BF16

.. option:: --int8

Quantize for int8
Quantize for INT8

.. option:: --fp8

Quantize for Float8E4M3FNUZ type
Quantize for FP8

.. option:: --int4-weights

Quantize weights for INT4
20 changes: 18 additions & 2 deletions docs/driver/read.rst
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,18 @@ Treat tensorflow format as nchw

Trim instructions from the end (Default: 0)

.. option:: --trim-size, -s [unsigned int]

Number of instructions in the trim model

.. option:: --input-dim [std::vector<std::string>]

Dim of a parameter (format: "@name d1 d2 dn")

.. option:: --dim-param [std::vector<std::string>]

Symbolic parameter dimension name (fixed / dynamic) - (fixed format): "@dim_param_name" "x" / (dynamic format): "@dim_param_name" "{min:x, max:y, optimals:[o1,o2]}"

.. option:: --dyn-input-dim [std::vector<std::string>]

Set dynamic dimensions of a parameter using JSON formatting (format "@name" "dynamic_dimension_json")
Expand All @@ -54,10 +62,18 @@ Set dynamic dimensions of a parameter using JSON formatting (format "@name" "dyn

Set the default dynamic dimension (format {min:x, max:y, optimals:[o1,o2,...]})

.. option:: --output-names [std::vector<std::string>]

Names of node output (format: "name_1 name_2 name_n")

.. option:: --optimize, -O

Optimize when reading

.. option:: --mlir

Offload everything to MLIR

.. option:: --apply-pass, -p

Passes to apply to model
Expand Down Expand Up @@ -90,9 +106,9 @@ Print out program in text format.

Print out program in binary format.

.. option:: --py
.. option:: --python, --py

Print out program using python API.
Print out the program as python program.

.. option:: --output, -o [std::string]

Expand Down
30 changes: 25 additions & 5 deletions docs/migraphx-driver.rst
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ The table below summarizes the MIGraphX driver commands.
- Runs reference and GPU implementations and checks outputs for consistency
* - perf
- Compiles and runs input graph followed by printing the performance report
* - time
- Compiles and runs input graph and reports total time

Options
----------
Expand Down Expand Up @@ -71,14 +73,22 @@ To learn which options can be used with which commands, see the :ref:`MIGraphX d
- Skips unknown operators when parsing and continues to parse.
* - --trim | -t
- Trims instructions from the end.
* - --trim-size | -s
- Number of instructions in the trim model.
* - --optimize | -O
- Optimizes read
* - --mlir
- Offloads everything to MLIR
* - --apply-pass | -p
- Passes to apply to model
* - --graphviz | -g
- Prints a graphviz representation
* - --brief
- Makes the output brief
* - --cpp
- Prints the program in .cpp format
* - --python | --py
- Prints the program as python program
* - --json
- Prints the program in .json format
* - --text
Expand All @@ -95,10 +105,14 @@ To learn which options can be used with which commands, see the :ref:`MIGraphX d
- Fills parameter with 1s
* - --input-dim
- Sets static dimensions of a parameter
* - --dim-param
- Symbolic parameter dimension name (fixed / dynamic)
* - --dyn-input-dim
- Sets dynamic dimensions of a parameter
* - --default-dyn-dim
- Sets default dynamic dimension
* - --output-names
- Names of node output
* - --gpu
- Compiles on the GPU
* - --cpu
Expand All @@ -110,15 +124,17 @@ To learn which options can be used with which commands, see the :ref:`MIGraphX d
* - --disable-fast-math
- Disables fast math optimization
* - --exhaustive-tune
- Enables exhaustive search to find the fastest kernel
- Exhaustively searches for best tuning parameters for kernels
* - --fp16
- Quantizes for fp16
- Quantizes for FP16
* - --bf16
- Quantizes for bf16
- Quantizes for BF16
* - --int8
- Quantizes for int8
- Quantizes for INT8
* - --fp8
- Quantize for ``Float8E4M3FNUZ`` type
- Quantizes for FP8
* - --int4-weights
- Quantizes weights for INT4
* - --rms-tol
- Sets tolerance for the RMS error (Default: 0.001)
* - --atol
Expand All @@ -129,6 +145,10 @@ To learn which options can be used with which commands, see the :ref:`MIGraphX d
- Verifies each instruction
* - --reduce | -r
- Reduces program and verifies
* - --bisect | -b
- Bisects program and verifies
* - --compiled-model | -c
- Compiled model to use
* - --iterations | -n
- Sets the number of iterations to run for perf report
* - --list | -l
Expand Down
22 changes: 22 additions & 0 deletions docs/reference/driver-options.rst
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,20 @@ Compiles and runs input graph then prints performance report.

Sets number of iterations to run for perf report (Default: 100)

time
----

.. program:: migraphx-driver time

Compiles and runs input graph and reports total time.

.. include:: ../driver/read.rst
.. include:: ../driver/compile.rst

.. option:: --iterations, -n [unsigned int]

Sets number of iterations to run (Default: 100)

verify
------

Expand Down Expand Up @@ -82,6 +96,14 @@ Verifies each instruction

Reduces program and verifies

.. option:: -b, --bisect

Bisects program and verifies

.. option:: -c, --compiled-model [std::string]

Compiled model to use

.. option:: --ref-use-double

Converts floating point values to double for the ref target
Expand Down