summaryrefslogtreecommitdiff
path: root/llvm/docs/CommandGuide/llvm-ir2vec.rst
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/docs/CommandGuide/llvm-ir2vec.rst')
-rw-r--r--llvm/docs/CommandGuide/llvm-ir2vec.rst16
1 files changed, 14 insertions, 2 deletions
diff --git a/llvm/docs/CommandGuide/llvm-ir2vec.rst b/llvm/docs/CommandGuide/llvm-ir2vec.rst
index 0c9fb6e94b6f..fc590a618031 100644
--- a/llvm/docs/CommandGuide/llvm-ir2vec.rst
+++ b/llvm/docs/CommandGuide/llvm-ir2vec.rst
@@ -13,7 +13,9 @@ DESCRIPTION
:program:`llvm-ir2vec` is a standalone command-line tool for IR2Vec. It
generates IR2Vec embeddings for LLVM IR and supports triplet generation
-for vocabulary training. The tool provides three main subcommands:
+for vocabulary training.
+
+The tool provides three main subcommands:
1. **triplets**: Generates numeric triplets in train2id format for vocabulary
training from LLVM IR.
@@ -93,7 +95,7 @@ Example Usage:
.. code-block:: bash
- llvm-ir2vec embeddings --ir2vec-vocab-path=vocab.json --level=func input.bc -o embeddings.txt
+ llvm-ir2vec embeddings --ir2vec-vocab-path=vocab.json --ir2vec-kind=symbolic --level=func input.bc -o embeddings.txt
OPTIONS
-------
@@ -129,6 +131,16 @@ Subcommand-specific options:
Process only the specified function instead of all functions in the module.
+.. option:: --ir2vec-kind=<kind>
+
+ Specify the kind of IR2Vec embeddings to generate. Valid values are:
+
+ * ``symbolic`` - Generate symbolic embeddings (default)
+ * ``flow-aware`` - Generate flow-aware embeddings
+
+ Flow-aware embeddings consider control flow relationships between instructions,
+ while symbolic embeddings focus on the symbolic representation of instructions.
+
.. option:: --ir2vec-vocab-path=<path>
Specify the path to the vocabulary file (required for embedding generation).