-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Update metagraph to 0.4.5 #59714
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update metagraph to 0.4.5 #59714
Changes from all commits
9f008da
f5dd754
ce328da
c6b302c
12dc8af
a291b25
c545689
62d844b
69efa5a
5f067b8
f6eee1b
3676287
fa8b46d
eb97070
5a7ae2f
e695a7a
23c8e46
165f91b
b4b00fd
9444345
7ab8b6a
7f3fec4
83498df
9f4d633
7e94d22
736c8da
92bc04c
2ac6f1d
6c1cce7
2f8f75f
5fd13b7
cfda535
4cec677
3f84318
8ae6200
e29dbd9
39e561e
55ea348
cdc4fe8
d6b3bbe
289bc50
9496379
d6d7df0
4e4fca6
958d575
c27f6dc
e439ed7
24e02ce
e576f18
8a0cb00
d39361e
32c37ed
62dc4ce
f81dff3
e67499c
2ce9760
ba5959b
4ca2c06
beb8a98
0a168cf
b4c1c85
d1da8cc
ca33d92
2975de5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
This file was deleted.
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. can you please make sure, this gets upstreamed?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, it's already in the master branch and will be in the next release. So, this patch can be removed in the next release. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,85 @@ | ||
| diff --git a/metagraph/CMakeLists.txt b/metagraph/CMakeLists.txt | ||
| index e651d2176..2371386b7 100644 | ||
| --- a/metagraph/CMakeLists.txt | ||
| +++ b/metagraph/CMakeLists.txt | ||
| @@ -331,16 +331,17 @@ find_package(Boost REQUIRED COMPONENTS iostreams) | ||
|
|
||
| findFolly() | ||
| if(FOLLY_FOUND) | ||
| - add_definitions(-D_USE_FOLLY -DUSE_JEMALLOC) | ||
| + add_definitions(-D_USE_FOLLY) | ||
| + if(Jemalloc_FOUND) | ||
| + add_definitions(-DUSE_JEMALLOC) | ||
| + else() | ||
| + message(WARNING "Jemalloc not found, some optimizations will be disabled.") | ||
| + endif() | ||
| include_directories(SYSTEM | ||
| external-libraries/folly | ||
| ${CMAKE_BINARY_DIR}/external-libraries/folly/include | ||
| ) | ||
| set(METALIBS ${METALIBS} fbvector) | ||
| -else() | ||
| - message(WARNING "Prerequisites for Folly (Facebook Open Source Library) not found." | ||
| - " Install jemalloc to compile with folly and enable various" | ||
| - " optimizations as well as reduce memory taken up by the Row-Compressed annotator.") | ||
| endif() | ||
|
|
||
| # makes ASIO not depend on boost | ||
| diff --git a/metagraph/CMakeListsHelpers.txt b/metagraph/CMakeListsHelpers.txt | ||
| index d7777c644..fd01b885d 100644 | ||
| --- a/metagraph/CMakeListsHelpers.txt | ||
| +++ b/metagraph/CMakeListsHelpers.txt | ||
| @@ -7,7 +7,7 @@ function (findOpenMP) | ||
| # and happily cached, thus messing up the compilation flags forever | ||
| unset(OpenMP_C_FLAGS CACHE) | ||
| unset(OpenMP_CXX_FLAGS CACHE) | ||
| -if(APPLE AND NOT CMAKE_CXX_COMPILER_ID STREQUAL "GNU") | ||
| +if(CMAKE_CXX_COMPILER_ID STREQUAL "AppleClang") | ||
| execute_process( | ||
| COMMAND brew --prefix libomp | ||
| OUTPUT_VARIABLE BREW_OMP_PREFIX | ||
| @@ -90,27 +90,25 @@ if(Jemalloc_FOUND) | ||
| endif() | ||
| endif() | ||
|
|
||
| -if(Jemalloc_FOUND) | ||
| - message(STATUS "Configuring Folly") | ||
| - include(external-libraries/folly/CMake/FollyConfigChecks.cmake) | ||
| - configure_file( | ||
| - external-libraries/folly/CMake/folly-config.h.cmake | ||
| - ${CMAKE_BINARY_DIR}/external-libraries/folly/include/folly/folly-config.h | ||
| - ) | ||
| - add_library(fbvector STATIC | ||
| - external-libraries/folly/folly/ScopeGuard.cpp | ||
| - external-libraries/folly/folly/memory/detail/MallocImpl.cpp | ||
| - ) | ||
| - target_include_directories(fbvector SYSTEM PRIVATE | ||
| - ${JEMALLOC_INCLUDE_DIRS} | ||
| - ${Boost_INCLUDE_DIRS} | ||
| - external-libraries/folly | ||
| - ${CMAKE_BINARY_DIR}/external-libraries/folly/include | ||
| - ${PROJECT_SOURCE_DIR}/src/common | ||
| - ) | ||
| - target_link_libraries(fbvector PRIVATE ${JEMALLOC_LIBRARIES} ${Boost_LIBRARIES}) | ||
| - set(FOLLY_FOUND TRUE PARENT_SCOPE) | ||
| -endif() | ||
| +message(STATUS "Configuring Folly") | ||
| +include(external-libraries/folly/CMake/FollyConfigChecks.cmake) | ||
| +configure_file( | ||
| + external-libraries/folly/CMake/folly-config.h.cmake | ||
| + ${CMAKE_BINARY_DIR}/external-libraries/folly/include/folly/folly-config.h | ||
| +) | ||
| +add_library(fbvector STATIC | ||
| + external-libraries/folly/folly/ScopeGuard.cpp | ||
| + external-libraries/folly/folly/memory/detail/MallocImpl.cpp | ||
| +) | ||
| +target_include_directories(fbvector SYSTEM PRIVATE | ||
| + ${JEMALLOC_INCLUDE_DIRS} | ||
| + ${Boost_INCLUDE_DIRS} | ||
| + external-libraries/folly | ||
| + ${CMAKE_BINARY_DIR}/external-libraries/folly/include | ||
| + ${PROJECT_SOURCE_DIR}/src/common | ||
| +) | ||
| +target_link_libraries(fbvector PRIVATE ${JEMALLOC_LIBRARIES} ${Boost_LIBRARIES}) | ||
| +set(FOLLY_FOUND TRUE PARENT_SCOPE) | ||
| endfunction() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is this Linux only?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There were issues with compiling with jemalloc.
It couldn't find the jemalloc headers. When I compile locally on my MacOS, everything works. So it's a bit difficult to troubleshoot this, as this appears to be specific to the online setup and paths where it installs packages.