| cmake_minimum_required(VERSION 3.13.4) |
| |
| # ------------------------------------------------------------------------------ |
| # Project configuration |
| # ------------------------------------------------------------------------------ |
| project(ml-models-public) |
| |
| set_property(GLOBAL PROPERTY USE_FOLDERS ON) |
| |
| set(SPRINGBOK_IREE_DIR "$ENV{ROOTDIR}/sw/vec_iree" CACHE PATH |
| "Springbok IREE library path (default: $ENV{ROOTDIR}/sw/vec_iree)") |
| |
| include_directories(BEFORE SYSTEM ${CMAKE_CURRENT_LIST_DIR}) |
| include_directories(BEFORE SYSTEM ${CMAKE_CURRENT_BINARY_DIR}) |
| include_directories(BEFORE SYSTEM ${SPRINGBOK_IREE_DIR}) |
| |
| # Include springbok_iree libraries. |
| add_subdirectory(${SPRINGBOK_IREE_DIR} springbok_iree) |
| |
| # Add compilation options. |
| include(${SPRINGBOK_IREE_DIR}/cmake/springbok_ops.cmake) |
| |
| # Set default linker memory size for the whole project. |
| set(TCM_LENGTH "16M" CACHE STRING "TCM Length (default: 16M)") |
| add_link_options("LINKER:--defsym=__tcm_length__=${TCM_LENGTH}") |
| |
| # Include model directories. |
| add_subdirectory(float_models) |
| add_subdirectory(quant_models) |