mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
icount: remove unnecessary gen_io_end calls
Prior patch resets can_do_io flag at the TB entry. Therefore there is no need in resetting this flag at the end of the block. This patch removes redundant gen_io_end calls. Signed-off-by: Pavel Dovgalyuk <Pavel.Dovgaluk@ispras.ru> Message-Id: <156404429499.18669.13404064982854123855.stgit@pasha-Precision-3630-Tower> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Pavel Dovgalyuk <pavel.dovgaluk@gmail.com>
This commit is contained in:
parent
ba3e792669
commit
9e9b10c649
18 changed files with 7 additions and 102 deletions
|
@ -16,6 +16,13 @@ static inline void gen_io_start(void)
|
|||
tcg_temp_free_i32(tmp);
|
||||
}
|
||||
|
||||
/*
|
||||
* cpu->can_do_io is cleared automatically at the beginning of
|
||||
* each translation block. The cost is minimal and only paid
|
||||
* for -icount, plus it would be very easy to forget doing it
|
||||
* in the translator. Therefore, backends only need to call
|
||||
* gen_io_start.
|
||||
*/
|
||||
static inline void gen_io_end(void)
|
||||
{
|
||||
TCGv_i32 tmp = tcg_const_i32(0);
|
||||
|
@ -58,7 +65,6 @@ static inline void gen_tb_start(TranslationBlock *tb)
|
|||
tcg_gen_st16_i32(count, cpu_env,
|
||||
offsetof(ArchCPU, neg.icount_decr.u16.low) -
|
||||
offsetof(ArchCPU, env));
|
||||
/* Disable I/O by default */
|
||||
gen_io_end();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue