run.sh 921 B

123456789101112131415161718192021222324252627282930313233
  1. #!/bin/bash
  2. #
  3. # Copyright (C) 2019 Intel Corporation. All rights reserved.
  4. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
  5. #
  6. if [[ $1 == "--classic-interp" ]]; then
  7. CMAKE_FLAGS="-DWAMR_BUILD_INTERP=1 -DWAMR_BUILD_FAST_INTERP=0"
  8. elif [[ $1 == "--fast-interp" ]]; then
  9. CMAKE_FLAGS="-DWAMR_BUILD_INTERP=1 -DWAMR_BUILD_FAST_INTERP=1"
  10. elif [[ $1 == "--fast-jit" ]]; then
  11. CMAKE_FLAGS="-DWAMR_BUILD_FAST_JIT=1"
  12. elif [[ $1 == "--jit" ]]; then
  13. CMAKE_FLAGS="-DWAMR_BUILD_JIT=1"
  14. elif [[ $1 == "--multi-tier-jit" ]]; then
  15. CMAKE_FLAGS="-DWAMR_BUILD_FAST_JIT=1 -DWAMR_BUILD_JIT=1"
  16. fi
  17. TARGET="X86_64"
  18. if [[ $3 = "X86_32" ]]; then
  19. TARGET="X86_32"
  20. fi
  21. echo "============> test dump-invoke-native"
  22. rm -fr build
  23. mkdir build && cd build
  24. cmake .. ${CMAKE_FLAGS} -DWAMR_BUILD_TARGET=${TARGET}
  25. make -j ${nproc} > /dev/null 2>&1
  26. cd ..
  27. echo "============> run test-invoke-native"
  28. ./build/test_invoke_native