Giter VIP home page Giter VIP logo

krcore-artifacts's Introduction

KRCore: rust-based communication library for using RDMA

KRCore has two parts. The first is a rust-based library for using RDMA, i.e., by adding high-level abstractions to low-level RDMA libraries (ibverbs). The second is a kernel-space component to provide fast user-space RDMA-capable connection setup, which builds on the first part.

[TOC]

Rust-based RDMA library

Crate location: ./KRdmaKit.

This library provides the following functionalities:

  1. Simplify building RDMA-based applications with rust.
  2. Using rust to manage all the (local) lifecycles of RDMA resources (e.g., QP) in a safe and transparent way.
  3. A unified codebase to build RDMA-enabled applications both in the kernel-space and user-space.

See the quickstart doc for how to use it in the user space!


Kernel-space support for fast RDMA connections

Crate location: ./KRdmaKit-syscall.

The second is a kernel-space component to provide fast user-space RDMA-capable connection setup. For details, please refer to our USENIX ATC 2022 paper: https://www.usenix.org/conference/atc22/presentation/wei .

To use this part or re-produce evaluations in our paper, please go to https://github.com/SJTU-IPADS/krcore-artifacts/tree/atc22-artifacts, or git checkout atc22-artifacts.

Please refer to install.md for the environment setup and exp.md for the evaluations. All documents can be found in the doc directory of the artifact.

Since KRCore is a kernel-space solution with RDMA, we should first build KRCore from source at the machines involved in the evaluations. Afterward, we provide scripts so that all the evaluations can be done on a single controller machine.

Roadmap

  • support user-space RDMA programs with the same KRdmaKit crate
  • build more utilities (e.g., reliable messaging over UD) atop of KRCore
  • revise system call layer to the new KRdmaKit API
  • support cross-communication between user and kernel


If you use KRCore in your research, please kindly cite our paper:

@inproceedings {krcoreatc22, author = {Xingda Wei and Fangming Lu and Rong Chen and Haibo Chen}, title = {{KRCORE}: A Microsecond-scale {RDMA} Control Plane for Elastic Computing}, booktitle = {2022 USENIX Annual Technical Conference (USENIX ATC 22)}, year = {2022}, isbn = {978-1-939133-29-42}, address = {Carlsbad, CA}, pages = {121--136}, url = {https://www.usenix.org/conference/atc22/presentation/wei}, publisher = {USENIX Association}, month = jul, }

Getting Started Instructions for the Performance evaluations

Overview of roles of machines involved in the evaluations

At high-level, we need one machine to be KRCore server (that serves RDMA control path and data path operations), a varied number of machines to be KRCore clients (that issues RDMA control path and data path operations to the server), and one controller machine that conduct experiments by issuing commands to the clients and server. The server and clients should connect with RDMA. The controller can be any machine that can establish ssh connections to the clients and server.

Except for building KRCore dependncies at clients and servers, all AE can be finished via scripts at the controller.

To get started, please first select a controller machine (e.g., your laptop or a PC in the lab).

At the controller. clone the repo to some directory (/path/to/krcore) and export it:

git clone https://github.com/SJTU-IPADS/krcore-artifacts.git
export PROJECT_PATH=/path/to/krcore

At the controller. Then fetch the third-party dependencies.

cd ${PROJECT_PATH}
sh git_init.sh

At the controller. Then synchronize all the files to all the hosts* of clients and server. We have prepread a sync script (rsync.sh) shown below that you can use for the synchronization.

user="your_user_name"
target=("host1" "host2") ## all the client and server hosts
path="./krdmakit"

for machine in ${target[*]}
do
  rsync -i -rtuv \
        $PWD/deps \
        $PWD/KRdmaKit-syscall \
        $PWD/rust-kernel-rdma \
        $PWD/krdmakit-macros  \
        $PWD/testlib \
        $PWD/include \
        $PWD/mlnx-ofed-4.9-driver \
        $PWD/exp \
        $user@$machine:/home/${user}/${path} \

done

Important!!! Please ensure each host of the clients and server has the same login username and password (i.e. user="test_user", pwd="my_pwd" for each host). Also, the path of the KRCore base is the same at all of them. For example, in the above rsync.sh, all the KRCore code are synchronized to /home/${USER}/projects/krdmakit at the clients and server.

Afterwards, please go to the next section for installing KRCore on a specific host.

Build & Install KRCore on the server and clients

See install.md (in ${PROJECT_PATH}/doc)for installing KRCore on a single machine. All the hosts involved should follow the same steps.

After finish the install instructions in install.md on all the involved servers, we can now start to reproduce results of KRCore shown below.

kick-the-tires

If Check if the configuration is correct in Run Experiments of exp.md passes, then everything will be fine. Please refer to exp.md for more details.

Key results and claims

There are three key results of the evaluations of the paper:

  1. KRCore can significantly improve the performance of RDMA control path (compared with verbs), e.g., 1000X+ higher throughput.

    Corresponding paper figures: Figure 8a

  2. KRCore have a comparable RDMA data path performance (compared with verbs) for common RDMA operations, e.g., one-sided RDMA and two-sided RDMA.

    Corresponding paper figures: Figure 10-11

  3. KRCore can improve the application (RaceHashing) bootstrap time when starting and connecting new nodes for the computation.

    Corresponding paper figures: Figure 14

We focus on the reproducing of these figures---others are similar in principle (or is less relevant to the key results), but is challenging for automatic reproduction due to configuration issues. For how to reproduce the key result figures, please refer to the next section.

Instructions for re-producing results

See exp.md for more information. (in ${PROJECT_PATH})

krcore-artifacts's People

Contributors

caribouw avatar gahow avatar grizzz13 avatar projectmitosisos avatar wangtianxia-sjtu avatar wxdwfc avatar xiehongrui avatar yangfisher1 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

krcore-artifacts's Issues

Build and run examples error in user space

Follow the install doc, I have installed cargo with version:

cargo 1.68.0-nightly (8c460b223 2023-01-04)
release: 1.68.0-nightly
commit-hash: 8c460b2237a6359a7e3335890db8da049bdd62fc
commit-date: 2023-01-04
host: x86_64-unknown-linux-gnu
libgit2: 1.5.0 (sys:0.15.0 vendored)
libcurl: 7.86.0-DEV (sys:0.4.59+curl-7.86.0 vendored ssl:OpenSSL/1.1.1q)
os: Ubuntu 18.04 (bionic) [64-bit]

But when I run cargo test --features user in folder KRdamKit, I get compile error:

error[E0425]: cannot find function `mmap` in this scope
   --> src/memory_region.rs:142:13
    |
142 |             mmap(
    |             ^^^^ not found in this scope
    |
help: consider importing this function
    |
2   | use libc::mmap;
    |

error[E0425]: cannot find function `null_mut` in this scope
   --> src/memory_region.rs:143:17
    |
143 |                 null_mut(),
    |                 ^^^^^^^^ not found in this scope
    |
help: consider importing one of these items
    |
2   | use core::ptr::null_mut;
    |
2   | use serde::__private::ptr::null_mut;
    |
2   | use std::ptr::null_mut;
    |

error[E0412]: cannot find type `size_t` in this scope
   --> src/memory_region.rs:144:29
    |
144 |                 capacity as size_t,
    |                             ^^^^^^ not found in this scope
    |
help: consider importing this type alias
    |
2   | use libc::size_t;
    |

error[E0425]: cannot find value `PROT_READ` in this scope
   --> src/memory_region.rs:145:17
    |
145 |                 PROT_READ | PROT_WRITE,
    |                 ^^^^^^^^^ not found in this scope
    |
help: consider importing this constant
    |
2   | use libc::PROT_READ;
    |

error[E0425]: cannot find value `PROT_WRITE` in this scope
   --> src/memory_region.rs:145:29
    |
145 |                 PROT_READ | PROT_WRITE,
    |                             ^^^^^^^^^^ not found in this scope
    |
help: consider importing this constant
    |
2   | use libc::PROT_WRITE;
    |

error[E0425]: cannot find value `MAP_PRIVATE` in this scope
   --> src/memory_region.rs:146:17
    |
146 |                 MAP_PRIVATE | MAP_ANONYMOUS | MAP_POPULATE | MAP_HUGETLB,
    |                 ^^^^^^^^^^^ not found in this scope
    |
help: consider importing this constant
    |
2   | use libc::MAP_PRIVATE;
    |

error[E0425]: cannot find value `MAP_ANONYMOUS` in this scope
   --> src/memory_region.rs:146:31
    |
146 |                 MAP_PRIVATE | MAP_ANONYMOUS | MAP_POPULATE | MAP_HUGETLB,
    |                               ^^^^^^^^^^^^^ not found in this scope
    |
help: consider importing this constant
    |
2   | use libc::MAP_ANONYMOUS;
    |

error[E0425]: cannot find value `MAP_POPULATE` in this scope
   --> src/memory_region.rs:146:47
    |
146 |                 MAP_PRIVATE | MAP_ANONYMOUS | MAP_POPULATE | MAP_HUGETLB,
    |                                               ^^^^^^^^^^^^ not found in this scope
    |
help: consider importing this constant
    |
2   | use libc::MAP_POPULATE;
    |

error[E0425]: cannot find value `MAP_HUGETLB` in this scope
   --> src/memory_region.rs:146:62
    |
146 |                 MAP_PRIVATE | MAP_ANONYMOUS | MAP_POPULATE | MAP_HUGETLB,
    |                                                              ^^^^^^^^^^^ not found in this scope
    |
help: consider importing this constant
    |
2   | use libc::MAP_HUGETLB;
    |

error[E0425]: cannot find value `MAP_FAILED` in this scope
   --> src/memory_region.rs:152:20
    |
152 |         if data == MAP_FAILED {
    |                    ^^^^^^^^^^ not found in this scope
    |
help: consider importing this constant
    |
2   | use libc::MAP_FAILED;
    |

error[E0425]: cannot find function `munmap` in this scope
   --> src/memory_region.rs:313:26
    |
313 |                 unsafe { munmap(self.data, self.capacity) };
    |                          ^^^^^^ not found in this scope
    |
help: consider importing this function
    |
2   | use libc::munmap;
    |

Then I follow the hints to add

use libc::mmap;
use core::ptr::null_mut;
use libc::size_t;
use libc::PROT_READ;
use libc::PROT_WRITE;
use libc::MAP_PRIVATE;
use libc::MAP_ANONYMOUS;
use libc::MAP_POPULATE;
use libc::MAP_HUGETLB;
use libc::MAP_FAILED;
use libc::munmap;

in KRdmaKit/src/memory_region.rs. But I still get error:

error[E0308]: mismatched types
   --> src/queue_pairs/doorbell_helper.rs:217:54
    |
217 |             self.send_doorbell.cur_wr().send_flags = send_flag;
    |             --------------------------------------   ^^^^^^^^^ expected `u32`, found `i32`
    |             |
    |             expected due to the type of this binding

error[E0308]: mismatched types
   --> src/queue_pairs/doorbell_helper.rs:260:54
    |
260 |             self.send_doorbell.cur_wr().send_flags = send_flag;
    |             --------------------------------------   ^^^^^^^^^ expected `u32`, found `i32`
    |             |
    |             expected due to the type of this binding

error[E0609]: no field `imm_data` on type `&mut rdma_shim::bindings::ibv_send_wr`
   --> src/queue_pairs/./operations_user.rs:124:24
    |
124 |                     wr.imm_data = imm.unwrap()
    |                        ^^^^^^^^ unknown field
    |
    = note: available fields are: `wr_id`, `next`, `sg_list`, `num_sge`, `opcode` ... and 5 others
help: one of the expressions' fields has a field of the same name
    |
124 |                     wr.__bindgen_anon_1.imm_data = imm.unwrap()
    |                        +++++++++++++++++

error[E0609]: no field `imm_data` on type `rdma_shim::bindings::ibv_send_wr`
   --> src/queue_pairs/./operations_user.rs:188:20
    |
188 |                 wr.imm_data = imm_data.unwrap()
    |                    ^^^^^^^^ unknown field
    |
    = note: available fields are: `wr_id`, `next`, `sg_list`, `num_sge`, `opcode` ... and 5 others
help: one of the expressions' fields has a field of the same name
    |
188 |                 wr.__bindgen_anon_1.imm_data = imm_data.unwrap()
    |                    +++++++++++++++++

error[E0609]: no field `imm_data` on type `rdma_shim::bindings::ibv_send_wr`
   --> src/queue_pairs/./operations_user.rs:445:16
    |
445 |             wr.imm_data = imm_data;
    |                ^^^^^^^^ unknown field
    |
    = note: available fields are: `wr_id`, `next`, `sg_list`, `num_sge`, `opcode` ... and 5 others
help: one of the expressions' fields has a field of the same name
    |
445 |             wr.__bindgen_anon_1.imm_data = imm_data;
    |                +++++++++++++++++

I think this is because my environment DO NOT HAVE feature OFED_5_4, so some codes in #[cfg(not(feature = "OFED_5_4"))] cannot pass compile!

I change ALL codes in #[cfg(not(feature = "OFED_5_4"))] to codes like #[cfg(feature = "OFED_5_4")]. For example, I change

#[cfg(not(feature = "OFED_5_4"))]
            {
                wr.imm_data = imm_data.unwrap()
            };

to

#[cfg(not(feature = "OFED_5_4"))]
            unsafe {
                *wr.__bindgen_anon_1.imm_data.as_mut() = imm_data.unwrap()
            };

I finally pass cargo test --features user. But when I finally run examples like cargo run --example doorbell --features user, I will get panic. I think this is triggered by different features between OFED_5_4 and my machine driver. With ofed_info, I get MLNX_OFED_LINUX-5.8-4.1.5.0 (OFED-5.8-4.1.5) in my machine.

Would you give some help for different version of OFED driver?

KRCore kernel module throws an error

Dear authors,

I am using the 7ba3bf6 as indicated in your paper for evaluation.

I have successfully installed the patched OFED driver.

I have compiled the KRdmaKitSyscall.ko successfully.

However, when I tried to install the module, there are some errors:

insmod: ERROR: could not insert module KRdmaKitSyscall.ko: Operation not permitted

The dmesg has the following output:

[ 5760.285891] KRdma kernel module init start
[ 5760.287625] Fail to start KRdma kernel module

Moreover, I am confused by the gid in the Makefile in the KRdmaKit-syscall folder and have no idea which gid to fill.

Could you help me with the above problems?

Thanks!

Errors occur in mlnx-ofed-4.9-driver/build.sh when install KRCORE modified version of Mellanox OFED driver

Dear authors, there is a step in krcore-artifacts/docs/install.md when install your modified version of Mellanox OFED driver:
cd ${PROJECT_PATH}/mlnx-ofed-4.9-driver
sh build.sh

When I run build.sh, there occurs:
tar (child): mlnx-ofed-kernel_4.9.orig.tar.gz: Cannot open: No such file or directory
tar (child): Error is not recoverable: exiting now
tar: Child returned status 2
tar: Error is not recoverable: exiting now
tail: cannot open 'mlnx-ofed-kernel-4.9/debian/changelog' for reading: No such file or directory
dpkg-source: error: tail of mlnx-ofed-kernel-4.9/debian/changelog subprocess returned exit status 1
tail: cannot open 'debian/changelog' for reading: No such file or directory
dpkg-buildpackage: error: tail of debian/changelog subprocess returned exit status 1
mv: cannot stat 'mlnx-ofed-kernel-dkms_4.9-OFED.4.9.3.1.5.1_all.deb': No such file or directory
dpkg: error: cannot access archive 'mlnx-ofed-kernel-dkms_4.9-OFED.4.9.3.1.5.1_all_new.deb': No such file or directory

In build.sh, there exists one command:
tar zxf mlnx-ofed-kernel_4.9.orig.tar.gz

May I ask what the mlnx-ofed-kernel_4.9.orig.tar.gz is? Does it mean MLNX_OFED_LINUX-4.9-3.1.5.0-ubuntu18.04-x86_64.tgz?
I would be very appreciate it.

A problem about building krcore kernel module

Dear author, I had a problem compiling the krcore kernel module. I'm sorry that this may disturb your study and life. I am interested in your project and hope to reproduce it.Thank you for your checking of this question.
————————————————————————————————
[root@localhost KRdmaKit-syscall]# make
cp -f /usr/src/ofa_kernel/default/Module*.symvers /home/Lichenxiang/krdmakit/KRdmaKit-syscall/Module.symvers
make -C /lib/modules/4.19.37/build M=/home/Lichenxiang/krdmakit/KRdmaKit-syscall CC=clang-9 CONFIG_CC_IS_CLANG=y
make[1]: Entering directory `/usr/src/linux-4.19.37'
cd /home/Lichenxiang/krdmakit/KRdmaKit-syscall; cargo build -Z build-std=core,alloc --target=x86_64-unknown-none-linuxkernel
Updating crates.io index
warning: spurious network error (2 tries remaining): failed to connect to github.com: Connection timed out; class=Os (2)
Compiling linux-kernel-module v0.1.0 (/home/Lichenxiang/krdmakit/rust-kernel-rdma/deps/rust-kernel-module)
Compiling rust-kernel-linux-util v0.1.0 (/home/Lichenxiang/krdmakit/rust-kernel-rdma/rust-kernel-linux-util)
Compiling rust-kernel-rdma-base v0.1.0 (/home/Lichenxiang/krdmakit/rust-kernel-rdma/rust-kernel-rdma-base)
Compiling KRdmaKitSyscall v0.1.0 (/home/Lichenxiang/krdmakit/KRdmaKit-syscall)
The following warnings were emitted during compilation:

warning: In file included from :2:
warning: /usr/src/ofa_kernel/default/include/generated/autoconf.h:2:2: warning: #include_next in file found relative to primary source file or found by absolute path; will search from start of include path [-Winclude-next-absolute-path]
warning: #include_next <generated/autoconf.h>
warning: ^
warning: In file included from src/native/kernel_helper.c:1:
warning: In file included from src/native/kernel_helper.h:1:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/moduleparam.h:7:
warning: In file included from //usr/src/ofa_kernel/default/include/linux/kernel.h:6:
warning: /lib/modules/4.19.37/build/./include/linux/kernel.h:6:10: error: 'stdarg.h' file not found with include; use "quotes" instead
warning: #include <stdarg.h>
warning: ^~~~~~~~~~
warning: "stdarg.h"
warning: In file included from src/native/kernel_helper.c:1:
warning: In file included from src/native/kernel_helper.h:1:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/moduleparam.h:7:
warning: In file included from //usr/src/ofa_kernel/default/include/linux/kernel.h:6:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/kernel.h:6:
warning: /lib/modules/4.19.37/build/./include/linux/stdarg.h:26:5: warning: 'STDC_VERSION' is not defined, evaluates to 0 [-Wundef]
warning: #if STDC_VERSION >= 199901L || __cplusplus >= 201103L || !defined(STRICT_ANSI)
warning: ^
warning: /lib/modules/4.19.37/build/./include/linux/stdarg.h:26:36: warning: '__cplusplus' is not defined, evaluates to 0 [-Wundef]
warning: #if STDC_VERSION >= 199901L || __cplusplus >= 201103L || !defined(STRICT_ANSI)
warning: ^
warning: In file included from src/native/kernel_helper.c:1:
warning: In file included from src/native/kernel_helper.h:1:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/moduleparam.h:7:
warning: In file included from //usr/src/ofa_kernel/default/include/linux/kernel.h:6:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/kernel.h:14:
warning: In file included from //usr/src/ofa_kernel/default/include/linux/printk.h:8:
warning: /lib/modules/4.19.37/build/./include/linux/printk.h:5:10: error: 'stdarg.h' file not found with include; use "quotes" instead
warning: #include <stdarg.h>
warning: ^~~~~~~~~~
warning: "stdarg.h"
warning: In file included from src/native/kernel_helper.c:1:
warning: In file included from src/native/kernel_helper.h:1:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/moduleparam.h:7:
warning: In file included from //usr/src/ofa_kernel/default/include/linux/kernel.h:6:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/kernel.h:14:
warning: In file included from //usr/src/ofa_kernel/default/include/linux/printk.h:8:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/printk.h:336:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/dynamic_debug.h:6:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/jump_label.h:121:
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:36:2: error: implicit declaration of function 'asm_volatile_goto' [-Werror,-Wimplicit-function-declaration]
warning: asm_volatile_goto("1:"
warning: ^
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:42:3: error: expected ')'
warning: : : "i" (key), "i" (branch) : : l_yes);
warning: ^
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:36:19: note: to match this '('
warning: asm_volatile_goto("1:"
warning: ^
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:51:2: error: implicit declaration of function 'asm_volatile_goto' [-Werror,-Wimplicit-function-declaration]
warning: asm_volatile_goto("1:"
warning: ^
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:58:3: error: expected ')'
warning: : : "i" (key), "i" (branch) : : l_yes);
warning: ^
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:51:19: note: to match this '('
warning: asm_volatile_goto("1:"
warning: ^
warning: In file included from src/native/kernel_helper.c:1:
warning: In file included from src/native/kernel_helper.h:2:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/stat.h:19:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/time.h:6:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/seqlock.h:36:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/spinlock.h:51:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/preempt.h:81:
warning: In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/preempt.h:7:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/thread_info.h:38:
warning: In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/thread_info.h:53:
warning: In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/cpufeature.h:5:
warning: In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/processor.h:21:
warning: In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/msr.h:11:
warning: In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/cpumask.h:5:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/cpumask.h:12:
warning: In file included from //usr/src/ofa_kernel/default/include/linux/bitmap.h:6:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/bitmap.h:9:
warning: In file included from //usr/src/ofa_kernel/default/include/linux/string.h:6:
warning: /lib/modules/4.19.37/build/./include/linux/string.h:9:10: error: 'stdarg.h' file not found with include; use "quotes" instead
warning: #include <stdarg.h>
warning: ^~~~~~~~~~
warning: "stdarg.h"
warning: In file included from src/native/kernel_helper.c:1:
warning: In file included from src/native/kernel_helper.h:2:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/stat.h:19:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/time.h:6:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/seqlock.h:36:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/spinlock.h:51:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/preempt.h:81:
warning: In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/preempt.h:7:
warning: In file included from /lib/modules/4.19.37/build/./include/linux/thread_info.h:38:
warning: In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/thread_info.h:53:
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/cpufeature.h:164:2: error: implicit declaration of function 'asm_volatile_goto' [-Werror,-Wimplicit-function-declaration]
warning: asm_volatile_goto("1: jmp 6f\n"
warning: ^
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/cpufeature.h:195:4: error: expected ')'
warning: : : [feature] "i" (bit),
warning: ^
warning: /lib/modules/4.19.37/build/./arch/x86/include/asm/cpufeature.h:164:19: note: to match this '('
warning: asm_volatile_goto("1: jmp 6f\n"
warning: ^
warning: 3 warnings and 9 errors generated.

error: failed to run custom build command for KRdmaKitSyscall v0.1.0 (/home/Lichenxiang/krdmakit/KRdmaKit-syscall)

Caused by:
process didn't exit successfully: /home/Lichenxiang/krdmakit/KRdmaKit-syscall/target/debug/build/KRdmaKitSyscall-33d4d8acb94183c0/build-script-build (exit status: 1)
--- stdout
cargo:rust-cfg=out
cargo:rerun-if-env-changed=CC
cargo:rerun-if-env-changed=KDIR
cargo:rerun-if-env-changed=c_flags
cargo:rerun-if-env-changed=ofa_flags
cargo:rustc-cfg=BASE_MLNX_OFED_LINUX_5_1_2_3_7_1
cargo:rerun-if-changed=../include/common.h
cargo:rerun-if-changed=src/native/kernel_helper.h
cargo:rerun-if-changed=src/native/kernel_helper.c
OPT_LEVEL = Some("2")
HOST = Some("x86_64-unknown-linux-gnu")
cargo:rerun-if-env-changed=CFLAGS_x86_64-unknown-none-linuxkernel
CFLAGS_x86_64-unknown-none-linuxkernel = None
cargo:rerun-if-env-changed=CFLAGS_x86_64_unknown_none_linuxkernel
CFLAGS_x86_64_unknown_none_linuxkernel = None
cargo:rerun-if-env-changed=TARGET_CFLAGS
TARGET_CFLAGS = None
cargo:rerun-if-env-changed=CFLAGS
CFLAGS = None
cargo:rerun-if-env-changed=CRATE_CC_NO_DEFAULTS
CRATE_CC_NO_DEFAULTS = None
DEBUG = Some("true")
running: "clang-9" "-O2" "-ffunction-sections" "-fdata-sections" "-gdwarf-4" "-fno-omit-frame-pointer" "--target=x86_64-unknown-none-linuxkernel" "-include" "/lib/modules/4.19.37/build/include/generated/autoconf.h" "-include" "/usr/src/ofa_kernel/default/include/generated/autoconf.h" "-I//usr/src/ofa_kernel/default/include" "-Wp,-MD,/home/Lichenxiang/krdmakit/KRdmaKit-syscall/target/x86_64-unknown-none-linuxkernel/debug/.libKRdmaKitSyscall.a.d" "-nostdinc" "-isystem" "/usr/local/bin/../include" "-I/lib/modules/4.19.37/build/./arch/x86/include" "-I/lib/modules/4.19.37/build/./arch/x86/include/generated" "-I/lib/modules/4.19.37/build/./include" "-I/lib/modules/4.19.37/build/./arch/x86/include/uapi" "-I/lib/modules/4.19.37/build/./arch/x86/include/generated/uapi" "-I/lib/modules/4.19.37/build/./include/uapi" "-I/lib/modules/4.19.37/build/./include/generated/uapi" "-include" "/lib/modules/4.19.37/build/./include/linux/kconfig.h" "-include" "/lib/modules/4.19.37/build/./include/linux/compiler_types.h" "-D__KERNEL__" "-Qunused-arguments" "-Wall" "-Wundef" "-Wstrict-prototypes" "-Wno-trigraphs" "-fno-strict-aliasing" "-fno-common" "-fshort-wchar" "-Werror-implicit-function-declaration" "-Wno-format-security" "-std=gnu89" "-no-integrated-as" "-fno-PIE" "-DCC_HAVE_ASM_GOTO" "-mno-sse" "-mno-mmx" "-mno-sse2" "-mno-3dnow" "-mno-avx" "-m64" "-mno-80387" "-mstack-alignment=8" "-mtune=generic" "-mno-red-zone" "-mcmodel=kernel" "-funit-at-a-time" "-DCONFIG_AS_CFI=1" "-DCONFIG_AS_CFI_SIGNAL_FRAME=1" "-DCONFIG_AS_CFI_SECTIONS=1" "-DCONFIG_AS_FXSAVEQ=1" "-DCONFIG_AS_SSSE3=1" "-DCONFIG_AS_CRC32=1" "-DCONFIG_AS_AVX=1" "-DCONFIG_AS_AVX2=1" "-DCONFIG_AS_AVX512=1" "-DCONFIG_AS_SHA1_NI=1" "-DCONFIG_AS_SHA256_NI=1" "-pipe" "-Wno-sign-compare" "-fno-asynchronous-unwind-tables" "-mretpoline-external-thunk" "-fno-delete-null-pointer-checks" "-O2" "-Wframe-larger-than=2048" "-fstack-protector-strong" "-Wno-format-invalid-specifier" "-Wno-gnu" "-Wno-address-of-packed-member" "-Wno-tautological-compare" "-mno-global-merge" "-Wno-unused-const-variable" "-g" "-pg" "-mfentry" "-DCC_USING_FENTRY" "-Wdeclaration-after-statement" "-Wno-pointer-sign" "-fno-strict-overflow" "-fno-merge-all-constants" "-fno-stack-check" "-Werror=implicit-int" "-Werror=strict-prototypes" "-Werror=date-time" "-Werror=incompatible-pointer-types" "-Wno-initializer-overrides" "-Wno-unused-value" "-Wno-format" "-Wno-sign-compare" "-Wno-format-zero-length" "-Wno-uninitialized" "-DMODULE" "-DKBUILD_BASENAME="libKRdmaKitSyscall"" "-DKBUILD_MODNAME="libKRdmaKitSyscall"" "-DMODULE" "-o" "/home/Lichenxiang/krdmakit/KRdmaKit-syscall/target/x86_64-unknown-none-linuxkernel/debug/build/KRdmaKitSyscall-3de05ecf81326dec/out/src/native/kernel_helper.o" "-c" "src/native/kernel_helper.c"
cargo:warning=In file included from :2:
cargo:warning=/usr/src/ofa_kernel/default/include/generated/autoconf.h:2:2: warning: #include_next in file found relative to primary source file or found by absolute path; will search from start of include path [-Winclude-next-absolute-path]
cargo:warning=#include_next <generated/autoconf.h>
cargo:warning= ^
cargo:warning=In file included from src/native/kernel_helper.c:1:
cargo:warning=In file included from src/native/kernel_helper.h:1:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/moduleparam.h:7:
cargo:warning=In file included from //usr/src/ofa_kernel/default/include/linux/kernel.h:6:
cargo:warning=/lib/modules/4.19.37/build/./include/linux/kernel.h:6:10: error: 'stdarg.h' file not found with include; use "quotes" instead
cargo:warning=#include <stdarg.h>
cargo:warning= ^~~~~~~~~~
cargo:warning= "stdarg.h"
cargo:warning=In file included from src/native/kernel_helper.c:1:
cargo:warning=In file included from src/native/kernel_helper.h:1:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/moduleparam.h:7:
cargo:warning=In file included from //usr/src/ofa_kernel/default/include/linux/kernel.h:6:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/kernel.h:6:
cargo:warning=/lib/modules/4.19.37/build/./include/linux/stdarg.h:26:5: warning: 'STDC_VERSION' is not defined, evaluates to 0 [-Wundef]
cargo:warning=#if STDC_VERSION >= 199901L || __cplusplus >= 201103L || !defined(STRICT_ANSI)
cargo:warning= ^
cargo:warning=/lib/modules/4.19.37/build/./include/linux/stdarg.h:26:36: warning: '__cplusplus' is not defined, evaluates to 0 [-Wundef]
cargo:warning=#if STDC_VERSION >= 199901L || __cplusplus >= 201103L || !defined(STRICT_ANSI)
cargo:warning= ^
cargo:warning=In file included from src/native/kernel_helper.c:1:
cargo:warning=In file included from src/native/kernel_helper.h:1:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/moduleparam.h:7:
cargo:warning=In file included from //usr/src/ofa_kernel/default/include/linux/kernel.h:6:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/kernel.h:14:
cargo:warning=In file included from //usr/src/ofa_kernel/default/include/linux/printk.h:8:
cargo:warning=/lib/modules/4.19.37/build/./include/linux/printk.h:5:10: error: 'stdarg.h' file not found with include; use "quotes" instead
cargo:warning=#include <stdarg.h>
cargo:warning= ^~~~~~~~~~
cargo:warning= "stdarg.h"
cargo:warning=In file included from src/native/kernel_helper.c:1:
cargo:warning=In file included from src/native/kernel_helper.h:1:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/moduleparam.h:7:
cargo:warning=In file included from //usr/src/ofa_kernel/default/include/linux/kernel.h:6:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/kernel.h:14:
cargo:warning=In file included from //usr/src/ofa_kernel/default/include/linux/printk.h:8:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/printk.h:336:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/dynamic_debug.h:6:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/jump_label.h:121:
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:36:2: error: implicit declaration of function 'asm_volatile_goto' [-Werror,-Wimplicit-function-declaration]
cargo:warning= asm_volatile_goto("1:"
cargo:warning= ^
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:42:3: error: expected ')'
cargo:warning= : : "i" (key), "i" (branch) : : l_yes);
cargo:warning= ^
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:36:19: note: to match this '('
cargo:warning= asm_volatile_goto("1:"
cargo:warning= ^
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:51:2: error: implicit declaration of function 'asm_volatile_goto' [-Werror,-Wimplicit-function-declaration]
cargo:warning= asm_volatile_goto("1:"
cargo:warning= ^
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:58:3: error: expected ')'
cargo:warning= : : "i" (key), "i" (branch) : : l_yes);
cargo:warning= ^
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/jump_label.h:51:19: note: to match this '('
cargo:warning= asm_volatile_goto("1:"
cargo:warning= ^
cargo:warning=In file included from src/native/kernel_helper.c:1:
cargo:warning=In file included from src/native/kernel_helper.h:2:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/stat.h:19:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/time.h:6:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/seqlock.h:36:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/spinlock.h:51:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/preempt.h:81:
cargo:warning=In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/preempt.h:7:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/thread_info.h:38:
cargo:warning=In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/thread_info.h:53:
cargo:warning=In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/cpufeature.h:5:
cargo:warning=In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/processor.h:21:
cargo:warning=In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/msr.h:11:
cargo:warning=In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/cpumask.h:5:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/cpumask.h:12:
cargo:warning=In file included from //usr/src/ofa_kernel/default/include/linux/bitmap.h:6:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/bitmap.h:9:
cargo:warning=In file included from //usr/src/ofa_kernel/default/include/linux/string.h:6:
cargo:warning=/lib/modules/4.19.37/build/./include/linux/string.h:9:10: error: 'stdarg.h' file not found with include; use "quotes" instead
cargo:warning=#include <stdarg.h>
cargo:warning= ^~~~~~~~~~
cargo:warning= "stdarg.h"
cargo:warning=In file included from src/native/kernel_helper.c:1:
cargo:warning=In file included from src/native/kernel_helper.h:2:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/stat.h:19:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/time.h:6:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/seqlock.h:36:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/spinlock.h:51:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/preempt.h:81:
cargo:warning=In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/preempt.h:7:
cargo:warning=In file included from /lib/modules/4.19.37/build/./include/linux/thread_info.h:38:
cargo:warning=In file included from /lib/modules/4.19.37/build/./arch/x86/include/asm/thread_info.h:53:
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/cpufeature.h:164:2: error: implicit declaration of function 'asm_volatile_goto' [-Werror,-Wimplicit-function-declaration]
cargo:warning= asm_volatile_goto("1: jmp 6f\n"
cargo:warning= ^
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/cpufeature.h:195:4: error: expected ')'
cargo:warning= : : [feature] "i" (bit),
cargo:warning= ^
cargo:warning=/lib/modules/4.19.37/build/./arch/x86/include/asm/cpufeature.h:164:19: note: to match this '('
cargo:warning= asm_volatile_goto("1: jmp 6f\n"
cargo:warning= ^
cargo:warning=3 warnings and 9 errors generated.
exit status: 1

--- stderr

error occurred: Command "clang-9" "-O2" "-ffunction-sections" "-fdata-sections" "-gdwarf-4" "-fno-omit-frame-pointer" "--target=x86_64-unknown-none-linuxkernel" "-include" "/lib/modules/4.19.37/build/include/generated/autoconf.h" "-include" "/usr/src/ofa_kernel/default/include/generated/autoconf.h" "-I//usr/src/ofa_kernel/default/include" "-Wp,-MD,/home/Lichenxiang/krdmakit/KRdmaKit-syscall/target/x86_64-unknown-none-linuxkernel/debug/.libKRdmaKitSyscall.a.d" "-nostdinc" "-isystem" "/usr/local/bin/../include" "-I/lib/modules/4.19.37/build/./arch/x86/include" "-I/lib/modules/4.19.37/build/./arch/x86/include/generated" "-I/lib/modules/4.19.37/build/./include" "-I/lib/modules/4.19.37/build/./arch/x86/include/uapi" "-I/lib/modules/4.19.37/build/./arch/x86/include/generated/uapi" "-I/lib/modules/4.19.37/build/./include/uapi" "-I/lib/modules/4.19.37/build/./include/generated/uapi" "-include" "/lib/modules/4.19.37/build/./include/linux/kconfig.h" "-include" "/lib/modules/4.19.37/build/./include/linux/compiler_types.h" "-D__KERNEL__" "-Qunused-arguments" "-Wall" "-Wundef" "-Wstrict-prototypes" "-Wno-trigraphs" "-fno-strict-aliasing" "-fno-common" "-fshort-wchar" "-Werror-implicit-function-declaration" "-Wno-format-security" "-std=gnu89" "-no-integrated-as" "-fno-PIE" "-DCC_HAVE_ASM_GOTO" "-mno-sse" "-mno-mmx" "-mno-sse2" "-mno-3dnow" "-mno-avx" "-m64" "-mno-80387" "-mstack-alignment=8" "-mtune=generic" "-mno-red-zone" "-mcmodel=kernel" "-funit-at-a-time" "-DCONFIG_AS_CFI=1" "-DCONFIG_AS_CFI_SIGNAL_FRAME=1" "-DCONFIG_AS_CFI_SECTIONS=1" "-DCONFIG_AS_FXSAVEQ=1" "-DCONFIG_AS_SSSE3=1" "-DCONFIG_AS_CRC32=1" "-DCONFIG_AS_AVX=1" "-DCONFIG_AS_AVX2=1" "-DCONFIG_AS_AVX512=1" "-DCONFIG_AS_SHA1_NI=1" "-DCONFIG_AS_SHA256_NI=1" "-pipe" "-Wno-sign-compare" "-fno-asynchronous-unwind-tables" "-mretpoline-external-thunk" "-fno-delete-null-pointer-checks" "-O2" "-Wframe-larger-than=2048" "-fstack-protector-strong" "-Wno-format-invalid-specifier" "-Wno-gnu" "-Wno-address-of-packed-member" "-Wno-tautological-compare" "-mno-global-merge" "-Wno-unused-const-variable" "-g" "-pg" "-mfentry" "-DCC_USING_FENTRY" "-Wdeclaration-after-statement" "-Wno-pointer-sign" "-fno-strict-overflow" "-fno-merge-all-constants" "-fno-stack-check" "-Werror=implicit-int" "-Werror=strict-prototypes" "-Werror=date-time" "-Werror=incompatible-pointer-types" "-Wno-initializer-overrides" "-Wno-unused-value" "-Wno-format" "-Wno-sign-compare" "-Wno-format-zero-length" "-Wno-uninitialized" "-DMODULE" "-DKBUILD_BASENAME="libKRdmaKitSyscall"" "-DKBUILD_MODNAME="libKRdmaKitSyscall"" "-DMODULE" "-o" "/home/Lichenxiang/krdmakit/KRdmaKit-syscall/target/x86_64-unknown-none-linuxkernel/debug/build/KRdmaKitSyscall-3de05ecf81326dec/out/src/native/kernel_helper.o" "-c" "src/native/kernel_helper.c" with args "clang-9" did not execute successfully (status code exit status: 1).
————————————————————————————————
When I enter the make command, it prompts the above error. My server is CentOS7, which is different from your server Ubuntu 18. Therefore, I speculate that it may be an operating system type problem. I don't know whether this speculation is correct. I hope you can provide an answer. Thank you again.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.