ZAM optimizations for record creation

includes reworking of managing "auxiliary" information for ZAM instructions
This commit is contained in:
Vern Paxson 2024-01-18 10:15:29 -08:00 committed by Arne Welzel
parent 9f94360cfc
commit 91cab9931d
8 changed files with 341 additions and 207 deletions

View file

@ -1392,6 +1392,10 @@ protected:
friend class zeek::detail::CPPRuntime;
friend class zeek::detail::CompositeHash;
// Constructor for use by script optimization, directly initializing
// record_vals from the second argument.
RecordVal(RecordTypePtr t, std::vector<std::optional<ZVal>> init_vals);
RecordValPtr DoCoerceTo(RecordTypePtr other, bool allow_orphaning) const;
/**
@ -1436,7 +1440,7 @@ protected:
void AddedField(int field) { Modified(); }
Obj* origin;
Obj* origin = nullptr;
using RecordTypeValMap = std::unordered_map<RecordType*, std::vector<RecordValPtr>>;
static RecordTypeValMap parse_time_records;