qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PPC440 tlbwe


From: BALATON Zoltan
Subject: Re: PPC440 tlbwe
Date: Mon, 13 Nov 2023 13:05:10 +0100 (CET)

On Mon, 13 Nov 2023, Nicholas Piggin wrote:
On Mon Nov 13, 2023 at 6:38 AM AEST, BALATON Zoltan wrote:
On Wed, 25 Oct 2023, Nicholas Piggin wrote:
On Wed Oct 25, 2023 at 2:01 AM AEST, BALATON Zoltan wrote:
On Wed, 11 Oct 2023, Nicholas Piggin wrote:
On Tue Oct 10, 2023 at 10:41 PM AEST, BALATON Zoltan wrote:
Hello,

I have a question about tlbwe emulation in TCG for PPC440. This seems to
be implemented in mmu_helper.c::helper_440_tlbwe which calls tlb_flush a
lot flushing all TLB entries. This causes a big performance hit with
sam460ex running AmigaOS which seems to do tlbwe on every task or context
switch so it runs much slower than on other machines with a G4 CPU
(pegasos2 and amigaone we also emulate) that use hardware TLB which does
not have such problem in TCG. Even the embedded TLB emulation has 3
versions for 40x, 440 and BookE 2.06 (I think that's e500) and at least
the booke206 version uses flush_page instead of flushing everything. I
don't know much about this so is there somebody with better understanding
of this who can have a look at it and see if it can be optimised to
resolve this problem or give some advice?

It looks like 440 might be able to use the same page flushing as 4xx.

This patch is only compile tested and I don't know the book E TLB stuff
too well but it may give you a starting point.

A few more people gave this some testing and it seems to work and found no
breakage so far. Do you plan to make it a porper patch and merge it
sometimes?

Performance is improved do you think? I can give it a try. I may try to
do the fix patches separately ahead of the performance patch. It would
be nice if those could be confirmed to fix a problem, but understand
it can be difficult to set up and hit TLB bugs.

Nick,

Are you still around?

Hey, a personal issue came up and I had to drop everything for a few
weeks (thanks to Daniel and others for stepping in to help). That's
over now, I'll try to start picking up the pieces again. Sorry if I
miss things...

Too bad this patch hasn't been followed up on after
the reply showing performance increase with it but since it can also be
considered fixing actual bugs is there a chance for this to still be in
8.2 release?

This may still be okay a a bug-fix. Separating the performance
improvement from the bug fix might actually not make it much simpler
but I'll see what it looks like.

I care more about the performance improvement as the bugs did not happen with the guests I run (they are probably corner cases that don't happen in practice) and keeping it as one patch might also be simpler but up to you.

Regards,
BALATON Zoltan

Thanks,
Nick


(Here's a link to the original trhread for reference:
https://lists.nongnu.org/archive/html/qemu-ppc/2023-10/msg00334.html )

Regards,
BALATON Zoltan






reply via email to

[Prev in Thread] Current Thread [Next in Thread]