mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 14:48:21 +00:00
optionally hash original, not extended, form of records for profiling
profile types associated with global initializations incorporate type name, if present, into type hash
This commit is contained in:
parent
0f18a01bf7
commit
0b45ff2179
3 changed files with 99 additions and 18 deletions
|
@ -81,7 +81,7 @@ void optimize_func(ScriptFunc* f, std::shared_ptr<ProfileFunc> pf,
|
|||
|
||||
if ( analysis_options.optimize_AST )
|
||||
{
|
||||
pf = std::make_shared<ProfileFunc>(f, body);
|
||||
pf = std::make_shared<ProfileFunc>(f, body, true);
|
||||
body->Traverse(pf.get());
|
||||
|
||||
RD_Decorate reduced_rds(pf);
|
||||
|
@ -111,7 +111,7 @@ void optimize_func(ScriptFunc* f, std::shared_ptr<ProfileFunc> pf,
|
|||
}
|
||||
|
||||
// Profile the new body.
|
||||
pf = std::make_shared<ProfileFunc>(f, body);
|
||||
pf = std::make_shared<ProfileFunc>(f, body, true);
|
||||
body->Traverse(pf.get());
|
||||
|
||||
// Compute its reaching definitions.
|
||||
|
@ -224,7 +224,7 @@ void analyze_scripts()
|
|||
|
||||
// Now that everything's parsed and BiF's have been initialized,
|
||||
// profile the functions.
|
||||
auto pfs = std::make_unique<ProfileFuncs>(funcs);
|
||||
auto pfs = std::make_unique<ProfileFuncs>(funcs, nullptr, true);
|
||||
|
||||
// Figure out which functions either directly or indirectly
|
||||
// appear in "when" clauses.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue