llvm-project/llvm/test/CodeGen/BPF/BTF
Yonghong Song a285bdb56f BPF: remove default .extern data section
Currently, for any extern variable, if it doesn't have
section attribution, it will be put into a default ".extern"
btf DataSec. The initial design is to put every extern
variable in a DataSec so libbpf can use it.

But later on, libbpf actually requires extern variables
to put into special sections, e.g., ".kconfig", ".ksyms", etc.
so they can be used properly based on section name.

Andrii mentioned since ".extern" variables are
not actually used, it makes sense to remove it from
the compiler so libbpf does not need to deal with it,
esp. for static linking. The BTF for these extern variables
is still generated.

With this patch, I tested kernel selftests/bpf and all tests
passed. Indeed, removing ".extern" DataSec seems having no
impact.

Differential Revision: https://reviews.llvm.org/D100392
2021-04-13 11:35:52 -07:00
..
array-1d-char.ll
array-1d-int.ll
array-2d-int.ll
array-size-0.ll
array-typedef.ll
binary-format.ll [llvm-readobj] Update tests because of changes in llvm-readobj behavior 2020-07-20 10:39:04 +01:00
builtin-btf-type-id-2.ll BPF: permit type modifiers for __builtin_btf_type_id() relocation 2021-03-04 16:27:23 -08:00
builtin-btf-type-id.ll BPF: make __builtin_btf_type_id() return 64bit int 2020-11-16 07:08:41 -08:00
char-no-debuginfo.ll
char.ll
double.ll [BPF] Add support for floats and doubles 2021-03-05 15:10:11 +01:00
empty-btf.ll
enum-basic.ll
extern-builtin.ll
extern-func-arg.ll
extern-global-var.ll
extern-var-func-weak-section.ll BPF: add extern func to data sections if specified 2021-03-25 16:03:29 -07:00
extern-var-func-weak.ll
extern-var-func.ll
extern-var-section.ll BPF: add extern func to data sections if specified 2021-03-25 16:03:29 -07:00
extern-var-struct-weak.ll BPF: remove default .extern data section 2021-04-13 11:35:52 -07:00
extern-var-struct.ll BPF: remove default .extern data section 2021-04-13 11:35:52 -07:00
extern-var-weak-section.ll BPF: add extern func to data sections if specified 2021-03-25 16:03:29 -07:00
filename.ll
float.ll [BPF] Add support for floats and doubles 2021-03-05 15:10:11 +01:00
func-func-ptr.ll
func-non-void.ll
func-source.ll
func-typedef.ll
func-unused-arg.ll
func-void.ll
fwd-no-define.ll
fwd-with-define.ll
global-var-inited.ll
global-var-sec-readonly.ll
global-var-sec.ll
int.ll
local-var-readonly-1.ll BPF: generate .rodata BTF datasec for certain initialized local var's 2020-07-17 09:45:57 -07:00
local-var-readonly-2.ll BPF: generate .rodata BTF datasec for certain initialized local var's 2020-07-17 09:45:57 -07:00
local-var.ll
longlong.ll
map-def-2.ll BPF: permit .maps section variables with typedef type 2020-07-12 09:42:25 -07:00
map-def-3.ll BPF: permit .maps section variables with typedef type 2020-07-12 09:42:25 -07:00
map-def.ll BPF: permit .maps section variables with typedef type 2020-07-12 09:42:25 -07:00
pruning-const.ll [BPF] fix a bug for BTF pointee type pruning 2020-06-17 15:13:46 -07:00
pruning-typedef.ll [BPF] fix a bug for BTF pointee type pruning 2020-06-17 15:13:46 -07:00
ptr-const-void.ll
ptr-func-1.ll
ptr-func-2.ll
ptr-func-3.ll
ptr-int.ll
ptr-prune-type.ll
ptr-void.ll
ptr-volatile-const-void.ll
ptr-volatile-void.ll
restrict-ptr.ll
short.ll
static-func.ll
static-var-derived-type.ll
static-var-inited-sec.ll
static-var-inited.ll
static-var-readonly-sec.ll
static-var-readonly.ll
static-var-sec.ll
static-var-zerolen-array.ll
static-var.ll
struct-anon-2.ll [BPF] Fix a BTF gen bug related to a pointer struct member 2020-07-01 09:55:01 -07:00
struct-anon.ll
struct-basic.ll
struct-bitfield-typedef.ll
struct-enum.ll
uchar.ll
uint.ll
ulonglong.ll
union-array-typedef.ll
ushort.ll
weak-global-2.ll
weak-global-3.ll BPF: generate proper BTF for globals with WeakODRLinkage 2021-04-13 08:54:05 -07:00
weak-global.ll