-
Notifications
You must be signed in to change notification settings - Fork 50
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
chore: Build mimalloc as a C++ library #264
base: master
Are you sure you want to change the base?
Conversation
This will have the benefit of throwing exceptions if allocations fail in the C++ APIs (like `new`)
cmake/third_party.cmake
Outdated
CMAKE_PASS_FLAGS "-DCMAKE_BUILD_TYPE=Release -DMI_BUILD_SHARED=OFF -DMI_BUILD_TESTS=OFF \ | ||
-DMI_INSTALL_TOPLEVEL=ON -DMI_OVERRIDE=OFF -DCMAKE_C_FLAGS=-g \ | ||
${HELIO_MIMALLOC_OPTS}" | ||
CMAKE_PASS_FLAGS "-DCMAKE_BUILD_TYPE=Release -DMI_USE_CXX=ON -DMI_BUILD_SHARED=OFF \ |
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.
I only added -DMI_USE_CXX=ON
, the rest is just bad diff display due to line breaks :|
@romange do you think we should merge this PR? |
… On Sun, Jun 23, 2024, 11:51 AM Shahar Mike ***@***.***> wrote:
@romange <https://github.com/romange> do you think we should merge this
PR?
I think that, given we know of scenarios in which mimalloc could return
nullptr (even if not in our production, although we also suspect other
cases in our production), it might be a good idea.
What are the downsides of doing so? It's the same code, if you compile it
with a C or C++ compiler, that shouldn't matter I think
—
Reply to this email directly, view it on GitHub
<#264 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AA4BFCG232KF4WXWZ6OVZ6LZI2ECTAVCNFSM6AAAAABHOK6PUSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCOBUHEYDOMJSGM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
45e35b1
to
2290be2
Compare
1402f6c
to
f102aa0
Compare
This will have the benefit of throwing exceptions if allocations fail in the C++ APIs (like
new
)Related to #2914