Skip to content

Compile Error With GCC 13.2.1 #6

@Hexancer

Description

@Hexancer
In file included from /home/yyp/dLSM/./table/format.h:14,
                 from /home/yyp/dLSM/include/dLSM/options.h:11,
                 from /home/yyp/dLSM/include/dLSM/db.h:13,
                 from /home/yyp/dLSM/./db/dbformat.h:13,
                 from /home/yyp/dLSM/./db/builder.h:8,
                 from /home/yyp/dLSM/db/builder.cc:5:
/home/yyp/dLSM/./util/rdma.h: In constructor ‘dLSM::In_Use_Array::In_Use_Array(size_t, size_t, ibv_mr*, std::atomic<bool>*)’:
/home/yyp/dLSM/./util/rdma.h:215:35: warning: unused parameter ‘in_use’ [-Wunused-parameter]
  215 |                std::atomic<bool>* in_use)
      |                ~~~~~~~~~~~~~~~~~~~^~~~~~
/home/yyp/dLSM/./util/rdma.h: In member function ‘bool dLSM::In_Use_Array::deallocate_memory_slot(int)’:
/home/yyp/dLSM/./util/rdma.h:234:15: warning: comparison of integer expressions of different signedness: ‘int’ and ‘size_t’ {aka ‘long unsigned int’} [-Wsign-compare]
  234 |     if (index < element_size_){
      |         ~~~~~~^~~~~~~~~~~~~~~
/home/yyp/dLSM/./util/rdma.h: At global scope:
/home/yyp/dLSM/./util/rdma.h:476:26: error: ‘condition_variable’ is not a member of ‘std’
  476 |   std::map<uint8_t, std::condition_variable*> dealloc_cv;
      |                          ^~~~~~~~~~~~~~~~~~
/home/yyp/dLSM/./util/rdma.h:38:1: note: ‘std::condition_variable’ is defined in header ‘<condition_variable>’; did you forget to ‘#include <condition_variable>’?
   37 | #include <list>
  +++ |+#include <condition_variable>

When compiling with GCC, it is necessary to add the header file

#include <condition_variable> 

in ./util/rdma.h.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions