Commit graph

33 commits

Author SHA1 Message Date
Vern Paxson
91335a770f fix for non-default_insert 2023-11-28 15:33:50 -08:00
Vern Paxson
eab33725f8 initial elements of switching over CSE validity to full assessment of side effects 2023-11-28 15:01:52 -08:00
Vern Paxson
8a18d5f8a2 broader tracking of aggregate modifications 2023-11-28 11:06:11 -08:00
Vern Paxson
f0eccda180 fixes for missed optimization opportunities 2023-11-27 22:31:03 -08:00
Vern Paxson
1a97b0572a squashing buglets 2023-11-27 16:51:52 -08:00
Vern Paxson
b645336b5d basic framework in place for rigorously assessing side effects 2023-11-24 16:36:55 -08:00
Vern Paxson
4ec9a23ce6 retention of superseded AST elements to prevent pointer mis-aliasing 2023-11-10 11:06:16 +01:00
Vern Paxson
b489cfc508 greater ZAM optimization of inlined function calls 2023-11-10 09:57:35 +01:00
Vern Paxson
9bfe18473d allow explicitly marking an identifier as equivalent to special '_' identifier 2023-11-10 09:56:59 +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
8f92e0d39b ZAM fixes for record creation and table indexing potentially having side-effects 2023-09-27 11:38:21 -07:00
Vern Paxson
1ff490b41c more extensive ZAM inlining & compilation of lambdas 2023-07-17 16:31:30 -07:00
Vern Paxson
1b2cd0c767 migrated some raw pointers to smart pointers 2023-07-11 16:04:30 -07:00
Vern Paxson
3f9f47980a updates to ZAM to track recent changes in script semantics 2021-12-04 20:24:39 -05: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
da6ac0b521 switch to ID definition regions; reworked driver functions; more info for reporting uncompilable functions 2021-09-08 10:23:38 -07:00
Tim Wojtulewicz
5e00f78920 Fix a number of Coverity findings
- 1458048: Use-after-free in the SQLite logger
- 1457823: Missing a break statement in script-opt reduction
- 1453966: Dead code in CompHash
- 1445417: Unintialized variable in StaticHash64
- 1437716: Unintialized variables in FileInfo in scan.l
2021-07-02 11:18:19 -07:00
Vern Paxson
b7c9940221 gracefully deal with "eval" exceptions that occur during AST reduction 2021-05-30 17:48:14 -07:00
Vern Paxson
9ba7e95bad fix for tracking the effects of += operations 2021-05-30 17:32:29 -07:00
Jon Siwek
f2d3bf3037 Merge remote-tracking branch 'origin/topic/vern/ast-opt'
- Removed a stray `printf()` from script-opt Reduce code

* origin/topic/vern/ast-opt: (23 commits)
  Tweak minor const-ref/std::move things in script-opt code
  Add alternative 'xform' baseline for test: broker.store.create-failure
  Add explicit return value to Reducer::SameOp()
  fixed AST transformation logic for boolean expressions
  don't know how I overlooked these minor test suite updates
  "opt" btest baseline updates due to AST optimizations changing printed code
  "opt" baseline exceptions due to incompatibility with optimize-AST and -u
  new "opt" btest alternative
  update to "xform" test suite baseline due to recent line number changes
  logic for driving AST optimization when requested
  methods implementing AST optimization (aliasing, constant propagation, CSE)
  helper class checking if common-subexpression elimination opportunity is valid
  helper function for comparing collections of definition points
  track more information about temporary variables
  simplify and tidy up some interfaces
  enable setting "-O optimize-AST" option
  fix for reducing operations on boolean vectors
  control whether checking for type-equivalence generates warnings
  remove unneeded virtual method (same as inherited method)
  accessors for additional Expr subclasses
  ...
2021-03-08 18:33:04 -08:00
Jon Siwek
b66f4ad500 Tweak minor const-ref/std::move things in script-opt code 2021-03-08 15:50:04 -08:00
Jon Siwek
0ef315d143 Add explicit return value to Reducer::SameOp()
Helps tools that don't realize the implications of [[noreturn]] on
the Reporter::InternalError() in this case.
2021-03-08 12:39:39 -08:00
Vern Paxson
77f04935a8 methods implementing AST optimization (aliasing, constant propagation, CSE) 2021-02-27 11:36:15 -08:00
Vern Paxson
34ccd3e417 helper class checking if common-subexpression elimination opportunity is valid 2021-02-27 11:35:01 -08:00
Vern Paxson
ec97c9b042 helper function for comparing collections of definition points 2021-02-27 11:32:06 -08:00
Vern Paxson
64ef7f0eb2 simplify and tidy up some interfaces 2021-02-27 11:07:39 -08:00
Vern Paxson
743f5cfef6 fix includes to have proper prefixes 2021-02-27 08:28:15 -08:00
Vern Paxson
772834e375 whitespace micro-preening 2021-02-05 21:03:10 -08:00
Vern Paxson
6f20c0da3f inlining fix: propagate identifier attributes (such as &is_set) 2021-02-03 16:46:07 -08:00
Jon Siwek
b4cf393475 Adjust some Reducer ref-counting and IntrusivePtr usage 2021-01-14 00:24:12 -08:00
Vern Paxson
03085d45e5 simplified some vestigial complexity I noticed when flipping through diffs 2021-01-10 17:36:03 -08:00
Vern Paxson
607e9950bf implementation for Reduce class - code now links 2021-01-10 14:14:09 -08:00