Skip to content
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

cudatoolkit: install missing libraries for nvprof #83291

Merged
merged 1 commit into from Sep 12, 2020

Conversation

tomberek
Copy link
Contributor

Motivation for this change

nvprof cannot find runtime libraries

Things done

Added a line copying (should it be a mv instead? I'm not sure if anything else depends on the current location of things like libcupti) libraries to $out/lib

Could probably use feedback on non-NixOS systems.

  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

Copy link
Contributor

@flokli flokli left a comment

Choose a reason for hiding this comment

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

According to https://www.pgroup.com/userforum/viewtopic.php?t=6578, simply making libcupti.so somehow available to the dynamic linker should be enough to get things working.

As $out/bin/nvprof already adds $out/lib to LD_LIBRARY_PATH, this is what's needed to get nvprof to discover libcupti.

Can you update the cp to mv, and update the commit message to be cudatoolkit: install missing libraries for nvprof

pkgs/development/compilers/cudatoolkit/common.nix Outdated Show resolved Hide resolved
@tomberek tomberek changed the title cudatoolkit: nvprof libs cudatoolkit: install missing libraries for nvprof Apr 2, 2020
Copy link
Contributor

@danieldk danieldk left a comment

Choose a reason for hiding this comment

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

Added an upper bound, since this doesn't work with cudatoolkit 11 (which already works correctly).

@danieldk danieldk merged commit 7c0afd4 into NixOS:master Sep 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants