cmu-db / noisepage

Self-Driving Database Management System from Carnegie Mellon University
https://noise.page
MIT License
1.74k stars 500 forks source link

Failed to run command ninja noisepage #1533

Closed CraneXHu closed 3 years ago

CraneXHu commented 3 years ago

Bug Report

Summary

Failed to run command ninja noisepage.

Build failed message /usr/lib/gcc/x86_64-linux-gnu/10/include/bmi2intrin.h:69:1: error: inlining failed in call to ‘always_inline’ ‘long long unsigned int _pdep_u64(long long unsigned int, long long unsigned int)’: target specific option mismatch

Environment

OS: VM Ubuntu (LTS) 20.04.

Compiler: GCC 10.

mbutrovich commented 3 years ago

Can you provide full CMake output? Note that we don't officially support GCC 10 since the default with 20.04 LTS is still 9.x. Last I heard, however, we did compile with GCC 10.

CraneXHu commented 3 years ago
  1. CMake output
    
    -- The CXX compiler identification is GNU 10.2.0
    -- Check for working CXX compiler: /usr/bin/c++
    -- Check for working CXX compiler: /usr/bin/c++ -- works
    -- Detecting CXX compiler ABI info
    -- Detecting CXX compiler ABI info - done
    -- Detecting CXX compile features
    -- Detecting CXX compile features - done
    -- Welcome to NoisePage!
        Home Page: https://noise.page/
        Version: 1.0.0.0

-- Compiler: /usr/bin/c++ GNU 10.2.0 -- System: Linux 5.8.0-48-generic x86_64 -- System NUMBER_OF_LOGICAL_CORES;NUMBER_OF_PHYSICAL_CORES: 1;1 -- System HOSTNAME;FQDN: ubuntu;ubuntu -- System AVAILABLE_VIRTUAL_MEMORY;TOTAL_VIRTUAL_MEMORY: 914;923 -- System AVAILABLE_PHYSICAL_MEMORY;TOTAL_PHYSICAL_MEMORY: 1080;1958 -- System IS_64BIT;HAS_IA64: 1;0 -- System HAS_FPU;HAS_MMX;HAS_MMX_PLUS: 1;1;0 -- System HAS_SSE;HAS_SSE2;HAS_SSE_FP;HAS_SSE_MMX: 1;1;0;0 -- System HAS_AMD_3DNOW;HAS_AMD_3DNOW_PLUS: 0;0 -- System HAS_SERIAL_NUMBER;PROCESSOR_SERIAL_NUMBER: 0; -- System PROCESSOR_NAME;PROCESSOR_DESCRIPTION: Unknown P6 family;1 core Intel(R) Core(TM) i3-2330M CPU @ 2.20GHz -- System OS_NAME;OS_RELEASE;OS_VERSION;OS_PLATFORM: Linux;5.8.0-48-generic;#54~20.04.1-Ubuntu SMP Sat Mar 20 13:40:25 UTC 2021;x86_64 -- CMAKE_BUILD_TYPE: RELEASE -- Coverage: OFF -- ASAN: OFF -- jemalloc: On (dir:/usr/include lib:/usr/lib/x86_64-linux-gnu/libjemalloc.so) -- Logging: ON -- Verbose unit tests (NOISEPAGE_UNITTEST_OUTPUT_ON_FAILURE): OFF -- Unity builds (NOISEPAGE_UNITY_BUILD): ON -- Test max parallelism: 1 tests at a time. -- Linker: Will pass "-fuse-ld=lld" to linker. -- Shared targets: Available. -- Tests: Will use dynamic linking. -- Colorized output: ON (-fdiagnostics-color=always) -- Ninja detected. Global pools: link=1 compile=-1 -- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.1") -- Dependencies: Locating...

-- Third-party CMAKE_BUILD_TYPE: Release -- Third-party CMAKE_C_FLAGS: -fPIC -- Third-party CMAKE_CXX_FLAGS: -fPIC -- [FOUND] csv (https://raw.githubusercontent.com/vincentlaucsb/csv-parser/92694230ba4863a436b6533788e590fce70b5f44/single_include/csv.hpp) -- [FOUND] portable_endian (https://gist.githubusercontent.com/panzi/6856583/raw/1eca2ab34f2301b9641aa73d1016b951fff3fc39/portable_endian.h) -- [FOUND] count (https://github.com/pmenon/libcount.git 6eef9d048d4577f144506ffc076c1913f8faf3ef 2019-09-14) -- [FOUND] cppzmq (https://github.com/zeromq/cppzmq.git v4.7.1 2020-10-05) -- [FOUND] gflags (https://github.com/gflags/gflags.git v2.2.2 2018-11-11) -- [FOUND] googlebenchmark (https://github.com/google/benchmark.git v1.5.2 2020-09-11) -- [FOUND] googletest (https://github.com/google/googletest.git release-1.10.0 2019-10-03) -- Copied /home/cranehu/Documents/noisepage/third_party/deps_override/ips4o_CMakeLists.txt -> /home/cranehu/Documents/noisepage/build/_deps/src/ips4o/CMakeLists.txt. -- [FOUND] ips4o (https://github.com/ips4o/ips4o.git 2fb65ca11ac1898faee2f146610e6409489d2105 2020-08-27) -- Copied /home/cranehu/Documents/noisepage/third_party/deps_override/madoka_CMakeLists.txt -> /home/cranehu/Documents/noisepage/build/_deps/src/madoka/CMakeLists.txt. -- [FOUND] madoka (https://github.com/s-yata/madoka.git 66783ee5b84a432f934517ad65452d54b19230bb 2018-11-17) -- [FOUND] nlohmann_json (https://github.com/ArthurSonzogni/nlohmann_json_cmake_fetchcontent.git v3.7.3 2020-06-28) -- [FOUND] spdlog (https://github.com/gabime/spdlog.git v1.8.1 2020-09-30) -- Copied /home/cranehu/Documents/noisepage/third_party/deps_override/xbyak_CMakeLists.txt -> /home/cranehu/Documents/noisepage/build/_deps/src/xbyak/CMakeLists.txt. -- [FOUND] xbyak (https://github.com/herumi/xbyak.git v5.77 2019-03-06) -- Copied /home/cranehu/Documents/noisepage/third_party/deps_override/xxHash_CMakeLists.txt -> /home/cranehu/Documents/noisepage/build/_deps/src/xxHash/CMakeLists.txt. -- [FOUND] xxHash (https://github.com/Cyan4973/xxHash.git v0.8.0 2020-07-27) -- [FOUND] fast_float (https://github.com/lemire/fast_float.git v1.0.0 2021-03-17) -- [FOUND] pqxx (dir:/usr/include lib:/usr/lib/x86_64-linux-gnu/libpqxx.so) -- Checking for one of the modules 'libevent' -- Checking for one of the modules 'libevent_pthreads' -- [FOUND] LLVM 8.0.1 -- Found TBB: /usr/include (found version "2020.1")
-- [FOUND] TBB 2020.1 --

Dependencies: All found!

-- Note that following NoisePage options are just a sample and may not be the full list. Check compile_commands.json to be sure. -- noisepage_objlib COMPILE_DEFINITIONS: NDEBUG;NOISEPAGE_USE_LOGGING -- noisepage_objlib COMPILE_FEATURES: cxx_std_17 -- noisepage_objlib COMPILE_OPTIONS: -Werror;-Wall;-march=native;-mcx16;-O3;-fdiagnostics-color=always -- noisepage_objlib LINK_OPTIONS: -fuse-ld=lld -- noisepage_objlib LINK_LIBRARIES: count;cppzmq;fast_float;gflags;ips4o::ips4o;madoka::madoka;nlohmann_json::nlohmann_json;pg_query::pg_query;xbyak::xbyak;xxHash::xxhash;/home/cranehu/Documents/noisepage/build/_deps/build/spdlog/libspdlog.a;/usr/lib/x86_64-linux-gnu/libevent.so;/usr/lib/x86_64-linux-gnu/libevent_pthreads.so;/usr/lib/x86_64-linux-gnu/libevent.so;/usr/lib/x86_64-linux-gnu/libjemalloc.so;/usr/lib/x86_64-linux-gnu/libpqxx.so;LLVMCore;LLVMipo;LLVMMCJIT;LLVMX86CodeGen;LLVMX86Desc;LLVMX86Info;LLVMSupport;LLVMX86CodeGen;LLVMX86AsmParser;LLVMX86AsmPrinter;LLVMX86Desc;LLVMX86Disassembler;LLVMX86Info;LLVMX86Utils;/usr/lib/x86_64-linux-gnu/libtbb.so -- noisepage COMPILE_OPTIONS: -Werror;-Wall -- noisepage LINK_LIBRARIES: noisepage_static -- tpl COMPILE_OPTIONS: -Werror;-Wall -- tpl LINK_LIBRARIES: noisepage_static;util_static -- noisepage_test_util_static COMPILE_DEFINITIONS: NOISEPAGE_BUILD_ROOT=/home/cranehu/Documents/noisepage/build -- noisepage_test_util_static COMPILE_OPTIONS: -Werror;-Wall -- noisepage_test_util_static LINK_LIBRARIES: /home/cranehu/Documents/noisepage/build/lib/libgtest.a;/home/cranehu/Documents/noisepage/build/lib/libgmock.a;util_static;pqxx -- tpcc_test COMPILE_OPTIONS: -Werror;-Wall;-fvisibility=hidden -- tpcc_test LINK_LIBRARIES: /home/cranehu/Documents/noisepage/build/lib/libgmock_main.a;noisepage_test_util_shared -- noisepage_benchmark_util COMPILE_OPTIONS: -Werror;-Wall -- noisepage_benchmark_util LINK_LIBRARIES: /home/cranehu/Documents/noisepage/build/lib/libgmock_main.a;noisepage_test_util_static;benchmark -- tpcc_benchmark COMPILE_OPTIONS: -Werror;-Wall -- tpcc_benchmark LINK_LIBRARIES: noisepage_benchmark_util -- [ADDED] check-censored -- [FOUND] cpplint (https://raw.githubusercontent.com/cpplint/cpplint/5b4259ef4c94d34e98192f53466c8af5e9d1c259/cpplint.py) -- [ADDED] check-lint (/home/cranehu/Documents/noisepage/build/_deps/src/cpplint/cpplint.py) -- [ADDED] check-tpl -- [ADDED] clang-format and check-clang-format (/usr/bin/clang-format-8) -- [ADDED] check-clang-tidy (/usr/bin/clang-tidy-8) -- Configuring done -- Generating done -- Build files have been written to: /home/cranehu/Documents/noisepage/build

2. run ninja noisepage

ninja: error: rules.ninja:21: invalid pool depth depth = 4294967295

I set depth to 4, there is no problem.

3. run ninja noisepage again

[0/2] Re-checking globbed directories... [3/118] Building CXX object CMakeFiles...ge_objlib.dir/Unity/unity_39_cxx.cxx.o FAILED: CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx.o /usr/bin/c++ -DGFLAGS_IS_A_DLL=0 -DNDEBUG -DNOISEPAGE_USE_LOGGING -I../src/include -I_deps/src/count/count/../include -I_deps/src/cppzmq -I_deps/build/gflags/include -I_deps/src/ips4o/ips4o -I_deps/src/ips4o -I_deps/src/madoka -I_deps/src/nlohmann_json/include -I_deps/src/xbyak -isystem /usr/lib/llvm-8/include -isystem _deps/src -isystem _deps/src/spdlog/include -isystem _deps/src/fast_float/include -isystem /usr/include/pgm-5.2 -isystem ../third_party/libpg_query/../src/postgres/include -isystem ../third_party/libpg_query/.. -O3 -DNDEBUG -fPIC -Werror -Wall -march=native -mcx16 -O3 -fdiagnostics-color=always -std=c++17 -MD -MT CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx.o -MF CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx.o.d -o CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx.o -c CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx In file included from /usr/lib/gcc/x86_64-linux-gnu/10/include/immintrin.h:109, from /usr/lib/gcc/x86_64-linux-gnu/10/include/x86intrin.h:32, from ../src/include/common/hash_util.h:3, from ../src/include/storage/storage_defs.h:15, from ../src/include/storage/storage_util.h:9, from ../src/include/storage/projected_row.h:8, from /home/cranehu/Documents/noisepage/src/storage/projected_row.cpp:1, from CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx:3: /usr/lib/gcc/x86_64-linux-gnu/10/include/bmi2intrin.h: In member function ‘uint32_t noisepage::execution::util::BitVector<WordType, Allocator>::NthOne(uint32_t) const [with WordType = long unsigned int; Allocator = std::allocator]’: /usr/lib/gcc/x86_64-linux-gnu/10/include/bmi2intrin.h:69:1: error: inlining failed in call to ‘always_inline’ ‘long long unsigned int _pdep_u64(long long unsigned int, long long unsigned int)’: target specific option mismatch 69 | _pdep_u64 (unsigned long long X, unsigned long long Y) | ^~~~~ In file included from ../src/include/execution/sql/tuple_id_list.h:9, from ../src/include/execution/sql/vector_projection.h:11, from /home/cranehu/Documents/noisepage/src/storage/storage_util.cpp:8, from CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx:9: ../src/include/execution/util/bit_vector.h:357:40: note: called from here 357 | const WordType mask = _pdep_u64(static_cast(1) << n, word); | ~~~^~~~~~~~~~~ In file included from /usr/lib/gcc/x86_64-linux-gnu/10/include/immintrin.h:109, from /usr/lib/gcc/x86_64-linux-gnu/10/include/x86intrin.h:32, from ../src/include/common/hash_util.h:3, from ../src/include/storage/storage_defs.h:15, from ../src/include/storage/storage_util.h:9, from ../src/include/storage/projected_row.h:8, from /home/cranehu/Documents/noisepage/src/storage/projected_row.cpp:1, from CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx:3: /usr/lib/gcc/x86_64-linux-gnu/10/include/bmi2intrin.h:69:1: error: inlining failed in call to ‘always_inline’ ‘long long unsigned int _pdep_u64(long long unsigned int, long long unsigned int)’: target specific option mismatch 69 | _pdep_u64 (unsigned long long X, unsigned long long Y) | ^~~~~ In file included from ../src/include/execution/sql/tuple_id_list.h:9, from ../src/include/execution/sql/vector_projection.h:11, from /home/cranehu/Documents/noisepage/src/storage/storage_util.cpp:8, from CMakeFiles/noisepage_objlib.dir/Unity/unity_39_cxx.cxx:9: ../src/include/execution/util/bit_vector.h:357:40: note: called from here 357 | const WordType mask = _pdep_u64(static_cast(1) << n, word); | ~~~^~~~~~~~~~~ [4/118] Building CXX object CMakeFiles...ge_objlib.dir/Unity/unity_38_cxx.cxx.o ninja: build stopped: subcommand failed.

mbutrovich commented 3 years ago

Since it's failing in x86intrin.h and the CPU is an i3-2330M (Sandy Bridge) I'm going to guess that system will not work to build NoisePage. We generally require Haswell or newer to compile since we use AVX2 instructions.