mirror of
https://github.com/zeek/zeek.git
synced 2025-10-09 10:08:20 +00:00
UID, ..: un-inline methods to reduce header dependencies
Only 1% build time speedup, but still, it declutters the headers a bit. Before this patch: 2565.17user 141.83system 2:25.46elapsed 1860%CPU (0avgtext+0avgdata 1489076maxresident)k 72576inputs+9130920outputs (1667major+49400430minor)pagefaults 0swaps After this patch: 2537.19user 142.94system 2:26.90elapsed 1824%CPU (0avgtext+0avgdata 1434268maxresident)k 16240inputs+8887152outputs (1931major+48728888minor)pagefaults 0swaps
This commit is contained in:
parent
0db61f3094
commit
6a815b4b06
38 changed files with 348 additions and 211 deletions
11
src/Val.h
11
src/Val.h
|
@ -6,9 +6,7 @@
|
|||
#include "Dict.h"
|
||||
#include "CompHash.h"
|
||||
#include "BroString.h"
|
||||
#include "Attr.h"
|
||||
#include "Timer.h"
|
||||
#include "ID.h"
|
||||
#include "Scope.h"
|
||||
#include "Notifier.h"
|
||||
#include "RE.h"
|
||||
|
@ -293,11 +291,7 @@ public:
|
|||
return bound_id ? global_scope()->Lookup(bound_id) : 0;
|
||||
}
|
||||
|
||||
void SetID(ID* id)
|
||||
{
|
||||
delete [] bound_id;
|
||||
bound_id = id ? copy_string(id->Name()) : 0;
|
||||
}
|
||||
void SetID(ID* id);
|
||||
#endif
|
||||
|
||||
static bool WouldOverflow(const BroType* from_type, const BroType* to_type, const Val* val);
|
||||
|
@ -792,8 +786,7 @@ public:
|
|||
ListVal* ConvertToPureList() const; // must be single index type
|
||||
|
||||
void SetAttrs(Attributes* attrs);
|
||||
Attr* FindAttr(attr_tag t) const
|
||||
{ return attrs ? attrs->FindAttr(t) : 0; }
|
||||
Attr* FindAttr(attr_tag t) const;
|
||||
Attributes* Attrs() { return attrs; }
|
||||
|
||||
// Returns the size of the table.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue