[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v2 16/21] accel/tcg: actually cache our partial icount TB
From: |
Alex Bennée |
Subject: |
Re: [PATCH v2 16/21] accel/tcg: actually cache our partial icount TB |
Date: |
Fri, 12 Feb 2021 17:06:24 +0000 |
User-agent: |
mu4e 1.5.8; emacs 28.0.50 |
Philippe Mathieu-Daudé <f4bug@amsat.org> writes:
> On 2/11/21 7:48 PM, Richard Henderson wrote:
>> On 2/11/21 2:21 AM, Philippe Mathieu-Daudé wrote:
>>>> - insns_left = MIN(0xffff, cpu->icount_budget);
>>>> + insns_left = MIN(CF_COUNT_MASK, cpu->icount_budget);
>>>
>>> Can you describe this change a bit please?
>>
>> Replacing a magic number with its proper symbol.
>
> I am confuse because I see:
>
> #define CF_COUNT_MASK 0x00007fff
This is the largest partial count you can store in the CF flags (0x8000
is used for LAST_IO). The decrement field can handle the full u16
although in practice I would never expect a final block to be more than
a few instructions. We could probably shorten the mask without any
deleterious effect if we needed to scrape together any more CFLAGS.
--
Alex Bennée
[PATCH v2 14/21] tests/plugin: expand insn test to detect duplicate instructions, Alex Bennée, 2021/02/10
[PATCH v2 20/21] accel/tcg: allow plugin instrumentation to be disable via cflags, Alex Bennée, 2021/02/10
Re: [PATCH v2 20/21] accel/tcg: allow plugin instrumentation to be disable via cflags, Alex Bennée, 2021/02/12
Re: [PATCH v2 20/21] accel/tcg: allow plugin instrumentation to be disable via cflags, Aaron Lindsay, 2021/02/12
Re: [PATCH v2 20/21] accel/tcg: allow plugin instrumentation to be disable via cflags, Alex Bennée, 2021/02/12