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
16
src/Stmt.h
16
src/Stmt.h
|
@ -8,7 +8,6 @@
|
|||
#include "Dict.h"
|
||||
#include "ID.h"
|
||||
#include "Obj.h"
|
||||
#include "Reporter.h"
|
||||
|
||||
#include "StmtEnums.h"
|
||||
|
||||
|
@ -63,13 +62,7 @@ public:
|
|||
void Describe(ODesc* d) const override;
|
||||
|
||||
virtual void IncrBPCount() { ++breakpoint_count; }
|
||||
virtual void DecrBPCount()
|
||||
{
|
||||
if ( breakpoint_count )
|
||||
--breakpoint_count;
|
||||
else
|
||||
reporter->InternalError("breakpoint count decremented below 0");
|
||||
}
|
||||
virtual void DecrBPCount();
|
||||
|
||||
virtual unsigned int BPCount() const { return breakpoint_count; }
|
||||
|
||||
|
@ -436,12 +429,7 @@ protected:
|
|||
|
||||
class InitStmt : public Stmt {
|
||||
public:
|
||||
explicit InitStmt(id_list* arg_inits) : Stmt(STMT_INIT)
|
||||
{
|
||||
inits = arg_inits;
|
||||
if ( arg_inits && arg_inits->length() )
|
||||
SetLocationInfo((*arg_inits)[0]->GetLocationInfo());
|
||||
}
|
||||
explicit InitStmt(id_list* arg_inits);
|
||||
|
||||
~InitStmt() override;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue