[llvm-dev] BPF_PSEUDO_CALL question
Ananyev, Konstantin via llvm-dev
llvm-dev at lists.llvm.org
Wed Apr 10 11:37:26 PDT 2019
Hi everyone,
wtih clang 6.0 and onwards, for the following code:
$ cat t6.c
#include <stdint.h>
extern int ffx1(const void *p);
uint64_t entry(const void *p)
{
return ffx1(p);
}
clang -O2 -target bpfel -c t6.c
generates for the call BPF_PSEUDO_CALL instruction:
entry:
0: 85 10 00 00 ff ff ff ff call -1
1: 67 00 00 00 20 00 00 00 r0 <<= 32
2: c7 00 00 00 20 00 00 00 r0 s>>= 32
3: 95 00 00 00 00 00 00 00 exit
Is there any way to force clang to generate proper BPF_CALL instruction,
i.e: 85 00 00 00 ff ff ff ff (as it did in older versions)?
Thanks
Konstantin
More information about the llvm-dev
mailing list