Add "--xip" option for wamrc (#2336)

Add shorthand "--xip" option for wamrc, which is equal to
"--enalbe-indirect-mode --disable-llvm-intrinsics"
This commit is contained in:
Huang Qi
2023-07-04 12:03:40 +08:00
committed by GitHub
parent 6ed4c9c908
commit df98d9fb4a
2 changed files with 9 additions and 0 deletions

View File

@ -65,6 +65,7 @@ print_help()
printf(" --enable-dump-call-stack Enable stack trace feature\n");
printf(" --enable-perf-profiling Enable function performance profiling\n");
printf(" --enable-memory-profiling Enable memory usage profiling\n");
printf(" --xip A shorthand of --enalbe-indirect-mode --disable-llvm-intrinsics\n");
printf(" --enable-indirect-mode Enalbe call function through symbol table but not direct call\n");
printf(" --disable-llvm-intrinsics Disable the LLVM built-in intrinsics\n");
printf(" --disable-llvm-lto Disable the LLVM link time optimization\n");
@ -325,6 +326,10 @@ main(int argc, char *argv[])
else if (!strcmp(argv[0], "--enable-memory-profiling")) {
option.enable_stack_estimation = true;
}
else if (!strcmp(argv[0], "--xip")) {
option.is_indirect_mode = true;
option.disable_llvm_intrinsics = true;
}
else if (!strcmp(argv[0], "--enable-indirect-mode")) {
option.is_indirect_mode = true;
}