FAILED: caffe2/CMakeFiles/torch_cuda.dir/__/aten/src/ATen/native/transformers/cuda/flash_attn/fmha_fprop_kernel_dispatch.cu.o /opt/cuda/bin/nvcc -forward-unknown-to-host-compiler -DAT_PER_OPERATOR_HEADERS -DGFLAGS_IS_A_DLL=0 -DGLOG_CUSTOM_PREFIX_SUPPORT -DHAVE_MALLOC_USABLE_SIZE=1 -DHAVE_MMAP=1 -DHAVE_SHM_OPEN=1 -DHAVE_SHM_UNLINK=1 -DMINIZ_DISABLE_ZIP_READER_CRC32_CHECKS -DONN XIFI_ENABLE_EXT=1 -DONNX_ML=1 -DONNX_NAMESPACE=onnx -DTORCH_CUDA_BUILD_MAIN_LIB -DUSE_CUDA -DUSE_EXPERIMENTAL_CUDNN_V8_API -DUSE_EXTERNAL_MZCRC -DUSE_FLASH_ATTENTION -D_FILE_OFFSET_BITS=64 -Dtorch_cuda_EXPORTS -I/var/tmp/portage/sci-libs/caffe2-1.13.1/w ork/pytorch-1.13.1_build/aten/src -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/aten/src -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1_build -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1 -I/var/tmp/portage /sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/cmake/../caffe2/contrib/opencl -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/cmake/../third_party/cudnn_frontend/include -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1_build/incl ude -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/aten/src/THC -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/aten/src/ATen/cuda -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/aten/src/ATen/../../../third_pa rty/cutlass/include -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1_build/caffe2/aten/src -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/aten/../third_party/catch/single_include -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work /pytorch-1.13.1/aten/src/ATen/.. -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/c10/cuda/../.. -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/c10/.. -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/torch/csrc/a pi -I/var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/torch/csrc/api/include -isystem=/opt/cuda/include -isystem=/usr/include/opencv4 -isystem=/usr/include/eigen3 -Xfatbin -compress-all -DONNX_NAMESPACE=onnx -gencode arch=compute_86,code=sm_8 6 -Xcudafe --diag_suppress=cc_clobber_ignored,--diag_suppress=integer_sign_change,--diag_suppress=useless_using_declaration,--diag_suppress=set_but_not_used,--diag_suppress=field_without_dll_interface,--diag_suppress=base_class_has_different_dll_interfa ce,--diag_suppress=dll_interface_conflict_none_assumed,--diag_suppress=dll_interface_conflict_dllexport_assumed,--diag_suppress=implicit_return_from_non_void_function,--diag_suppress=unsigned_compare_with_zero,--diag_suppress=declared_but_not_referenced ,--diag_suppress=bad_friend_decl --expt-relaxed-constexpr --expt-extended-lambda -Wno-deprecated-gpu-targets --expt-extended-lambda -DCUB_WRAPPED_NAMESPACE=at_cuda_detail -DCUDA_HAS_FP16=1 -D__CUDA_NO_HALF_OPERATORS__ -D__CUDA_NO_HALF_CONVERSIONS__ -D_ _CUDA_NO_HALF2_OPERATORS__ -D__CUDA_NO_BFLOAT16_CONVERSIONS__ -g -lineinfo --source-in-ptx -Xcompiler=-fPIC -DTH_HAVE_THREAD -Xcompiler=-Wall,-Wextra,-Wno-unused-parameter,-Wno-unused-function,-Wno-unused-result,-Wno-missing-field-initializers,-Wno-wri te-strings,-Wno-unknown-pragmas,-Wno-type-limits,-Wno-array-bounds,-Wno-unknown-pragmas,-Wno-sign-compare,-Wno-strict-overflow,-Wno-strict-aliasing,-Wno-error=deprecated-declarations,-Wno-missing-braces,-Wno-maybe-uninitialized -DTORCH_CUDA_BUILD_MAIN_L IB -std=c++14 -MD -MT caffe2/CMakeFiles/torch_cuda.dir/__/aten/src/ATen/native/transformers/cuda/flash_attn/fmha_fprop_kernel_dispatch.cu.o -MF caffe2/CMakeFiles/torch_cuda.dir/__/aten/src/ATen/native/transformers/cuda/flash_attn/fmha_fprop_kernel_dispa tch.cu.o.d -x cu -c /var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/aten/src/ATen/native/transformers/cuda/flash_attn/fmha_fprop_kernel_dispatch.cu -o caffe2/CMakeFiles/torch_cuda.dir/__/aten/src/ATen/native/transformers/cuda/flash_attn/fmha _fprop_kernel_dispatch.cu.o In file included from /var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/aten/src/ATen/native/transformers/cuda/flash_attn/fmha_fprop_kernel_dispatch.cu:30: /var/tmp/portage/sci-libs/caffe2-1.13.1/work/pytorch-1.13.1/aten/src/ATen/native/transformers/cuda/flash_attn/kernel_traits.h:30:10: fatal error: cutlass/cutlass.h: No such file or directory 30 | #include <cutlass/cutlass.h> | ^~~~~~~~~~~~~~~~~~~ compilation terminated. ---- $ emerge --info Portage 3.0.44 (python 3.10.9-final-0, default/linux/amd64/17.1/desktop/plasma, gcc-11, glibc-2.36-r5, 6.1.11-dorellan x86_64) ================================================================= System uname: Linux-6.1.11-dorellan-x86_64-Intel-R-_Core-TM-_i7-7700K_CPU_@_4.20GHz-with-glibc2.36 KiB Mem: 32769984 total, 5389292 free KiB Swap: 67633144 total, 67625268 free Head commit of repository gentoo: d16051f7223082375cc255d34da4a12737092748 Timestamp of repository flussence: Fri, 17 Feb 2023 14:02:21 +0000 Head commit of repository flussence: 08f5ff29cb5c059ec0e194e022e09370e0978f4f Timestamp of repository gentoo-zh: Sun, 19 Feb 2023 11:16:54 +0000 Head commit of repository gentoo-zh: 24dfb5af1912d84086085aca396251a771046735 Timestamp of repository guru: Fri, 17 Feb 2023 14:02:19 +0000 Head commit of repository guru: dd95ab3abc229844c1ad5c9bead61f593550a920 Timestamp of repository pentoo: Fri, 17 Feb 2023 22:46:54 +0000 Head commit of repository pentoo: bd296cb2254d063c853b16a40d25805becebe96b Timestamp of repository pg_overlay: Sat, 18 Feb 2023 10:16:54 +0000 Head commit of repository pg_overlay: d8670bbae2e6baf96b7e3343a37c45e45b387dbb Timestamp of repository science: Sun, 19 Feb 2023 04:46:51 +0000 Head commit of repository science: f9040627758b25cf0890f912a049a2f98aa7e798 Timestamp of repository steam-overlay: Tue, 07 Feb 2023 14:47:33 +0000 Head commit of repository steam-overlay: 8121a25bc99056e35ab2dd7924bb01ad8f80df8d Timestamp of repository tatsh-overlay: Sun, 19 Feb 2023 15:16:53 +0000 Head commit of repository tatsh-overlay: b751733ae1f5233d8ea8974fb428362ee6c2506a sh bash 5.1_p16-r2 ld GNU ld (Gentoo 2.39 p5) 2.39.0 distcc 3.4 x86_64-pc-linux-gnu [disabled] ccache version 4.7.4 [disabled] app-misc/pax-utils: 1.3.5::gentoo app-shells/bash: 5.1_p16-r2::gentoo dev-java/java-config: 2.3.1::gentoo dev-lang/perl: 5.36.0-r1::gentoo dev-lang/python: 2.7.18_p16-r1::gentoo, 3.9.16_p1::gentoo, 3.10.9-r1::gentoo, 3.11.1-r1::gentoo dev-lang/rust: 1.66.1::gentoo dev-util/ccache: 4.7.4::gentoo dev-util/cmake: 3.25.2::gentoo dev-util/meson: 1.0.0::gentoo sys-apps/baselayout: 2.9::gentoo sys-apps/openrc: 0.45.2-r2::gentoo sys-apps/sandbox: 2.29::gentoo sys-devel/autoconf: 2.13-r7::gentoo, 2.71-r5::gentoo sys-devel/automake: 1.16.5::gentoo sys-devel/binutils: 2.39-r4::gentoo sys-devel/binutils-config: 5.4.1::gentoo sys-devel/clang: 14.0.6-r1::gentoo, 15.0.7-r1::gentoo sys-devel/gcc: 11.3.1_p20230120-r1::gentoo, 12.2.1_p20230121-r1::gentoo sys-devel/gcc-config: 2.8::gentoo sys-devel/libtool: 2.4.7-r1::gentoo sys-devel/lld: 15.0.7::gentoo sys-devel/llvm: 14.0.6-r2::gentoo, 15.0.7::gentoo sys-devel/make: 4.3::gentoo sys-kernel/linux-headers: 5.15-r3::gentoo (virtual/os-headers) sys-libs/glibc: 2.36-r5::gentoo sys-libs/libselinux: 3.4::gentoo Repositories: gentoo location: /var/db/repos/gentoo sync-type: git sync-uri: https://anongit.gentoo.org/git/repo/gentoo.git priority: -1000 volatile: True flussence location: /var/db/repos/flussence sync-type: git sync-uri: https://github.com/gentoo-mirror/flussence.git masters: gentoo volatile: True gentoo-zh location: /var/db/repos/gentoo-zh sync-type: git sync-uri: https://github.com/gentoo-mirror/gentoo-zh.git masters: gentoo volatile: True guru location: /var/db/repos/guru sync-type: git sync-uri: https://github.com/gentoo-mirror/guru.git masters: gentoo volatile: True pentoo location: /var/db/repos/pentoo sync-type: git sync-uri: https://github.com/gentoo-mirror/pentoo.git masters: gentoo volatile: True pg_overlay location: /var/db/repos/pg_overlay sync-type: git sync-uri: https://github.com/gentoo-mirror/pg_overlay.git masters: gentoo volatile: True science location: /var/db/repos/science sync-type: git sync-uri: https://github.com/gentoo-mirror/science.git masters: gentoo volatile: True steam-overlay location: /var/db/repos/steam-overlay sync-type: git sync-uri: https://github.com/gentoo-mirror/steam-overlay.git masters: gentoo volatile: True tatsh-overlay location: /var/db/repos/tatsh-overlay sync-type: git sync-uri: https://github.com/gentoo-mirror/tatsh-overlay.git masters: gentoo volatile: True crossdev location: /usr/local/portage-crossdev masters: gentoo priority: 10 volatile: True local location: /usr/local/portage masters: gentoo priority: 999 volatile: True Installed sets: @esteam ACCEPT_KEYWORDS="amd64" ACCEPT_LICENSE="*" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-O2 -pipe -march=native" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/lib64/libreoffice/program/sofficerc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/themes/oxygen-gtk/gtk-2.0 /var/bind" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/init.d /etc/portage/savedconfig /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c /lib/modules" CXXFLAGS="-O2 -pipe -march=native" DISTDIR="/var/cache/distfiles" EMERGE_DEFAULT_OPTS="--alphabetical --keep-going --load-average=8 --autounmask=y --autounmask-write=n --verbose-conflicts --backtrack=100 --autounmask-backtrack=y --unordered-display" ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME" FCFLAGS="-O2 -pipe" FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs buildpkg-live candy config-protect-if-modified distlocks downgrade-backup ebuild-locks fixlafiles ipc-sandbox merge-sync multilib-strict network-sandbox news parallel-fetch pid-sandbox preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr" FFLAGS="-O2 -pipe" GENTOO_MIRRORS="http://mirrors.163.com/gentoo/" LANG="en_US.utf8" LDFLAGS="-Wl,-O1 -Wl,--as-needed" LEX="flex" LINGUAS="en en-GB en_US zh_CN" MAKEOPTS="-j9 -l8 --output-sync" PKGDIR="/var/cache/packages" PORTAGE_CONFIGROOT="/" PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git" PORTAGE_TMPDIR="/var/tmp" SHELL="" USE="MSP430 Mips WebAssembly X a52 aac acl acpi activities aio alsa amd64 apng av1 bitcoin_policy_spamfilter bittorrent bluetooth bluray branding brotli btrfs bzip2 cairo cdda cddb cdr chm cjk cli client conntrack corefonts cpudetection cpufreq_bench crossdev crypt cryptsetup cups cxx cycles d3d9 dbus declarative default-stack-clash-protection dhcp dhcp-tools dist-kernel dlz dnsretry dri drm dts dvd dvdr eap-sim eap-tls echo-cancel elogind encode epub evdev exif expat fat fcitx4 ffmpeg fftw flac fluidsynth fontconfig fortran ftdi fuse gd gdbm geoip2 gif gimp github gles1 gles2 gphoto2 gpm grub gstreamer gtk gui haptic hash-sysv-compat havege hcitop hddtemp http2 hwaccel iconv icu id3tag imagemagick imlib inotify io-uring iproute2 ipv6 ithreads jack jpeg json jumbo-build kde kwallet ladspa latex lcms libass libglvnd libinput libkms libnotify libtirpc libusb ljr lm_sensors logrotate lv2 lxc lz4 lzma lzo mad markdown matroska mdnsresponder-compat midi mikmod mingw minizip mjpeg mng mobi mobile mod mp3 mp4 mpeg mtp multilib multimedia nano ncurses nethack netlink nftables nls nptl ntfs ntp nvenc nvme ocr ogg onigurama oniguruma opencl opengl openh264 openimageio openmp openssl pam pango pcre pcre16 pdf pdf-writer pdfimport pipewire pipewire-alsa plasma png policykit postproc postscript ppds printsupport qml qt5 qtmedia rar rdp readline redfish rendering rle rustfmt s3tc samba sasl scanner sdl sdl2 seccomp secure-delete semantic-desktop sixel smp socks5 sound sound-server spell split-usr sqlite ssh ssl sslv3 startup-notification subtitles svc svg sync-plugin-portage system-llvm system-vulkan taglib tcl test-rust text theora tiff tk tracepath transparent-proxy truetype tty-helpers udev udf udisks uefi unicode unicode3 unit-mm update_drivedb upnp upower urandom usb usbredir utils uvm v4l vaapi vcd vdpau virt-network virtualbox visio vkd3d vnc vorbis vpx vulkan vulkan-overlay webp widgets winbind wireshark-plugins wps x264 x265 xattr xcb xcomposite xft xinerama xkb xla xml xmp xnasong xnest xrandr xv xvfb xvid xvmc zeroconf zip zlib zstd" ABI_X86="64" ADA_TARGET="gnat_2021" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias http2" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="aes avx avx2 f16c fma3 mmx mmxext pclmul popcnt rdrand sse sse2 sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="keyboard mouse synaptics evdev mutouch" KERNEL="linux" L10N="en en-GB en-US zh-CN" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LLVM_TARGETS="AMDGPU ARM BPF NVPTX X86" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php7-4 php8-0" POSTGRES_TARGETS="postgres12 postgres13" PYTHON_SINGLE_TARGET="python3_10" PYTHON_TARGETS="python3_10" QEMU_SOFTMMU_TARGETS="aarch64 arm x86_64" QEMU_USER_TARGETS="aarch64 arm x86_64" RUBY_TARGETS="ruby27 ruby30" SANE_BACKENDS="abaton agfafocus apple artec artec_eplus48u as6e avision bh canon canon630u canon_dr cardscan coolscan coolscan2 coolscan3 dc210 dc240 dc25 dell1600n_net dmc epjitsu epson epson2 fujitsu genesys gt68xx hp hp3500 hp3900 hp4200 hp5400 hp5590 hpljm1005 hs2p ibm kodak kodakaio kvs1025 kvs20xx kvs40xx leo lexmark ma1509 magicolor matsushita microtek microtek2 mustek mustek_usb mustek_usb2 nec net niash p5 pie pixma plustek plustek_pp pnm qcam ricoh rts8891 s9036 sceptre sharp sm3600 sm3840 snapscan sp15c st400 stv680 tamarack teco1 teco2 teco3 {-test} u12 umax umax1220u umax_pp xerox_mfp" USERLAND="GNU" VIDEO_CARDS="nvidia intel" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq proto steal rawnat logmark ipmark dhcpmac delude chaos account" Unset: ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS
Created attachment 853150 [details] build.log.gz build log (gzipped)
Perhaps it needs https://github.com/NVIDIA/cutlass I guess? There seems to be no ebuild for this package though, even in 3rd party repos
It needs an older version of that C++ template package, so I let it use its own Git submodule in my overlay: https://github.com/stefantalpalaru/gentoo-overlay/blob/61c6181347783d4b6e172059ef599984a51bf0cb/sci-libs/caffe2/caffe2-1.13.1-r100.ebuild#L14-L16
(In reply to Ștefan Talpalaru from comment #3) > It needs an older version of that C++ template package, so I let it use its > own Git submodule in my overlay: > https://github.com/stefantalpalaru/gentoo-overlay/blob/ > 61c6181347783d4b6e172059ef599984a51bf0cb/sci-libs/caffe2/caffe2-1.13.1-r100. > ebuild#L14-L16 Ah yeah that works - your ebuild has not just a different SRC_URI, but a few other changes too (eg an extra patch), how important are those?
> how important are those? Quite important if you use CUDA, need functorch, have MKL installed, want to build distributed programs, use MPI, etc. For functorch you also need my version of the "pytorch" ebuild.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b2f385739323abaf90da0a967b3cdc3a4f548bb0 commit b2f385739323abaf90da0a967b3cdc3a4f548bb0 Author: Alfredo Tupone <tupone@gentoo.org> AuthorDate: 2023-02-27 14:16:03 +0000 Commit: Alfredo Tupone <tupone@gentoo.org> CommitDate: 2023-02-27 14:16:03 +0000 sci-libs/caffe2: add cutlass deps Closes: https://bugs.gentoo.org/895490 Signed-off-by: Alfredo Tupone <tupone@gentoo.org> sci-libs/caffe2/caffe2-1.13.1-r1.ebuild | 1 + 1 file changed, 1 insertion(+) Additionally, it has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=72b00eae9b73d5180aed21f90e2f0471ad51047e commit 72b00eae9b73d5180aed21f90e2f0471ad51047e Author: Alfredo Tupone <tupone@gentoo.org> AuthorDate: 2023-02-27 14:13:07 +0000 Commit: Alfredo Tupone <tupone@gentoo.org> CommitDate: 2023-02-27 14:13:07 +0000 dev-libs/cutlass: new package, add 2.10.0 Bug: https://bugs.gentoo.org/895490 Signed-off-by: Alfredo Tupone <tupone@gentoo.org> dev-libs/cutlass/Manifest | 1 + dev-libs/cutlass/cutlass-2.10.0.ebuild | 33 +++++++++++++++++++++++++++++++++ dev-libs/cutlass/metadata.xml | 12 ++++++++++++ profiles/features/musl/package.mask | 4 ++++ 4 files changed, 50 insertions(+)