docs: Update IREE compiling options Change-Id: I0b8960007d337b026eff29dc3a815fb0b57234ca
diff --git a/GenerateAndInspectIreeExecutables.md b/GenerateAndInspectIreeExecutables.md index 0709c1b..066e7c8 100644 --- a/GenerateAndInspectIreeExecutables.md +++ b/GenerateAndInspectIreeExecutables.md
@@ -14,15 +14,15 @@ example, to generate the IREE bytecode module from a vector multiply MLIR: ```bash -${OUT}/host/iree-compiler/install/bin/iree-translate \ +${OUT}/host/iree_compiler/install/bin/iree-translate \ -iree-input-type=mhlo \ -iree-mlir-to-vm-bytecode-module \ -iree-hal-target-backends=dylib-llvm-aot \ -iree-llvm-target-triple=riscv32-pc-linux-elf \ -iree-llvm-target-cpu=generic-rv32 \ -iree-llvm-target-cpu-features="+m,+f" \ - -iree-llvm-target-abi=lp32d \ - -iree-llvm-link-embedded=true \ + -iree-llvm-target-abi=ilp32 \ + -iree-llvm-embedded-linker-path=${OUT}/host/iree_compiler/install/bin/lld \ ${ROOTDIR}/toolchain/iree/iree/samples/simple_embedding/simple_embedding_test.mlir \ -o /tmp/simple_mul-llvm_aot.vmfb @@ -44,12 +44,8 @@ support. __For the vector extension, it can be enabled with "+experimental-v"__. * iree-llvm-target-abi: The flag is polulated to LLVM target abi. -* iree-llvm-link-embedded: Generate the executable into a platform-agnostic ELF -and use the ELF loader to load the library instead of using `dlopen` and `dlsym`. -This creates the least overhead in the executable, and the simplest -linker during codegen without dynamic library linkage; therefore, it will be the -targeted path for Shodan. However, it is WIP and currently is not set as the -default path. +* iree-llvm-embedded-linker-path: Linker for the device executable. It is + recommanded to use the lld from the IREE compiler release. Some extra options: @@ -57,6 +53,13 @@ (with [schema](https://github.com/google/iree/blob/main/iree/schemas/bytecode_module_def.fbs)), the intermediate linker is generated at `/tmp/<module_name>_linked_<hal_target>-xxxxxx.so`. (the exact path is printed in the stdout). +* iree-vm-emit-polyglot-zip: Instead of the previous flag, by enabling this flag +you can extract the .so from the .vmfb file with 7z + +```bash +7z e -aoa -bb0 <vmfb> -y +``` + * riscv-v-vector-bits-min and riscv-v-fixed-length-vector-lmul-max: If the vector extension is enabled in `iree-llvm-target-cpu-features`, the RVV VLS (vector length specific) code will be generated with the vector length specified @@ -99,8 +102,7 @@ -iree-hal-target-backends=dylib-llvm-aot \ -iree-llvm-target-triple=riscv32-pc-linux-elf \ -iree-llvm-target-cpu=generic-rv32 \ - -iree-llvm-target-cpu-features="+m,+a,+f" \ - -iree-llvm-target-abi=lp32d \ - -iree-llvm-link-embedded=true \ + -iree-llvm-target-cpu-features="+m,+f" \ + -iree-llvm-target-abi=ilp32 \ <MLIR input> ```