-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
org: move jemalloc from spec2006 to benchmarks
- Loading branch information
Showing
4 changed files
with
32 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,26 @@ | ||
{ lib | ||
, callPackage | ||
, riscv64-pkgs | ||
}: lib.makeScope lib.callPackageWith (self: { | ||
spec2006 = callPackage ./spec2006 {}; | ||
riscv64-jemalloc = riscv64-pkgs.jemalloc.overrideAttrs (oldAttrs: { | ||
configureFlags = (oldAttrs.configureFlags or []) ++ [ | ||
"--enable-static" | ||
"--disable-shared" | ||
]; | ||
preBuild = '' | ||
# Add weak attribute to C++ operators, same as jemalloc_cpp.patch | ||
sed -i 's/void \*operator new(size_t)/void *operator new(size_t) __attribute__((weak))/g' src/jemalloc_cpp.cpp | ||
sed -i 's/void operator delete(void \*)/void operator delete(void *) __attribute__((weak))/g' src/jemalloc_cpp.cpp | ||
''; | ||
# Ensure static libraries are installed | ||
postInstall = '' | ||
${oldAttrs.postInstall or ""} | ||
cp -v lib/libjemalloc.a $out/lib/ | ||
''; | ||
}); | ||
spec2006 = callPackage ./spec2006 { | ||
inherit (self) riscv64-jemalloc; | ||
}; | ||
|
||
openblas = callPackage ./openblas {}; | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters