Skip to content

Commit

Permalink
oneDNN: disable tests to avoid illegal instructions
Browse files Browse the repository at this point in the history
oneDNN tests fail on some Hydra builders because they do not support SSE
4.2. Unfortunately, oneDNN does not seem to work without SSE 4.2, see
issues NixOS#93692 and NixOS#93747.
  • Loading branch information
danieldk authored and ian bierlich committed Sep 14, 2020
1 parent 469d354 commit 3772404
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions pkgs/development/libraries/oneDNN/default.nix
Expand Up @@ -18,21 +18,13 @@ stdenv.mkDerivation rec {

nativeBuildInputs = [ cmake ];

doCheck = true;

cmakeFlags = [
# oneDNN compiles with -msse4.1 by default, but not all x86_64
# CPUs support SSE 4.1.
"-DDNNL_ARCH_OPT_FLAGS="
];
# Tests fail on some Hydra builders, because they do not support SSE4.2.
doCheck = false;

# The test driver doesn't add an RPath to the build libdir
preCheck = ''
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH''${LD_LIBRARY_PATH:+:}$PWD/src
export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH''${DYLD_LIBRARY_PATH:+:}$PWD/src
'' + lib.optionalString stdenv.isx86_64 ''
# Use baseline SIMD in case CPU features get misdetected.
export DNNL_MAX_CPU_ISA=SSE41
'';

# The cmake install gets tripped up and installs a nix tree into $out, in
Expand Down

0 comments on commit 3772404

Please sign in to comment.