mirror of https://github.com/torvalds/linux.git
End result is the same, its an ABI, so the struct won't change, avoid
using a GNU extension, so that we can catch other cases that may be bugs.
Caught when building with clang:
tests/parse-no-sample-id-all.c:53:20: error: field 'attr' with variable sized type 'struct attr_event' not at the end of a struct or class is a GNU extension
[-Werror,-Wgnu-variable-sized-type-not-at-end]
struct attr_event attr;
^
1 error generated.
Testing it:
# perf test sample_id
24: Parse with no sample_id_all bit set : Ok
#
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/n/tip-e2vs1x771fc208uvxnwcf08b@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
|
||
|---|---|---|
| .. | ||
| attr | ||
| .gitignore | ||
| Build | ||
| attr.c | ||
| attr.py | ||
| backward-ring-buffer.c | ||
| bitmap.c | ||
| bp_signal.c | ||
| bp_signal_overflow.c | ||
| bpf-script-example.c | ||
| bpf-script-test-kbuild.c | ||
| bpf-script-test-prologue.c | ||
| bpf-script-test-relocation.c | ||
| bpf.c | ||
| builtin-test.c | ||
| clang.c | ||
| code-reading.c | ||
| cpumap.c | ||
| dso-data.c | ||
| dwarf-unwind.c | ||
| event-times.c | ||
| event_update.c | ||
| evsel-roundtrip-name.c | ||
| evsel-tp-sched.c | ||
| fdarray.c | ||
| hists_common.c | ||
| hists_common.h | ||
| hists_cumulate.c | ||
| hists_filter.c | ||
| hists_link.c | ||
| hists_output.c | ||
| is_printable_array.c | ||
| keep-tracking.c | ||
| kmod-path.c | ||
| llvm.c | ||
| llvm.h | ||
| make | ||
| mmap-basic.c | ||
| mmap-thread-lookup.c | ||
| openat-syscall-all-cpus.c | ||
| openat-syscall-tp-fields.c | ||
| openat-syscall.c | ||
| parse-events.c | ||
| parse-no-sample-id-all.c | ||
| perf-hooks.c | ||
| perf-record.c | ||
| perf-targz-src-pkg | ||
| pmu.c | ||
| python-use.c | ||
| sample-parsing.c | ||
| sdt.c | ||
| stat.c | ||
| sw-clock.c | ||
| switch-tracking.c | ||
| task-exit.c | ||
| tests.h | ||
| thread-map.c | ||
| thread-mg-share.c | ||
| topology.c | ||
| unit_number__scnprintf.c | ||
| vmlinux-kallsyms.c | ||