mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 16:17:45 +00:00
Revert "LibJS/Bytecode: Don't replace the entry block in MergeBlocks"
This reverts commit acd29e064c
.
This commit is contained in:
parent
cf81bf48c6
commit
b37d84be58
1 changed files with 1 additions and 2 deletions
|
@ -36,8 +36,7 @@ void MergeBlocks::perform(PassPipelineExecutable& executable)
|
||||||
if (entry.key->terminator()->type() != Instruction::Type::Jump)
|
if (entry.key->terminator()->type() != Instruction::Type::Jump)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
// NOTE: We can't replace the first block in a function, as it's the entry block.
|
{
|
||||||
if (entry.key != executable.executable.basic_blocks.first()) {
|
|
||||||
InstructionStreamIterator it { entry.key->instruction_stream() };
|
InstructionStreamIterator it { entry.key->instruction_stream() };
|
||||||
auto& first_instruction = *it;
|
auto& first_instruction = *it;
|
||||||
if (first_instruction.type() == Instruction::Type::Jump) {
|
if (first_instruction.type() == Instruction::Type::Jump) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue