Fix eh frame relocation (#2109)

* Exclude .eh_frame
This commit is contained in:
jackcmay
2018-12-11 12:14:41 -08:00
committed by GitHub
parent 5847961fec
commit 935524f20c
4 changed files with 7 additions and 8 deletions

View File

@ -12,6 +12,7 @@ extern bool entrypoint(const uint8_t *input) {
SolClusterInfo info;
sol_log(__FILE__);
if (!sol_deserialize(input, ka, SOL_ARRAY_SIZE(ka), &ka_len, &data, &data_len, &info)) {
return false;
}

View File

@ -16,5 +16,4 @@ SECTIONS
.gnu.hash : { *(.gnu.hash) } :dynamic
.rel.dyn : { *(.rel.dyn) } :dynamic
.hash : { *(.hash) } :dynamic
}

View File

@ -60,6 +60,10 @@ BPF_CXX_FLAGS := \
-emit-llvm \
-target bpf \
-fPIC \
-fomit-frame-pointer \
-fno-exceptions \
-fno-asynchronous-unwind-tables \
-fno-unwind-tables \
BPF_LLC_FLAGS := \
-march=bpf \

View File

@ -299,12 +299,7 @@ fn test_program_builtin_bpf_noop() {
fn test_program_bpf_c() {
logger::setup();
let programs = [
"noop",
"struct_pass",
"struct_ret",
//"noop++" // TODO fails with buffer overflow
];
let programs = ["noop", "struct_pass", "struct_ret", "noop++"];
for program in programs.iter() {
println!("Test program: {:?}", program);
let mut file = File::open(create_bpf_path(program)).expect("file open failed");