FROMLIST: perf/core: Save raw sample data conditionally based on sample type
Currently, space for raw sample data is always allocated within sample records for both BPF output and tracepoint events. This leads to unused space in sample records when raw sample data is not requested. This patch enforces checking sample type of an event in perf_sample_save_raw_data(). So raw sample data will only be saved if explicitly requested, reducing overhead when it is not needed. Fixes: 0a9081cf ("perf/core: Add perf_sample_save_raw_data() helper") Link: https://lore.kernel.org/bpf/20240515193610.2350456-2-yabinc@google.com/T/#u Bug: 335563897 Change-Id: I14fc6e6a568efaefa6c15f8842192f63ebfc2261 Signed-off-by:Yabin Cui <yabinc@google.com>
Loading
Please sign in to comment