mirror of
https://github.com/zeek/zeek.git
synced 2025-10-17 14:08:20 +00:00
greater ZAM optimization of inlined function calls
This commit is contained in:
parent
e3b75ac391
commit
b489cfc508
13 changed files with 130 additions and 95 deletions
|
@ -2,8 +2,8 @@
|
|||
|
||||
#pragma once
|
||||
|
||||
// Class for managing temporary variables created during statement reduction
|
||||
// for compilation.
|
||||
// Reducer helper class for managing temporary variables created during
|
||||
// statement reduction for compilation.
|
||||
|
||||
#include <string>
|
||||
|
||||
|
@ -15,10 +15,9 @@ namespace zeek::detail {
|
|||
|
||||
class TempVar {
|
||||
public:
|
||||
TempVar(size_t num, const TypePtr& t, ExprPtr rhs);
|
||||
TempVar(size_t num, ExprPtr rhs);
|
||||
|
||||
const char* Name() const { return name.data(); }
|
||||
const zeek::Type* Type() const { return type.get(); }
|
||||
const Expr* RHS() const { return rhs.get(); }
|
||||
|
||||
IDPtr Id() const { return id; }
|
||||
|
@ -42,7 +41,6 @@ public:
|
|||
protected:
|
||||
std::string name;
|
||||
IDPtr id;
|
||||
const TypePtr& type;
|
||||
ExprPtr rhs;
|
||||
bool active = true;
|
||||
IDPtr alias;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue