arrayfire / arrayfire

ArrayFire: a general purpose GPU library.
https://arrayfire.com
BSD 3-Clause "New" or "Revised" License
4.52k stars 536 forks source link

[Build] Support for MacOS-arm64 Please #3340

Open Congyuwang opened 1 year ago

Congyuwang commented 1 year ago

ignoring file /opt/arrayfire/lib/libaf.dylib, building for macOS-arm64 but attempting to link with file built for macOS-x86_64

Seems not working for arm64 macOS.

Tried to build from source, but got error target LAPACKE::LAPACKE not found on m2 chip MacBook Air. MacOS Ventura.

umar456 commented 1 year ago

We currently do not have a machine that supports that OS/cpu combo in our build environment. I am willing to work with you to make the necessary changes to the library to support that platform on the CPU and OpenCL backends. We have supported macOS on x86 in the past but I am not sure what problems we would run into with the latest updates.

Congyuwang commented 1 year ago

Great, I’ll try to compile from source and paste the current error code here later on, since I’m not very familiar with openCL.

umar456 commented 1 year ago

It would be more productive if you could post on our slack. We can have a better back and forth there. I am not going to be able to get to it today but I will follow up with you after my jury duty. If slack is not possible the posting here is fine.

Congyuwang commented 1 year ago

For the moment, I'll just paste my output here. Hope that it will be an easy fix. If it doesn't seem easy, we can go to slack I think.

System information:

MacOS Ventura 13.0.1
MacBook Air M2

My commands from a clean build:

# install deps
brew install cmake freeimage boost glfw fftw

# clone lib
git clone git@github.com:Congyuwang/arrayfire.git && cd arrayfire
git submodule init
git submodule update

# cd build folder
mkdir build && cd build

# build for CPU and openCL
cmake .. -DCMAKE_BUILD_TYPE=Release -DAF_BUILD_CUDA=OFF -DAF_BUILD_OPENCL=ON

cmake command output

(base) 
arrayfire/build on  master 
❯ cmake .. -DCMAKE_BUILD_TYPE=Release -DAF_BUILD_CUDA=OFF -DAF_BUILD_OPENCL=ON
-- The C compiler identification is AppleClang 14.0.0.14000029
-- The CXX compiler identification is AppleClang 14.0.0.14000029
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Performing Test has_cxx_fast_math
-- Performing Test has_cxx_fast_math - Success
-- Performing Test has_cxx_fp_model
-- Performing Test has_cxx_fp_model - Failed
-- Performing Test has_cxx_no_errno_math
-- Performing Test has_cxx_no_errno_math - Failed
-- Performing Test has_cxx_no_trapping_math
-- Performing Test has_cxx_no_trapping_math - Success
-- Performing Test has_cxx_no_signed_zeros
-- Performing Test has_cxx_no_signed_zeros - Success
-- Performing Test has_cxx_no_ieee_fp
-- Performing Test has_cxx_no_ieee_fp - Failed
-- Performing Test has_cxx_unqualified_std_cast_call
-- Performing Test has_cxx_unqualified_std_cast_call - Failed
-- Performing Test has_cxx_error_reorder_ctor
-- Performing Test has_cxx_error_reorder_ctor - Success
Debug information is not split on OSX
CMake Warning at CMakeModules/InternalUtils.cmake:178 (message):
  CMAKE_INSTALL_RPATH is required when installing ArrayFire to the local
  system.  Set it to /opt/arrayfire/lib if making the installer or your own
  custom install path.
Call Stack (most recent call first):
  CMakeLists.txt:41 (arrayfire_set_cmake_default_variables)

CUDA_TOOLKIT_ROOT_DIR not found or specified
-- Could NOT find CUDA (missing: CUDA_TOOLKIT_ROOT_DIR CUDA_NVCC_EXECUTABLE CUDA_INCLUDE_DIRS CUDA_CUDART_LIBRARY) (Required is at least version "9.0")
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) 
-- Could NOT find cuDNN (missing: cuDNN_LINK_LIBRARY cuDNN_INCLUDE_DIRS) (Required is at least version "4.0")
-- Looking for CL_VERSION_2_0
-- Looking for CL_VERSION_2_0 - not found
-- Looking for CL_VERSION_1_2
-- Looking for CL_VERSION_1_2 - found
-- Found OpenCL: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/System/Library/Frameworks/OpenCL.framework (found suitable version "1.2", minimum required is "1.2") 
-- Found OpenGL: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/System/Library/Frameworks/OpenGL.framework  
-- Found FreeImage: /opt/homebrew/include  
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE  
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) 
-- Found FFTW: /opt/homebrew/include  
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) 
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of void*
-- Check size of void* - done
-- Checking for [Accelerate]
-- Includes found
-- Looking for cblas_dgemm
-- Looking for cblas_dgemm - found
-- CBLAS Symbols FOUND
-- CBLAS library found
-- Could NOT find PkgConfig (missing: PKG_CONFIG_EXECUTABLE) 
-- Could NOT find LAPACKE (missing: LAPACKE_LIB LAPACKE_INCLUDES) 
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE) 
CMake Warning (dev) at /opt/homebrew/Cellar/cmake/3.25.1/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (OpenMP_C)
  does not match the name of the calling package (OpenMP).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  CMakeModules/FindOpenMP.cmake:402 (find_package_handle_standard_args)
  CMakeModules/FindMKL.cmake:76 (find_package)
  CMakeLists.txt:62 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Warning (dev) at /opt/homebrew/Cellar/cmake/3.25.1/share/cmake/Modules/FindPackageHandleStandardArgs.cmake:438 (message):
  The package name passed to `find_package_handle_standard_args` (OpenMP_CXX)
  does not match the name of the calling package (OpenMP).  This can lead to
  problems in calling code that expects `find_package` result variables
  (e.g., `_FOUND`) to follow a certain pattern.
Call Stack (most recent call first):
  CMakeModules/FindOpenMP.cmake:402 (find_package_handle_standard_args)
  CMakeModules/FindMKL.cmake:76 (find_package)
  CMakeLists.txt:62 (find_package)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Check size of int
-- Check size of int - done
-- MKL: Thread Layer(Intel OpenMP) Interface(4-byte Integer)
-- Could NOT find MKL: Source the compilervars.sh or mklvars.sh scripts included with your installation of MKL. This script searches for the libraries in MKLROOT, LIBRARY_PATHS(Linux), and LIB(Windows) environment variables (missing: MKL_INCLUDE_DIR MKL_Core_LINK_LIBRARY MKL_Interface_LINK_LIBRARY MKL_ThreadLayer_LINK_LIBRARY) 
-- Could NOT find MKL: Source the compilervars.sh or mklvars.sh scripts included with your installation of MKL. This script searches for the libraries in MKLROOT, LIBRARY_PATHS(Linux), and LIB(Windows) environment variables (missing: MKL_INCLUDE_DIR MKL_Core_STATIC_LINK_LIBRARY MKL_Interface_STATIC_LINK_LIBRARY MKL_ThreadLayer_STATIC_LINK_LIBRARY) 
-- Could NOT find GTest (missing: GTEST_LIBRARY GTEST_INCLUDE_DIR GTEST_MAIN_LIBRARY) 
-- Found Boost: /opt/homebrew/lib/cmake/Boost-1.80.0/BoostConfig.cmake (found suitable version "1.80.0", minimum required is "1.70")  
-- Looking for sgemm_
-- Looking for sgemm_ - not found
-- Looking for dgemm_
-- Looking for dgemm_ - found
-- Found BLAS: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/System/Library/Frameworks/Accelerate.framework  
-- Looking for cheev_
-- Looking for cheev_ - found
-- Found LAPACK: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/System/Library/Frameworks/Accelerate.framework;-lm;-ldl  
-- Build spdlog: 1.9.2
-- Build type: Release
-- Project 'span_lite', package 'span-lite' version: '0.10.2'
-- Found OpenCL: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/System/Library/Frameworks/OpenCL.framework (found version "1.2") 
-- UNICODE feature disabled on linux
-- 64bit build - FIND_LIBRARY_USE_LIB64_PATHS TRUE
-- Found Boost: /opt/homebrew/lib/cmake/Boost-1.80.0/BoostConfig.cmake (found suitable version "1.80.0", minimum required is "1.33.0") found components: program_options 
-- Boost_PROGRAM_OPTIONS_LIBRARY: Boost::program_options
-- Found OpenCL: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/System/Library/Frameworks/OpenCL.framework  
-- Found FFTW: /opt/homebrew/lib/libfftw3f.dylib;/opt/homebrew/lib/libfftw3.dylib  
-- CMAKE_CXX_COMPILER flags: 
-- CMAKE_CXX_COMPILER debug flags: -g
-- CMAKE_CXX_COMPILER release flags: -O3 -DNDEBUG
-- CMAKE_CXX_COMPILER relwithdebinfo flags: -O2 -g -DNDEBUG
-- CMAKE_EXE_LINKER link flags: 
FFT clients will NOT be built
GoogleTest unit tests will NOT be built
FFT callback client will NOT be built
-- Performing Test has_ignored_attributes_flag
-- Performing Test has_ignored_attributes_flag - Success
-- Found OpenCL: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.0.sdk/System/Library/Frameworks/OpenCL.framework (found version "1.2") 
-- Performing Test has_all_warnings_flag
-- Performing Test has_all_warnings_flag - Success
-- Found Python: /Users/congyuwang/miniconda3/bin/python3.9 (found version "3.9.12") found components: Interpreter 
-- Configuring done
CMake Error at src/backend/opencl/CMakeLists.txt:486 (target_link_libraries):
  Target "afopencl" links to:

    LAPACKE::LAPACKE

  but the target was not found.  Possible reasons include:

    * There is a typo in the target name.
    * A find_package call is missing for an IMPORTED target.
    * An ALIAS target is missing.

-- Generating done
CMake Generate step failed.  Build files cannot be regenerated correctly.
(base) 
arrayfire/build on  master via △ v3.25.1 took 2m30s 
❯ 

The error is: target LAPACKE::LAPACKE not found.

sp-mishra commented 1 year ago

Did you manage to compile it? I was able to compile the CPU build for M1. The OpenCL build on M1 is throwing the error Undefined symbols for architecture arm64: "_cbdsqr_", referenced from: LAPACKE_cbdsqr_work(int, char, int, int, int, int, float*, float*, cl_float2*, int, cl_float2*, int, cl_float2*, int, float*) in lapacke.cpp.o (maybe you meant: LAPACKE_cbdsqr_work(int, char, int, int, int, int, float*, float*, cl_float2*, int, cl_float2*, int, cl_float2*, int, float*))

Congyuwang commented 1 year ago

No, I tried to build with OpenCL too. I get:

CMake Error at src/backend/opencl/CMakeLists.txt:486 (target_link_libraries):
  Target "afopencl" links to:

    LAPACKE::LAPACKE

  but the target was not found
lwabeke commented 11 months ago

I was getting similar errors My process to work around it:

Inspired by: https://superuser.com/questions/776061/installing-lapacke-using-make-on-mac

Went to https://www.netlib.org/lapack/lug/node14.html which gave me the link to download the sources from http://www.netlib.org/lapack/lapack.tgz

extract tar
mkdir build
cd build

cmake -DLAPACKE=ON ..
make -j30
sudo make install

Then I went back to array fire source and could rerun cmake and build arrayfire's make test is giving many failures, but at least some of the tests are passing on both CPU and OpenCL

76% tests passed, 64 tests failed out of 265
Total Test time (real) = 644.83 sec

The following tests FAILED:
      1 - test_anisotropic_diffusion_cpu (Failed)
      2 - test_anisotropic_diffusion_opencl (Failed)
      4 - test_approx1_opencl (Failed)
      6 - test_approx2_opencl (Failed)
     10 - test_array_death_tests_opencl (Failed)
     19 - test_bilateral_cpu (Failed)
     20 - test_bilateral_opencl (Failed)
     25 - test_canny_cpu (Failed)
     26 - test_canny_opencl (Failed)
     37 - test_confidence_connected_cpu (Failed)
     38 - test_confidence_connected_opencl (Failed)
     40 - test_constant_opencl (Failed)
     42 - test_convolve_opencl (Failed)
     48 - test_diagonal_opencl (Failed)
     54 - test_dog_opencl (Failed)
     61 - test_fast_cpu (Failed)
     62 - test_fast_opencl (Failed)
     82 - test_getting_started_opencl (Failed)
     86 - test_gradient_opencl (Failed)
     93 - test_harris_cpu (Failed)
     94 - test_harris_opencl (Failed)
     97 - test_homography_cpu (Failed)
     98 - test_homography_opencl (Failed)
    103 - test_imageio_cpu (Failed)
    104 - test_imageio_opencl (Failed)
    111 - test_inverse_deconv_cpu (Failed)
    112 - test_inverse_deconv_opencl (Failed)
    119 - test_iterative_deconv_cpu (Failed)
    120 - test_iterative_deconv_opencl (Failed)
    124 - test_join_opencl (Failed)
    126 - test_lu_dense_opencl (Failed)
    134 - test_mean_opencl (Failed)
    135 - test_meanshift_cpu (Failed)
    136 - test_meanshift_opencl (Failed)
    137 - test_meanvar_cpu (Failed)
    151 - test_moments_cpu (Failed)
    152 - test_moments_opencl (Failed)
    153 - test_morph_cpu (Failed)
    154 - test_morph_opencl (Failed)
    162 - test_orb_cpu (Failed)
    163 - test_orb_opencl (Failed)
    167 - test_pinverse_opencl (Failed)
    169 - test_qr_dense_opencl (Failed)
    178 - test_reduce_opencl (Failed)
    192 - test_sat_opencl (Failed)
    198 - test_select_opencl (Failed)
    202 - test_shift_opencl (Failed)
    203 - test_gloh_cpu (Failed)
    204 - test_gloh_opencl (Failed)
    205 - test_sift_cpu (Failed)
    206 - test_sift_opencl (Failed)
    209 - test_solve_dense_cpu (Failed)
    218 - test_sparse_opencl (SEGFAULT)
    220 - test_sparse_arith_opencl (SEGFAULT)
    222 - test_sparse_convert_opencl (SEGFAULT)
    225 - test_susan_cpu (Failed)
    226 - test_susan_opencl (Failed)
    228 - test_svd_dense_opencl (Failed)
    229 - test_threading_cpu (Failed)
    230 - test_threading_opencl (SEGFAULT)
    232 - test_tile_opencl (Failed)
    235 - test_transform_cpu (SEGFAULT)
    236 - test_transform_opencl (SEGFAULT)
    250 - test_var_opencl (Failed)
ArrayFire v3.9.0 (OpenCL, 64-bit Mac OSX, build b59a1ae53)
[0] APPLE: Apple M2 Pro, 10922 MB
Errors while running CTest
Output from these tests are in: /Users/lwabeke/Code/arrayfire/build/Testing/Temporary/LastTest.log
Use "--rerun-failed --output-on-failure" to re-run the failed cases verbosely.
make: *** [test] Error 8

OpenCL is only seeing 1 device, but it seems that is the GPU side of the chip, since it gives significantly different benchmark results, while not showing up as a high %CPU in activity monitor.

scfurl commented 10 months ago

I initially got the same LAPACKE error as @Congyuwang on an M1 Mac... then followed @lwabeke's advice

I ran following


brew install cmake freeimage
brew install fftw
brew install boost

brew tap homebrew/versions # didnt work
brew install glfw

brew install openblas

wget http://www.netlib.org/lapack/lapack.tgz # per @lwabeke 
cd lapack-3.10.1
mkdir build
cd build
cmake -DLAPACKE=ON ..
make -j8
sudo make install

git clone https://github.com/arrayfire/arrayfire.git
cd arrayfire
git submodule init
git submodule update
ccmake . # than ran configure, exited
mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DAF_BUILD_CUDA=OFF -DAF_BUILD_OPENCL=ON -DCMAKE_INSTALL_PREFIX=/opt/arrayfire
cd ..
make -j8

attached is my CMakeCache.txt CMakeCache.txt

Here is the error obtained when running make [ 0%] Building C object extern/af_glad-build/CMakeFiles/af_glad_obj_lib.dir/src/glad.c.o [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_char.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 0%] Building CXX object CMakeFiles/bin2cpp.dir/CMakeModules/bin2cpp.cpp.o [ 0%] Building CXX object extern/spdlog-build/CMakeFiles/spdlog.dir/src/spdlog.cpp.o [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_float.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_short.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_double.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_int.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 0%] Building CXX object CMakeFiles/bin2cpp.dir/src/backend/common/deterministicHash.cpp.o [ 0%] Linking CXX executable bin2cpp [ 0%] Built target bin2cpp [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_ushort.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 0%] Built target af_glad_obj_lib [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_uchar.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 0%] Building CXX object extern/spdlog-build/CMakeFiles/spdlog.dir/src/stdout_sinks.cpp.o [ 0%] Building CXX object extern/spdlog-build/CMakeFiles/spdlog.dir/src/color_sinks.cpp.o [ 0%] Building CXX object extern/spdlog-build/CMakeFiles/spdlog.dir/src/file_sinks.cpp.o [ 0%] Building CXX object extern/spdlog-build/CMakeFiles/spdlog.dir/src/async.cpp.o [ 0%] Built target cpu_sort_by_key_short [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_uintl.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 0%] Building CXX object extern/spdlog-build/CMakeFiles/spdlog.dir/src/cfg.cpp.o [ 0%] Built target cpu_sort_by_key_double [ 0%] Built target cpu_sort_by_key_char [ 0%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_intl.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 1%] Building CXX object src/backend/cpu/CMakeFiles/cpu_sort_by_key_uint.dir/kernel/sort_by_key/sort_by_key_impl.cpp.o [ 1%] Built target cpu_sort_by_key_int [ 1%] Building CXX object extern/spdlog-build/CMakeFiles/spdlog.dir/src/fmt.cpp.o [ 1%] Built target cpu_sort_by_key_float [ 1%] Creating directories for 'CLBlast-ext' [ 1%] No download step for 'CLBlast-ext' [ 1%] No update step for 'CLBlast-ext' [ 1%] No patch step for 'CLBlast-ext' [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/KParam.hpp to C++ source [ 1%] Performing configure step for 'CLBlast-ext' [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/anisotropic_diffusion.cl to C++ source -- The C compiler identification is AppleClang 15.0.0.15000040 [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/approx1.cl to C++ source -- The CXX compiler identification is AppleClang 15.0.0.15000040 -- Detecting C compiler ABI info [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/approx2.cl to C++ source [ 1%] Built target cpu_sort_by_key_ushort [ 1%] Building CXX object extern/ocl_clfft-build/library/CMakeFiles/clFFT.dir/transform.cpp.o [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/assign.cl to C++ source [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/bilateral.cl to C++ source [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/convolve.cl to C++ source -- Detecting C compiler ABI info - done -- Check for working C compiler: /Library/Developer/CommandLineTools/usr/bin/cc - skipped -- Detecting C compile features -- Detecting C compile features - done -- Detecting CXX compiler ABI info [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/convolve_separable.cl to C++ source [ 1%] Linking CXX shared library libspdlog.dylib [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/coo2dense.cl to C++ source In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/transform.cpp:23: In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:23: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.h:369:28: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions] virtual ~FFTAction() = default; ^ In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/transform.cpp:23: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:52:47: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions] FFTRepoKey(const FFTRepoKey &other) = default; ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:54:31: warning: rvalue references are a C++11 extension [-Wc++11-extensions] FFTRepoKey(FFTRepoKey && other) ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/transform.cpp:125:10: warning: enumeration value 'ENDDIMENSION' not handled in switch [-Wswitch] switch( fftPlan->dim ) ^~~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/transform.cpp:125:10: note: add missing switch cases switch( fftPlan->dim ) ^ [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/copy.cl to C++ source [ 1%] Built target spdlog [ 1%] Built target cpu_sort_by_key_uchar [ 1%] Building C object test/mmio/CMakeFiles/mmio.dir/mmio.c.o [ 1%] Building CXX object extern/googletest-build/googletest/CMakeFiles/gtest.dir/src/gtest-all.cc.o 4 warnings generated. [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/cscmm.cl to C++ source [ 1%] Building CXX object extern/ocl_clfft-build/library/CMakeFiles/clFFT.dir/accessors.cpp.o -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: /Library/Developer/CommandLineTools/usr/bin/c++ - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- Building CLBlast with OpenCL API (default) [ 1%] Linking C static library libmmio.a -- Found OpenCL: /Library/Developer/CommandLineTools/SDKs/MacOSX14.0.sdk/System/Library/Frameworks/OpenCL.framework [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/cscmv.cl to C++ source -- Configuring done (1.3s) -- Generating done (0.0s) -- Build files have been written to: /Users/sfurlan/develop/arrayfire/extern/ocl_clblast-build [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/csr2coo.cl to C++ source [ 1%] Built target mmio [ 1%] Performing build step for 'CLBlast-ext' [ 1%] Building CXX object extern/ocl_clfft-build/library/CMakeFiles/clFFT.dir/plan.cpp.o [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/csr2dense.cl to C++ source [ 1%] Building CXX object CMakeFiles/clblast.dir/src/database/database.cpp.o [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/csrmm.cl to C++ source In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/accessors.cpp:23: In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:23: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.h:369:28: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions] virtual ~FFTAction() = default; ^ In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/accessors.cpp:23: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:52:47: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions] FFTRepoKey(const FFTRepoKey &other) = default; ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:54:31: warning: rvalue references are a C++11 extension [-Wc++11-extensions] FFTRepoKey(FFTRepoKey && other) ^ [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/csrmv.cl to C++ source In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:25: In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:23: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.h:369:28: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions] virtual ~FFTAction() = default; ^ In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:25: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:52:47: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions] FFTRepoKey(const FFTRepoKey &other) = default; ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/repo.h:54:31: warning: rvalue references are a C++11 extension [-Wc++11-extensions] FFTRepoKey(FFTRepoKey && other) ^ In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:27: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/generator.stockham.h:290:6: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations] sprintf(cv, "%036.34lf", wc[nt]); ^ /Library/Developer/CommandLineTools/SDKs/MacOSX14.0.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here __deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.") ^ /Library/Developer/CommandLineTools/SDKs/MacOSX14.0.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'

define deprecated_msg(_msg) attribute((deprecated__(_msg)))

                                                  ^

In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:27: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/generator.stockham.h:291:6: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations] sprintf(sv, "%036.34lf", ws[nt++]); ^ /Library/Developer/CommandLineTools/SDKs/MacOSX14.0.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here __deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.") ^ /Library/Developer/CommandLineTools/SDKs/MacOSX14.0.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'

define deprecated_msg(_msg) attribute((deprecated__(_msg)))

                                                  ^

In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:29: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/action.h:54:13: error: exception specification of overriding function is more lax than base version virtual ~FFTStockhamAction() = default; ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.h:369:13: note: overridden virtual function is here virtual ~FFTAction() = default; ^ In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:29: /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/action.h:54:36: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions] virtual ~FFTStockhamAction() = default; ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/action.h:182:13: error: exception specification of overriding function is more lax than base version virtual ~FFTGeneratedStockhamAction() = default; ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/action.h:54:13: note: overridden virtual function is here virtual ~FFTStockhamAction() = default; ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/action.h:182:45: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions] virtual ~FFTGeneratedStockhamAction() = default; ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:34:43: warning: illegal character encoding in string literal [-Winvalid-source-encoding] const std::string beginning_of_binary( "<[_beginning_ofbinary]>" ); ^~ ~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:35:37: warning: illegal character encoding in string literal [-Winvalid-source-encoding] const std::string end_of_binary( "<[_I_may_be_a_sorry_case,_but_I_don't_write_jokes_in_base13]>" ); ^~ ~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:36:35: warning: illegal character encoding in string literal [-Winvalid-source-encoding] const std::string end_of_file( "<[_You're_off_the_edge_of_the_map,_mate._Here_there_bemonsters]>" ); ^~ ~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:307:10: warning: enumeration value 'ENDDIMENSION' not handled in switch [-Wswitch] switch( dim ) ^~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:307:10: note: add missing switch cases switch( dim ) ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:379:13: warning: enumeration value 'ENDGENERATORS' not handled in switch [-Wswitch] switch( gen ) ^~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:379:13: note: add missing switch cases switch( gen ) ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:487:9: warning: enumeration value 'ENDDIMENSION' not handled in switch [-Wswitch] switch(fftPlan->dim) ^~~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:487:9: note: add missing switch cases switch(fftPlan->dim) ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:568:10: warning: enumeration value 'ENDDIMENSION' not handled in switch [-Wswitch] switch(fftPlan->dim) ^~~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:568:10: note: add missing switch cases switch(fftPlan->dim) ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:631:10: warning: enumeration value 'ENDDIMENSION' not handled in switch [-Wswitch] switch( fftPlan->dim ) ^~~~ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:631:10: note: add missing switch cases switch( fftPlan->dim ) ^ /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:4826:7: warning: comparison of address of 'this->envelope' equal to a null pointer is always false [-Wtautological-pointer-compare] if( &envelope == NULL ) ^~~~ ~~~~ 16 warnings and 2 errors generated. make[2]: [extern/ocl_clfft-build/library/CMakeFiles/clFFT.dir/plan.cpp.o] Error 1 make[2]: Waiting for unfinished jobs.... 3 warnings generated. make[1]: [extern/ocl_clfft-build/library/CMakeFiles/clFFT.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/dense2csr.cl to C++ source [ 2%] Building CXX object CMakeFiles/clblast.dir/src/routines/common.cpp.o [ 1%] Linking C static library libaf_glad.a [ 1%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/diag_create.cl to C++ source [ 1%] Built target af_glad [ 3%] Building CXX object CMakeFiles/clblast.dir/src/utilities/compile.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/diag_extract.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/diff.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/example.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/fast.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/fftconvolve_multiply.cl to C++ source [ 4%] Building CXX object CMakeFiles/clblast.dir/src/utilities/clblast_exceptions.cpp.o [ 6%] Building CXX object CMakeFiles/clblast.dir/src/utilities/timing.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/fftconvolve_pack.cl to C++ source [ 7%] Building CXX object CMakeFiles/clblast.dir/src/utilities/utilities.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/fftconvolve_reorder.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/flood_fill.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/gradient.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/harris.cl to C++ source [ 8%] Building CXX object CMakeFiles/clblast.dir/src/api_common.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/histogram.cl to C++ source [ 9%] Building CXX object CMakeFiles/clblast.dir/src/cache.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/homography.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/hsv_rgb.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/identity.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/iir.cl to C++ source [ 10%] Building CXX object CMakeFiles/clblast.dir/src/kernel_preprocessor.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/index.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/interp.cl to C++ source [ 12%] Building CXX object CMakeFiles/clblast.dir/src/routine.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/iops.cl to C++ source [ 13%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xinvert.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/iota.cl to C++ source [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/ireduce_dim.cl to C++ source [ 2%] Built target cpu_sort_by_key_uintl [ 14%] Building CXX object CMakeFiles/clblast.dir/src/tuning/configurations.cpp.o [ 2%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/ireduce_first.cl to C++ source [ 2%] Built target cpu_sort_by_key_intl [ 15%] Building CXX object CMakeFiles/clblast.dir/src/clblast.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/jit.cl to C++ source [ 3%] Built target cpu_sort_by_key_uint [ 17%] Building CXX object CMakeFiles/clblast.dir/src/clblast_c.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/laset_band.cl to C++ source [ 3%] Linking CXX shared library ../../../lib/libgtest.dylib [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/laset.cl to C++ source [ 18%] Building CXX object CMakeFiles/clblast.dir/src/tuning/tuning_api.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/laswp.cl to C++ source [ 3%] Built target gtest [ 19%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xswap.cpp.o [ 20%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xscal.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/lookup.cl to C++ source [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/lu_split.cl to C++ source [ 21%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xcopy.cpp.o [ 23%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xaxpy.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/matchTemplate.cl to C++ source [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/mean_dim.cl to C++ source [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/mean_first.cl to C++ source [ 24%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xdot.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/mean_ops.cl to C++ source [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/meanshift.cl to C++ source [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/medfilt1.cl to C++ source [ 25%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xdotu.cpp.o [ 26%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xdotc.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/medfilt2.cl to C++ source [ 28%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xnrm2.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/memcopy.cl to C++ source [ 29%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xasum.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/moments.cl to C++ source [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/morph.cl to C++ source [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/nearest_neighbour.cl to C++ source [ 30%] Building CXX object CMakeFiles/clblast.dir/src/routines/level1/xamax.cpp.o [ 31%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xgemv.cpp.o [ 32%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xgbmv.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/nonmax_suppression.cl to C++ source [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/ops.cl to C++ source [ 34%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xhemv.cpp.o [ 3%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/orb.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/pad_array_borders.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/random_engine_mersenne.cl to C++ source [ 35%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xhbmv.cpp.o [ 36%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xhpmv.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/random_engine_mersenne_init.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/random_engine_philox.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/random_engine_threefry.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/random_engine_write.cl to C++ source [ 37%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xsymv.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/range.cl to C++ source [ 39%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xsbmv.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_all.cl to C++ source [ 40%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xspmv.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_blocks_by_key_dim.cl to C++ source [ 41%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xtrmv.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_blocks_by_key_first.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_by_key_boundary.cl to C++ source [ 42%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xtbmv.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_by_key_boundary_dim.cl to C++ source [ 43%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xtpmv.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_by_key_compact.cl to C++ source [ 45%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xtrsv.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_by_key_compact_dim.cl to C++ source [ 46%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xger.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_dim.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_by_key_needs_reduction.cl to C++ source [ 47%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xgeru.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reduce_first.cl to C++ source [ 48%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xgerc.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/regions.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/reorder.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/resize.cl to C++ source [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/rotate.cl to C++ source [ 50%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xher.cpp.o [ 51%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xhpr.cpp.o [ 4%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/scan_dim_by_key.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/scan_dim.cl to C++ source [ 52%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xher2.cpp.o [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/scan_first_by_key.cl to C++ source [ 53%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xhpr2.cpp.o [ 54%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xsyr.cpp.o [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/scan_first.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/select.cl to C++ source [ 56%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xspr.cpp.o [ 57%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xsyr2.cpp.o [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/sift_nonfree.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/sobel.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/sparse_arith_common.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/sparse_arith_coo.cl to C++ source [ 58%] Building CXX object CMakeFiles/clblast.dir/src/routines/level2/xspr2.cpp.o [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/sparse_arith_csr.cl to C++ source [ 59%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xgemm.cpp.o [ 60%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xsymm.cpp.o [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/sp_sp_arith_csr.cl to C++ source [ 62%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xhemm.cpp.o [ 63%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xsyrk.cpp.o [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/ssarith_calc_out_nnz.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/susan.cl to C++ source [ 64%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xherk.cpp.o [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/swapdblk.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/tile.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/trace_edge.cl to C++ source [ 65%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xsyr2k.cpp.o [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/transform.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/transpose.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/transpose_inplace.cl to C++ source [ 5%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/triangle.cl to C++ source [ 6%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/unwrap.cl to C++ source [ 67%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xher2k.cpp.o [ 6%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/where.cl to C++ source [ 6%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/wrap.cl to C++ source [ 68%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xtrmm.cpp.o [ 6%] Compiling /Users/sfurlan/develop/arrayfire/src/backend/opencl/kernel/wrap_dilated.cl to C++ source [ 69%] Building CXX object CMakeFiles/clblast.dir/src/routines/level3/xtrsm.cpp.o [ 6%] Built target arrayfire_opencl_kernel_headers_bin_target [ 70%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xhad.cpp.o [ 71%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xomatcopy.cpp.o [ 73%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xim2col.cpp.o [ 74%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xcol2im.cpp.o [ 75%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xconvgemm.cpp.o [ 76%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xaxpybatched.cpp.o [ 78%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xgemmbatched.cpp.o [ 79%] Building CXX object CMakeFiles/clblast.dir/src/routines/levelx/xgemmstridedbatched.cpp.o [ 80%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/copy/copy.cpp.o [ 81%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/pad/pad.cpp.o [ 82%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/padtranspose/padtranspose.cpp.o [ 84%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/transpose/transpose.cpp.o [ 85%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xaxpy/xaxpy.cpp.o [ 86%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xdot/xdot.cpp.o [ 87%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xgemm/xgemm.cpp.o [ 89%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xgemm_direct/xgemm_direct.cpp.o [ 90%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xgemv/xgemv.cpp.o [ 91%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xgemv_fast/xgemv_fast.cpp.o [ 92%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xgemv_fast_rot/xgemv_fast_rot.cpp.o [ 93%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xger/xger.cpp.o [ 95%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/invert/invert.cpp.o [ 96%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/gemm_routine/gemm_routine.cpp.o [ 97%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/trsv_routine/trsv_routine.cpp.o [ 98%] Building CXX object CMakeFiles/clblast.dir/src/database/kernels/xconvgemm/xconvgemm.cpp.o [100%] Linking CXX static library libclblast.a [100%] Built target clblast [ 6%] Performing install step for 'CLBlast-ext' [100%] Built target clblast Install the project... -- Install configuration: "Release" -- Installing: /Users/sfurlan/develop/arrayfire/extern/ocl_clblast-build/pkg/lib/libclblast.a -- Installing: /Users/sfurlan/develop/arrayfire/extern/ocl_clblast-build/pkg/include/clblast_half.h -- Installing: /Users/sfurlan/develop/arrayfire/extern/ocl_clblast-build/pkg/include/clblast.h -- Installing: /Users/sfurlan/develop/arrayfire/extern/ocl_clblast-build/pkg/include/clblast_c.h -- Installing: /Users/sfurlan/develop/arrayfire/extern/ocl_clblast-build/pkg/lib/cmake/CLBlast/CLBlastConfig.cmake -- Installing: /Users/sfurlan/develop/arrayfire/extern/ocl_clblast-build/pkg/lib/cmake/CLBlast/CLBlastConfig-release.cmake -- Installing: /Users/sfurlan/develop/arrayfire/extern/ocl_clblast-build/pkg/lib/pkgconfig/clblast.pc [ 6%] Completed 'CLBlast-ext' [ 6%] Built target CLBlast-ext make: *** [all] Error 2

Any help would be greatly appreciated!

lwabeke commented 10 months ago
mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DAF_BUILD_CUDA=OFF -DAF_BUILD_OPENCL=ON -DCMAKE_INSTALL_PREFIX=/opt/arrayfire
cd ..
make -j8

I am a bit confused, why after running cmake in the build folder, do you run make in the top level folder? If that isn't a typo, you are running make on a different Makefile than the one that cmake generated

Also maybe run make without the -j8 to run it single threaded to easier see where the error occurs. It is a bit confusing that it completes and does an installl, but still errors. Earlier messages all seem to be warnings, but maybe I am missing something.

scfurl commented 10 months ago
mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DAF_BUILD_CUDA=OFF -DAF_BUILD_OPENCL=ON -DCMAKE_INSTALL_PREFIX=/opt/arrayfire
cd ..
make -j8

I am a bit confused, why after running cmake in the build folder, do you run make in the top level folder? If that isn't a typo, you are running make on a different Makefile than the one that cmake generated

Also maybe run make without the -j8 to run it single threaded to easier see where the error occurs. It is a bit confusing that it completes and does an installl, but still errors. Earlier messages all seem to be warnings, but maybe I am missing something.

Thanks @lwabeke. I admittedly was confused as well. The build folder was actually empty and the last few lines of the cmake output (pasted below) suggested that it was build in the top level folder which is why I went up a level before making

-- Configuring done (9.4s)
-- Generating done (2.0s)
-- Build files have been written to: /Users/sfurlan/develop/arrayfire

As you suggested I ran without parallelism... Here is the output of the last few lines

16 warnings and 2 errors generated.
make[2]: *** [extern/ocl_clfft-build/library/CMakeFiles/clFFT.dir/plan.cpp.o] Error 1
make[1]: *** [extern/ocl_clfft-build/library/CMakeFiles/clFFT.dir/all] Error 2
make: *** [all] Error 2

I grafted more details about the errors below

/Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/action.h:54:13: error: exception specification of overriding function is more lax than base version
    virtual ~FFTStockhamAction() = default;
            ^
/Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.h:369:13: note: overridden virtual function is here
    virtual ~FFTAction() = default;
            ^
In file included from /Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/plan.cpp:29:
/Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/action.h:54:36: warning: defaulted function definitions are a C++11 extension [-Wc++11-extensions]
    virtual ~FFTStockhamAction() = default;
                                   ^
/Users/sfurlan/develop/arrayfire/extern/ocl_clfft-src/src/library/action.h:182:13: error: exception specification of overriding function is more lax than base version
    virtual ~FFTGeneratedStockhamAction() = default;
            ^

Any ideas?

edwinsolisf commented 1 month ago

From the looks of the output @scfurl got, there seems to be a configuration with c++ version being used to build the ocl-clfft library causing the errors virtual destructors. Try to look in the cmake configuration or cache for the c++ version being used.

Has there been any progress in the meantime?