Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@

inputs = {
flake-utils.url = "github:numtide/flake-utils";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable-small";
# Temporarily pin this commit to fix ucx issues:
# https://github.com/NixOS/nixpkgs/pull/538738
nixpkgs.url = "github:NixOS/nixpkgs/ec1a11210589d294f0ac99d3290a27e6c73dfa1d";
#nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable-small";
flake-compat.url = "github:edolstra/flake-compat";
rust-overlay = {
url = "github:oxalica/rust-overlay";
Expand Down
2 changes: 1 addition & 1 deletion nix-builder/lib/extension/torch/arch.nix
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ stdenv.mkDerivation (prevAttrs: {

# Make dependent on build configuration dependencies once
# the Torch dependency is gone.
cuda_cccl
cccl
libcublas
libcusolver
libcusparse
Expand Down
2 changes: 1 addition & 1 deletion nix-builder/lib/extension/tvm-ffi/arch.nix
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ stdenv.mkDerivation (prevAttrs: {

# Make dependent on build configuration dependencies once
# the Torch dependency is gone.
cuda_cccl
cccl
libcublas
libcusolver
libcusparse
Expand Down
1 change: 0 additions & 1 deletion nix-builder/lib/mk-build-set.nix
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ let
});
}
);

};

overlayForRocmVersion = rocmVersion: self: super: {
Expand Down
12 changes: 12 additions & 0 deletions nix-builder/overlay.nix
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

final: prev:
{
# Local packages/hooks.
kernel-builder = final.callPackage ./pkgs/kernel-builder { inherit builderProvenance; };

cmakeNvccThreadsHook = final.callPackage ./pkgs/cmake-nvcc-threads-hook { };
Expand Down Expand Up @@ -44,6 +45,17 @@ final: prev:
}
);

# nixpkgs overrides
ucc = prev.ucc.overrideAttrs (
_: prevAttrs: {
# Concurrent build flags do not seem to get passed through? So instead, let's
# add parallelism to building CUDA files.
preConfigure = prevAttrs.preConfigure + ''
export NVCC_CFLAGS="--threads $NIX_BUILD_CORES"
'';
Comment on lines +51 to +55

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we could benefit from this in the CI of kernels-community and the GitHub Actions workflow we have for building? Cc: @drbh

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is already done automatically when building kernels using the nvcc threads hook.

}
);

ucx = prev.ucx.overrideAttrs (
_: prevAttrs: {
buildInputs = prevAttrs.buildInputs ++ [ final.cudaPackages.cuda_nvcc ];
Expand Down
Loading