diff options
Diffstat (limited to 'compiler/optimizing')
| -rw-r--r-- | compiler/optimizing/builder.cc | 1 | ||||
| -rw-r--r-- | compiler/optimizing/suspend_check_test.cc | 18 | 
2 files changed, 18 insertions, 1 deletions
diff --git a/compiler/optimizing/builder.cc b/compiler/optimizing/builder.cc index 71e71f79d4..cbdaec63de 100644 --- a/compiler/optimizing/builder.cc +++ b/compiler/optimizing/builder.cc @@ -164,7 +164,6 @@ void HGraphBuilder::If_21t(const Instruction& instruction, uint32_t dex_offset)    current_block_->AddInstruction(comparison);    HInstruction* ifinst = new (arena_) HIf(comparison);    current_block_->AddInstruction(ifinst); -  fprintf(stderr, "%d and %d\n", dex_offset, target_offset);    HBasicBlock* target = FindBlockStartingAt(dex_offset + target_offset);    DCHECK(target != nullptr);    current_block_->AddSuccessor(target); diff --git a/compiler/optimizing/suspend_check_test.cc b/compiler/optimizing/suspend_check_test.cc index 65fc2d8e85..2e48ee8e7e 100644 --- a/compiler/optimizing/suspend_check_test.cc +++ b/compiler/optimizing/suspend_check_test.cc @@ -74,4 +74,22 @@ TEST(CodegenTest, CFG4) {    TestCode(data);  } + +TEST(CodegenTest, CFG5) { +  const uint16_t data[] = ONE_REGISTER_CODE_ITEM( +    Instruction::CONST_4 | 0 | 0, +    Instruction::IF_EQZ, 0xFFFF, +    Instruction::RETURN_VOID); + +  TestCode(data); +} + +TEST(CodegenTest, CFG6) { +  const uint16_t data[] = ONE_REGISTER_CODE_ITEM( +    Instruction::CONST_4 | 0 | 0, +    Instruction::IF_NEZ, 0xFFFF, +    Instruction::RETURN_VOID); + +  TestCode(data); +}  }  // namespace art  |