-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Perf: initial support for functions inlining
- Loading branch information
Showing
3 changed files
with
84 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,11 @@ | ||
#pragma once | ||
|
||
#include "Program.h" | ||
#include "Segment.h" | ||
|
||
namespace Bytecode::Optimizer { | ||
bool is_tail_recursive(const Segment &segment, size_t id); | ||
bool is_inlineable(const Segment &segment, size_t id); | ||
void optimize_tail_calls(Segment &segment); | ||
}// namespace Bytecode::Optimizer | ||
void inline_function(Segment &segment, Segment &to_inline, size_t id); | ||
}// namespace Bytecode::Optimizer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters