introduce notions of script functions/BiFs that are (1) foldable, (2) replaceable

This commit is contained in:
Vern Paxson 2024-04-08 18:18:46 -04:00 committed by Tim Wojtulewicz
parent 5445e8c7ff
commit 1b838ca91d
3 changed files with 201 additions and 165 deletions

View file

@ -34,6 +34,11 @@ void Inliner::Analyze() {
if ( is_special_script_func(f.Func()->Name()) )
continue;
// If ZAM can replace the script, don't inline it, so its usage
// remains visible during the AST reduction process.
if ( is_ZAM_replaceable_script_func(f.Func()->Name()) )
continue;
std::unordered_set<const Func*> cs;
// Aspirational ....