mirror of
https://github.com/ggerganov/llama.cpp.git
synced 2024-11-13 14:29:52 +00:00
097e121e2f
* llama : add benchmark example * add to examples CMakeLists.txt * fix msvc build * add missing include * add Bessel's correction to stdev calculation Co-authored-by: Johannes Gäßler <johannesg@5d6.de> * improve markdown formatting * add missing include * print warning is NDEBUG is not defined * remove n_prompt and n_gen from the matrix, use each value separately instead * better checks for non-optimized builds * llama.cpp : fix MEM_REQ_SCRATCH0 reusing the value of n_ctx of the first call * fix json formatting * add sql output * add basic cpu and gpu info (linx/cuda only) * markdown: also show values that differ from the default * markdown: add build id * cleanup * improve formatting * formatting --------- Co-authored-by: Johannes Gäßler <johannesg@5d6.de>
56 lines
1.1 KiB
CMake
56 lines
1.1 KiB
CMake
# dependencies
|
|
|
|
find_package(Threads REQUIRED)
|
|
|
|
# third-party
|
|
|
|
# ...
|
|
|
|
# common
|
|
|
|
set(TARGET common)
|
|
|
|
add_library(${TARGET} OBJECT
|
|
common.h
|
|
common.cpp
|
|
console.h
|
|
console.cpp
|
|
grammar-parser.h
|
|
grammar-parser.cpp
|
|
)
|
|
|
|
if (BUILD_SHARED_LIBS)
|
|
set_target_properties(${TARGET} PROPERTIES POSITION_INDEPENDENT_CODE ON)
|
|
endif()
|
|
|
|
target_include_directories(${TARGET} PUBLIC .)
|
|
target_compile_features(${TARGET} PUBLIC cxx_std_11)
|
|
target_link_libraries(${TARGET} PRIVATE llama)
|
|
|
|
# examples
|
|
|
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
|
|
|
|
if (EMSCRIPTEN)
|
|
else()
|
|
add_subdirectory(main)
|
|
add_subdirectory(quantize)
|
|
add_subdirectory(quantize-stats)
|
|
add_subdirectory(perplexity)
|
|
add_subdirectory(embedding)
|
|
add_subdirectory(save-load-state)
|
|
add_subdirectory(benchmark)
|
|
add_subdirectory(baby-llama)
|
|
add_subdirectory(train-text-from-scratch)
|
|
add_subdirectory(convert-llama2c-to-ggml)
|
|
add_subdirectory(simple)
|
|
add_subdirectory(embd-input)
|
|
add_subdirectory(llama-bench)
|
|
if (LLAMA_METAL)
|
|
add_subdirectory(metal)
|
|
endif()
|
|
if (LLAMA_BUILD_SERVER)
|
|
add_subdirectory(server)
|
|
endif()
|
|
endif()
|