Integrate benchmarks and differential tests against an EVM interpreter (#7)

This commit is contained in:
Cyrill Leutwiler
2024-04-24 18:51:19 +02:00
parent bd10742ef8
commit df8ebb61ec
27 changed files with 1567 additions and 383 deletions
+17 -10
View File
@@ -8,16 +8,7 @@ fn llvm_config(arg: &str) -> String {
.unwrap_or_else(|_| panic!("output of `llvm-config {arg}` should be utf8"))
}
fn main() {
let mut builder = cc::Build::new();
llvm_config("--cxxflags")
.split_whitespace()
.fold(&mut builder, |builder, flag| builder.flag(flag))
.flag("-Wno-unused-parameter")
.cpp(true)
.file("src/linker.cpp")
.compile("liblinker.a");
fn set_rustc_link_flags() {
println!("cargo:rustc-link-search=native={}", llvm_config("--libdir"));
for lib in [
@@ -30,9 +21,25 @@ fn main() {
"LLVMLTO",
"LLVMTargetParser",
"LLVMBinaryFormat",
"LLVMDemangle",
] {
println!("cargo:rustc-link-lib=static={lib}");
}
#[cfg(target_os = "linux")]
println!("cargo:rustc-link-lib=dylib=stdc++");
}
fn main() {
llvm_config("--cxxflags")
.split_whitespace()
.fold(&mut cc::Build::new(), |builder, flag| builder.flag(flag))
.flag("-Wno-unused-parameter")
.cpp(true)
.file("src/linker.cpp")
.compile("liblinker.a");
set_rustc_link_flags();
println!("cargo:rerun-if-changed=build.rs");
}