Commit graph

40 commits

Author SHA1 Message Date
Vern Paxson
693aa244f9 shift much of the internal use of ID* identifier pointers over to IDPtr objects 2025-09-03 11:19:31 -07:00
Tim Wojtulewicz
b592b6c998 Use .contains() instead of .find() or .count() 2025-09-02 16:42:52 +00:00
Benjamin Bannier
627c3ad726 Fix clang-tidy readability-isolate-declaration warnings
I missed one of these in review so a machine is probably better at
catching them.

I fixed the existing instances which where largely in code which look
dated. Where possible I slightly reorganized the code so we do not have
to leave values uninitialized, but did not touch up anything else.
2025-06-30 14:19:06 -07:00
Tim Wojtulewicz
34ee136a3c More std::move changes based on Coverity findings 2025-04-08 11:01:21 -07:00
Vern Paxson
148215aa87 fixes for ZAM's propagation of control flow information for some degenerate constructs 2024-11-08 15:34:21 +01:00
Vern Paxson
110e5d0787 factoring of logic used by ZAM's low-level optimizer when adjusting control flow info 2024-09-27 14:16:15 -07:00
Vern Paxson
56d01ea83b ZAM control-flow tracking now explicitly includes the ends of loops 2024-09-27 13:24:34 -07:00
Arne Welzel
71e9c8d436 script_opt: Use Func::GetName() 2024-09-27 15:11:17 +02:00
Vern Paxson
db22448270 internal option to suppress control-flow optimization 2024-08-16 11:18:58 +02:00
Vern Paxson
a1185ee6bb add tracking of control flow information 2024-08-16 11:18:58 +02:00
Vern Paxson
5fc2c601b4 updates to ZAM operations / gen-zam regularization, other than the operations themselves 2024-08-16 11:18:58 +02:00
Vern Paxson
39c3a0ec0b fix for ZAM optimization pruning of unnecessary instructions 2024-04-25 09:15:12 -07:00
Vern Paxson
9f9f01580f better isolation of ZAM instruction elements
hooks for tracking extended ZAM profiling location
2024-03-19 10:59:49 -07:00
Vern Paxson
91cab9931d ZAM optimizations for record creation
includes reworking of managing "auxiliary" information for ZAM instructions
2024-01-25 20:49:12 +01:00
Vern Paxson
6660738b7d ZAM fixes for "for" loops that are only used to choose an element from a table/set 2024-01-15 15:03:56 +01:00
Vern Paxson
709d410fcd regularized (some) types of pointers used in script optimization 2023-12-12 09:45:19 +01:00
Vern Paxson
e3b75ac391 some minor ZAM optimization improvements 2023-11-10 09:57:35 +01:00
Benjamin Bannier
f5a76c1aed Reformat Zeek in Spicy style
This largely copies over Spicy's `.clang-format` configuration file. The
one place where we deviate is header include order since Zeek depends on
headers being included in a certain order.
2023-10-30 09:40:55 +01:00
Vern Paxson
3505827982 ASSERT seatbelts for low-level vector accesses 2023-07-13 11:42:53 -07:00
Vern Paxson
b6b4a81e0d removal of unused functionality and some follow-on simplifications 2023-06-30 09:36:14 +02:00
Vern Paxson
7d5760ac74 ZAM support for lambdas 2023-06-30 09:36:14 +02:00
Vern Paxson
ee0a6f6835 Script optimization maintenance and updates:
maintenance fixes for variadic run-time checks, '_' placeholder identifier
  "-O allow-cond" permits compiling scripts to C++ when influenced by @if conditionals
  more robust standalone compile-to-C++ properties
  fix for nested "when" statements
  test suite updates
2022-11-08 11:56:32 -08:00
Vern Paxson
5fe4eb27a8 ZAM support for two-valued "for" loops over vectors 2022-09-16 09:40:39 -07:00
Tim Wojtulewicz
f624c18383 Deprecate bro_int_t and bro_uint_t 2022-07-12 12:01:23 -07:00
Vern Paxson
5a0a88526e removed deprecated capture-by-reference closures 2022-06-17 15:55:43 -07:00
Vern Paxson
7a9c6c476e ZAM maintenance for recent changes and some newly exercised corner cases 2022-05-01 14:33:58 -07:00
Vern Paxson
03194949c9 reduce interpreter frames for compiled function bodies 2022-04-01 18:00:11 -07:00
Vern Paxson
16a16948a1 updates for ZAM optimization 2022-03-23 15:36:36 -07:00
Vern Paxson
f895008c34 captures for "when" statements
update Triggers to IntrusivePtr's and simpler AST traversal
introduce IDSet type, migrate associated "ID*" types to "const ID*"
2022-01-07 14:50:35 -08:00
Tim Wojtulewicz
4423574d26 clang-format: Set IndentCaseBlocks to false 2021-09-27 10:49:48 -07:00
Tim Wojtulewicz
b2f171ec69 Reformat the world 2021-09-16 15:35:39 -07:00
Vern Paxson
81e8354ada still more nit-squashing 2021-09-14 16:04:04 -07:00
Vern Paxson
57fdef573c additional tweaks to address some compiler warnings 2021-09-14 11:45:50 -07:00
Vern Paxson
693fc14eb2 tweaks to address some compiler warnings 2021-09-13 19:55:26 -07:00
Vern Paxson
7f3993ca0e tweaks to address concerns flagged by Coverity 2021-09-13 12:57:15 -07:00
Vern Paxson
38578a2ea3 low-level cleanups found by code review 2021-09-08 10:23:39 -07:00
Vern Paxson
bd7edd27fd flag loop that has slightly subtle logic 2021-09-08 10:23:38 -07:00
Vern Paxson
d609a11312 switch simple loops that don't need indices to being iterator-based 2021-09-08 10:23:38 -07:00
Vern Paxson
ffd1905f90 use container empty() rather than size() where appropriate 2021-09-08 10:23:38 -07:00
Vern Paxson
906d1fc1f2 the main ZAM code 2021-09-08 10:23:38 -07:00