[PATCH 0/5] contrib/plugins/hotblocks: Minor bug fixes and add limit argument

Alex Bradbury posted 5 patches 3 months, 2 weeks ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/cover.1753857212.git.asb@igalia.com
Maintainers: "Alex Bennée" <alex.bennee@linaro.org>, Alexandre Iooss <erdnaxe@crans.org>, Mahmoud Mandour <ma.mandourr@gmail.com>, Pierrick Bouvier <pierrick.bouvier@linaro.org>
contrib/plugins/hotblocks.c | 20 ++++++++++++++------
docs/about/emulation.rst    | 12 ++++++++++++
2 files changed, 26 insertions(+), 6 deletions(-)
[PATCH 0/5] contrib/plugins/hotblocks: Minor bug fixes and add limit argument
Posted by Alex Bradbury 3 months, 2 weeks ago
This series contains one minor feature addition and a series of small
bugfixes/improvements. The addition that motivates the submission is to add a
limit argument for the hotblocks plugin, allowing you to control how many
blocks are printed rather than being hardcoded to the 20 most executed.
Setting limit=0 and dumping information about all executed blocks is
incredibly helpful for an analysis script I have downstream.

This is my first contribution to QEMU. I've attempted to follow all of the
guidance in the "Submitting a Patch" guide, but apologies if I missed
anything.

Alex Bradbury (5):
  contrib/plugins/hotblocks: Correctly free sorted counts list
  contrib/plugins/hotblocks: Fix off by one error in iteration of sorted
    blocks
  contrib/plugins/hotblocks: Print uint64_t with PRIu64 rather than
    PRId64
  docs/about/emulation: Add documentation for hotblocks plugin arguments
  contrib/plugins/hotblocks: Allow limit to be set as a command line
    argument

 contrib/plugins/hotblocks.c | 20 ++++++++++++++------
 docs/about/emulation.rst    | 12 ++++++++++++
 2 files changed, 26 insertions(+), 6 deletions(-)

-- 
2.50.1
Re: [PATCH 0/5] contrib/plugins/hotblocks: Minor bug fixes and add limit argument
Posted by Manos Pitsidianakis 3 months, 2 weeks ago
Hi Alex,

On Wed, Jul 30, 2025 at 4:19 PM Alex Bradbury <asb@igalia.com> wrote:
>
> This series contains one minor feature addition and a series of small
> bugfixes/improvements. The addition that motivates the submission is to add a
> limit argument for the hotblocks plugin, allowing you to control how many
> blocks are printed rather than being hardcoded to the 20 most executed.
> Setting limit=0 and dumping information about all executed blocks is
> incredibly helpful for an analysis script I have downstream.
>
> This is my first contribution to QEMU. I've attempted to follow all of the
> guidance in the "Submitting a Patch" guide, but apologies if I missed
> anything.
>
> Alex Bradbury (5):
>   contrib/plugins/hotblocks: Correctly free sorted counts list
>   contrib/plugins/hotblocks: Fix off by one error in iteration of sorted
>     blocks
>   contrib/plugins/hotblocks: Print uint64_t with PRIu64 rather than
>     PRId64
>   docs/about/emulation: Add documentation for hotblocks plugin arguments
>   contrib/plugins/hotblocks: Allow limit to be set as a command line
>     argument
>
>  contrib/plugins/hotblocks.c | 20 ++++++++++++++------
>  docs/about/emulation.rst    | 12 ++++++++++++
>  2 files changed, 26 insertions(+), 6 deletions(-)
>
> --
> 2.50.1
>
>

I think the mailing list ate up your first patch. Not your fault
though. I did not receive it in my inbox and it's not on
lore.kernel.org either:

> $ b4 shazam cover.1753857212.git.asb@igalia.com
> Grabbing thread from lore.kernel.org/all/cover.1753857212.git.asb@igalia.com/t.mbox.gz
> Checking for newer revisions
> Grabbing search results from lore.kernel.org
> Analyzing 5 messages in the thread
> Looking for additional code-review trailers on lore.kernel.org
> Analyzing 0 code-review messages
> Checking attestation on all messages, may take a moment...
> ---
>   ERROR: missing [1/5]!
>   ✗ [PATCH 2/5] contrib/plugins/hotblocks: Fix off by one error in iteration of sorted blocks
>     ✗ BADSIG: DKIM/igalia.com
>   ✗ [PATCH 3/5] contrib/plugins/hotblocks: Print uint64_t with PRIu64 rather than PRId64
>     ✗ BADSIG: DKIM/igalia.com
>   ✗ [PATCH 4/5] docs/about/emulation: Add documentation for hotblocks plugin arguments
>     ✗ BADSIG: DKIM/igalia.com
>   ✗ [PATCH 5/5] contrib/plugins/hotblocks: Allow limit to be set as a command line argument
>     ✗ BADSIG: DKIM/igalia.com
> ---
> Total patches: 4
> ---
> WARNING: Thread incomplete!
> Applying: contrib/plugins/hotblocks: Fix off by one error in iteration of sorted blocks
> Patch failed at 0001 contrib/plugins/hotblocks: Fix off by one error in iteration of sorted blocks
> error: sha1 information is lacking or useless (contrib/plugins/hotblocks.c).
> error: could not build fake ancestor

Could you resend it?
Re: [PATCH 0/5] contrib/plugins/hotblocks: Minor bug fixes and add limit argument
Posted by Pierrick Bouvier 3 months, 2 weeks ago
On 7/30/25 6:48 AM, Manos Pitsidianakis wrote:
> Hi Alex,
> 
> On Wed, Jul 30, 2025 at 4:19 PM Alex Bradbury <asb@igalia.com> wrote:
>>
>> This series contains one minor feature addition and a series of small
>> bugfixes/improvements. The addition that motivates the submission is to add a
>> limit argument for the hotblocks plugin, allowing you to control how many
>> blocks are printed rather than being hardcoded to the 20 most executed.
>> Setting limit=0 and dumping information about all executed blocks is
>> incredibly helpful for an analysis script I have downstream.
>>
>> This is my first contribution to QEMU. I've attempted to follow all of the
>> guidance in the "Submitting a Patch" guide, but apologies if I missed
>> anything.
>>
>> Alex Bradbury (5):
>>    contrib/plugins/hotblocks: Correctly free sorted counts list
>>    contrib/plugins/hotblocks: Fix off by one error in iteration of sorted
>>      blocks
>>    contrib/plugins/hotblocks: Print uint64_t with PRIu64 rather than
>>      PRId64
>>    docs/about/emulation: Add documentation for hotblocks plugin arguments
>>    contrib/plugins/hotblocks: Allow limit to be set as a command line
>>      argument
>>
>>   contrib/plugins/hotblocks.c | 20 ++++++++++++++------
>>   docs/about/emulation.rst    | 12 ++++++++++++
>>   2 files changed, 26 insertions(+), 6 deletions(-)
>>
>> --
>> 2.50.1
>>
>>
> 
> I think the mailing list ate up your first patch. Not your fault
> though. I did not receive it in my inbox and it's not on
> lore.kernel.org either:
> 
>> $ b4 shazam cover.1753857212.git.asb@igalia.com
>> Grabbing thread from lore.kernel.org/all/cover.1753857212.git.asb@igalia.com/t.mbox.gz
>> Checking for newer revisions
>> Grabbing search results from lore.kernel.org
>> Analyzing 5 messages in the thread
>> Looking for additional code-review trailers on lore.kernel.org
>> Analyzing 0 code-review messages
>> Checking attestation on all messages, may take a moment...
>> ---
>>    ERROR: missing [1/5]!
>>    ✗ [PATCH 2/5] contrib/plugins/hotblocks: Fix off by one error in iteration of sorted blocks
>>      ✗ BADSIG: DKIM/igalia.com
>>    ✗ [PATCH 3/5] contrib/plugins/hotblocks: Print uint64_t with PRIu64 rather than PRId64
>>      ✗ BADSIG: DKIM/igalia.com
>>    ✗ [PATCH 4/5] docs/about/emulation: Add documentation for hotblocks plugin arguments
>>      ✗ BADSIG: DKIM/igalia.com
>>    ✗ [PATCH 5/5] contrib/plugins/hotblocks: Allow limit to be set as a command line argument
>>      ✗ BADSIG: DKIM/igalia.com
>> ---
>> Total patches: 4
>> ---
>> WARNING: Thread incomplete!
>> Applying: contrib/plugins/hotblocks: Fix off by one error in iteration of sorted blocks
>> Patch failed at 0001 contrib/plugins/hotblocks: Fix off by one error in iteration of sorted blocks
>> error: sha1 information is lacking or useless (contrib/plugins/hotblocks.c).
>> error: could not build fake ancestor
> 
> Could you resend it?

I've been lucky to receive it, probably because I'm in direct copy as a 
plugins reviewer.
However, it would be better for the mailing list if you could resend it 
indeed Alex (you can apply the reviewed-by at the same time, so this v2 
"adds" something).

Regards,
Pierrick

Re: [PATCH 0/5] contrib/plugins/hotblocks: Minor bug fixes and add limit argument
Posted by Alex Bradbury 3 months, 2 weeks ago
On 2025-07-30 14:48, Manos Pitsidianakis wrote:
> Hi Alex,
> 
> On Wed, Jul 30, 2025 at 4:19 PM Alex Bradbury <asb@igalia.com> wrote:
>>
>> This series contains one minor feature addition and a series of small
>> bugfixes/improvements. The addition that motivates the submission is to add a
>> limit argument for the hotblocks plugin, allowing you to control how many
>> blocks are printed rather than being hardcoded to the 20 most executed.
>> Setting limit=0 and dumping information about all executed blocks is
>> incredibly helpful for an analysis script I have downstream.
>>
>> This is my first contribution to QEMU. I've attempted to follow all of the
>> guidance in the "Submitting a Patch" guide, but apologies if I missed
>> anything.
>>
>> Alex Bradbury (5):
>>   contrib/plugins/hotblocks: Correctly free sorted counts list
>>   contrib/plugins/hotblocks: Fix off by one error in iteration of sorted
>>     blocks
>>   contrib/plugins/hotblocks: Print uint64_t with PRIu64 rather than
>>     PRId64
>>   docs/about/emulation: Add documentation for hotblocks plugin arguments
>>   contrib/plugins/hotblocks: Allow limit to be set as a command line
>>     argument
>>
>>  contrib/plugins/hotblocks.c | 20 ++++++++++++++------
>>  docs/about/emulation.rst    | 12 ++++++++++++
>>  2 files changed, 26 insertions(+), 6 deletions(-)
>>
>> --
>> 2.50.1
>>
>>
> 
> I think the mailing list ate up your first patch. Not your fault
> though. I did not receive it in my inbox and it's not on
> lore.kernel.org either:

Thanks for taking a look - it seems like it's made it through now
https://lore.kernel.org/qemu-devel/cf5a00136738b981a12270b76572e8d502daf208.1753857212.git.asb@igalia.com/

Best,

Alex

Re: [PATCH 0/5] contrib/plugins/hotblocks: Minor bug fixes and add limit argument
Posted by Pierrick Bouvier 3 months, 2 weeks ago
On 7/29/25 11:41 PM, Alex Bradbury wrote:
> This series contains one minor feature addition and a series of small
> bugfixes/improvements. The addition that motivates the submission is to add a
> limit argument for the hotblocks plugin, allowing you to control how many
> blocks are printed rather than being hardcoded to the 20 most executed.
> Setting limit=0 and dumping information about all executed blocks is
> incredibly helpful for an analysis script I have downstream.
> 
> This is my first contribution to QEMU. I've attempted to follow all of the
> guidance in the "Submitting a Patch" guide, but apologies if I missed
> anything.
>

Thanks for contributing Alex.

As you probably read, in case a v2 is expected (the plugins maintainer 
Alex will be back next week, he might have additional comments), you can 
add the "Reviewed-by" tags you already collected to your commits by 
ammending their messages.
For the rest, your series looks good to me.

Regards,
Pierrick

> Alex Bradbury (5):
>    contrib/plugins/hotblocks: Correctly free sorted counts list
>    contrib/plugins/hotblocks: Fix off by one error in iteration of sorted
>      blocks
>    contrib/plugins/hotblocks: Print uint64_t with PRIu64 rather than
>      PRId64
>    docs/about/emulation: Add documentation for hotblocks plugin arguments
>    contrib/plugins/hotblocks: Allow limit to be set as a command line
>      argument
> 
>   contrib/plugins/hotblocks.c | 20 ++++++++++++++------
>   docs/about/emulation.rst    | 12 ++++++++++++
>   2 files changed, 26 insertions(+), 6 deletions(-)
>