Commit Graph

12 Commits

Author SHA1 Message Date
e95ee717fd Core: Resolve @bpfglobal reads in expressions and f-strings
Name resolution tried local_sym_tab, then vmlinux enums, then failed. Globals
now resolve between the two, in _handle_name_expr, get_operand_value, and the
printk f-string formatter, each emitting the plain 'load i64, ptr @counter'
form the C reference produces. A global therefore works in conditions, binops,
print arguments and as a helper scalar argument with no further changes --
those paths all funnel through eval_expr/get_operand_value.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01L1PX8EuP9C3o3veWGA84RF
2026-09-01 15:29:24 +05:30
3f4f95115f Core: Pass compilation_context to _prepare_expr_args as it calls eval_expr 2026-03-29 13:28:38 +05:30
f2b9767098 Core: Fix args in helper/printk_formatter 2026-03-29 13:11:44 +05:30
c22911daaf Core: FIx inconsistent compilation_context usage in helper/printk_formatter 2026-03-28 19:02:16 +05:30
cbe365d760 Unify struct and pointer to struct handling, abstract null check in ir_ops 2025-11-23 06:26:09 +05:30
c883d95655 Minor fix - check expr type before sending to char_array handler in printk_formatter 2025-11-11 17:43:20 +05:30
2f4a7d2f90 Remove get_struct_char_array_ptr in favour of get_char_array_ptr_and_size, wrap it in get_or_crate_ptr_from_arg to use in bpf_helper_handler 2025-11-07 18:54:59 +05:30
3e6cea2b67 Move get_struct_char_array_ptr from helper/printk_formatter to helper/helper_utils, enable array to ptr conversion in skb_store_bytes 2025-11-05 19:10:58 +05:30
84fdf52658 Merge branch 'master' into bcc_examples 2025-10-22 04:09:07 +05:30
190baf2674 support vmlinux enum in printk handler 2025-10-21 04:10:25 +05:30
fb480639a5 Make char array struct fields work 2025-10-15 17:27:43 +05:30
6b41f1fb84 Move print logic to helper/printk_emitter.py 2025-10-13 18:32:51 +05:30