diff --git a/ggml-qnn.h b/ggml/include/ggml-qnn.h similarity index 100% rename from ggml-qnn.h rename to ggml/include/ggml-qnn.h diff --git a/ggml-qnn.cpp b/ggml/src/ggml-qnn.cpp similarity index 100% rename from ggml-qnn.cpp rename to ggml/src/ggml-qnn.cpp diff --git a/ggml-qnn/backend-ops.cpp b/ggml/src/ggml-qnn/backend-ops.cpp similarity index 100% rename from ggml-qnn/backend-ops.cpp rename to ggml/src/ggml-qnn/backend-ops.cpp diff --git a/ggml-qnn/backend-ops.hpp b/ggml/src/ggml-qnn/backend-ops.hpp similarity index 100% rename from ggml-qnn/backend-ops.hpp rename to ggml/src/ggml-qnn/backend-ops.hpp diff --git a/ggml-qnn/backend.hpp b/ggml/src/ggml-qnn/backend.hpp similarity index 100% rename from ggml-qnn/backend.hpp rename to ggml/src/ggml-qnn/backend.hpp diff --git a/ggml-qnn/logger.cpp b/ggml/src/ggml-qnn/logger.cpp similarity index 100% rename from ggml-qnn/logger.cpp rename to ggml/src/ggml-qnn/logger.cpp diff --git a/ggml-qnn/logger.hpp b/ggml/src/ggml-qnn/logger.hpp similarity index 100% rename from ggml-qnn/logger.hpp rename to ggml/src/ggml-qnn/logger.hpp diff --git a/ggml-qnn/qnn-types.hpp b/ggml/src/ggml-qnn/qnn-types.hpp similarity index 100% rename from ggml-qnn/qnn-types.hpp rename to ggml/src/ggml-qnn/qnn-types.hpp diff --git a/ggml-qnn/qnn.hpp b/ggml/src/ggml-qnn/qnn.hpp similarity index 100% rename from ggml-qnn/qnn.hpp rename to ggml/src/ggml-qnn/qnn.hpp diff --git a/ggml-qnn/tensor.hpp b/ggml/src/ggml-qnn/tensor.hpp similarity index 100% rename from ggml-qnn/tensor.hpp rename to ggml/src/ggml-qnn/tensor.hpp diff --git a/ggml-qnn/utils.cpp b/ggml/src/ggml-qnn/utils.cpp similarity index 100% rename from ggml-qnn/utils.cpp rename to ggml/src/ggml-qnn/utils.cpp diff --git a/ggml-qnn/utils.hpp b/ggml/src/ggml-qnn/utils.hpp similarity index 100% rename from ggml-qnn/utils.hpp rename to ggml/src/ggml-qnn/utils.hpp diff --git a/tests/ggml-qnn/CMakeLists.txt b/tests/ggml-qnn/CMakeLists.txt index 66e8c077a..b4f1bd6c0 100644 --- a/tests/ggml-qnn/CMakeLists.txt +++ b/tests/ggml-qnn/CMakeLists.txt @@ -13,18 +13,18 @@ set(QNN_INC_PATH ${QNN_SDK_PATH}/include/QNN) set(QNN_LIB_PATH ${QNN_SDK_PATH}/lib/aarch64-android) include_directories(${QNN_INC_PATH}) -include_directories(../../) # ggml.h +include_directories(../../ggml/include) # ggml.h, ggml-qnn.h set(SOURCE_FILES - ../../ggml.c - ../../ggml-alloc.c - ../../ggml-backend.c - ../../ggml-quants.c - ../../ggml-qnn/logger.cpp - ../../ggml-qnn/utils.cpp - ../../ggml-qnn/backend-ops.cpp - ../../ggml-qnn.cpp - ggml-qnn-ut.cpp + ../../ggml/src/ggml.c + ../../ggml/src/ggml-alloc.c + ../../ggml/src/ggml-backend.c + ../../ggml/src/ggml-quants.c + ../../ggml/src/ggml-qnn/logger.cpp + ../../ggml/src/ggml-qnn/utils.cpp + ../../ggml/src/ggml-qnn/backend-ops.cpp + ../../ggml/src/ggml-qnn.cpp + ggml-qnn-ut.cpp ) @@ -36,22 +36,20 @@ add_definitions(-D__ARM_NEON) add_definitions(-DGGML_USE_QNN) if(CMAKE_BUILD_TYPE STREQUAL "Release") -add_definitions(-DNDEBUG) -add_definitions(-O3) + add_definitions(-DNDEBUG) + add_definitions(-O3) else() -add_definitions(-O3) + add_definitions(-O3) endif() if (TARGET_SNAPDRAGON_8_GEN3) -# the below build optimization only verified and works well on Qualcomm SM8650-AB Snapdragon 8 Gen 3 -add_definitions(-march=armv8.7-a) -add_definitions(-mcpu=cortex-x1) -add_definitions(-mtune=cortex-x1) - + # the below build optimization only verified and works well on Qualcomm SM8650-AB Snapdragon 8 Gen 3 + add_definitions(-march=armv8.7-a) + add_definitions(-mcpu=cortex-x1) + add_definitions(-mtune=cortex-x1) else() -# the below build optimization might be works well on ALL Android phone equipped with Qualcomm mainstream mobile SoC -add_definitions(-mcpu=cortex-a72) - + # the below build optimization might be works well on ALL Android phone equipped with Qualcomm mainstream mobile SoC + add_definitions(-mcpu=cortex-a72) endif() add_compile_options("-Wall" "-Wno-sign-compare")