Skip to content

Commit

Permalink
ggml C++ bindings wip
Browse files Browse the repository at this point in the history
  • Loading branch information
slaren committed Oct 15, 2023
1 parent 159bdae commit d7338cd
Show file tree
Hide file tree
Showing 7 changed files with 1,465 additions and 1 deletion.
1 change: 1 addition & 0 deletions examples/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,4 @@ add_subdirectory(replit)
add_subdirectory(mpt)
add_subdirectory(starcoder)
add_subdirectory(sam)
add_subdirectory(ggml-cpp)
21 changes: 21 additions & 0 deletions examples/ggml-cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#
# gpt-2-cpp

set(TEST_TARGET gpt-2-cpp)
add_executable(${TEST_TARGET} gpt-2-cpp.cpp)
target_link_libraries(${TEST_TARGET} PRIVATE ggml common common-ggml)

#
# For GPU offloading

if (GGML_CUBLAS)
add_compile_definitions(GGML_USE_CUBLAS)
endif()

if (GGML_CLBLAST)
add_compile_definitions(GGML_USE_CLBLAST)
endif()

if (GGML_METAL)
add_compile_definitions(GGML_USE_METAL)
endif()
Loading

0 comments on commit d7338cd

Please sign in to comment.