From: Thomas Zimmermann <tzimmermann@suse.de>
To: Gerd Hoffmann <kraxel@redhat.com>
Cc: daniel@ffwll.ch, airlied@gmail.com, mripard@kernel.org,
maarten.lankhorst@linux.intel.com,
dri-devel@lists.freedesktop.org, virtualization@lists.linux.dev
Subject: Re: [PATCH 00/10] rm/bochs: Modernize driver
Date: Fri, 23 Aug 2024 17:00:43 +0200 [thread overview]
Message-ID: <42389f21-1ddb-428d-8471-92eae5a5f45a@suse.de> (raw)
In-Reply-To: <sksjddgidfrk4bvcxvb46khevp4a4nfvl2holgdw636wld7oov@vdbcvdf3ch6m>
Hi
Am 23.08.24 um 16:34 schrieb Gerd Hoffmann:
> Hi,
>
>> Patch 8 replaces GEM VRAM with GEM SHMEM. The new memory manager
>> is more reliable and allows for larger resolutions.
> Valid point.
>
>> Display updates were so slow that Gnome was unmanageable with a
>> flickering cursor and single FPS. The new memory management makes
>> Gnome at least useable.
> Hmm? I'm wondering where this huge improvement comes from?
>
> With enough video memory VRAM performance should be ok.
>
> If video memory is tight and ttm is forced to shuffle around
> framebuffers between vram and system memory on each page flip (touching
> much of vram along the way which causes additional overhead on the qemu
> side), that is obviously very bad for performance. One of the reasons
> why cirrus uses SHMEM + shadowing since years.
>
> Shadow buffering comes with some overhead too, so the switch isn't an
> obvious win (assuming enough vram). Hiding the page flips from qemu
> might reduce the work qemu has to do though, especially if the shadowing
> uses dirty tracking and only touches the vram pages which have actually
> changed content. So there is a fair chance that this outweighs the
> shadowing overhead and ends up being a net win. I don't expect the
> difference being very big though. Also different display usage patterns
> might yield different results (fbcon vs. gnome for example).
>
> So this probably makes sense, but I'd like to see a bit more background
> information ...
The difference is in damage handling.
The old code had two BOs in video memory and flipped between them. IDK
the details of the old rendering, but from the massive flickering of the
cursor, I assume that X11's internal either copies a full buffer during
each redraw, or doesn't really handle damage well. It could also happen
that X didn't use a shadow buffer for rendering. Bochs didn't request
one. Without, drawing to I/O memory is really slow. If that applies to
virtual I/O memory as well IDK.
The new driver code only copies areas that have been changed from
rendering. The flickering is gone and the overall update performance is
acceptable.
>
> On vram sizes: The default qemu vram size (16M) should be fine for the
> default display resolution (1280x800). For FullHD vram size should be
> doubled (-device VGA,vgamem_mb=32).
Right. Bochs never really tested that. So I saw something like 5k by 3k
resolutions on my test setup with 16 MiB. Now that video-memory
requirements for each mode can be calculated easily, we can sort out the
invalid modes.
>
>
> Skimmed the other patches, looks sane overall, but I don't follow drm
> close enough any more to do an full review. So I leave this here:
>
> Acked-by: Gerd Hoffmann <kraxel@redhat.com>
Thank you so much.
Best regards
Thomas
>
> take care,
> Gerd
>
--
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstrasse 146, 90461 Nuernberg, Germany
GF: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman
HRB 36809 (AG Nuernberg)
next prev parent reply other threads:[~2024-08-23 15:00 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-08-23 12:28 [PATCH 00/10] rm/bochs: Modernize driver Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 01/10] drm/bochs: Remove manual format test from fb_create Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 02/10] drm/bochs: Use helpers for struct drm_edid Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 03/10] drm/bochs: Do managed resource cleanup Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 04/10] drm/bochs: Pass bochs device to various functions Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 05/10] drm/bochs: Upcast with to_bochs_device() Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 06/10] drm/bochs: Allocate DRM device in struct bochs_device Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 07/10] drm/bochs: Use regular atomic helpers Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 08/10] drm/bochs: Use GEM SHMEM helpers for memory management Thomas Zimmermann
2024-08-23 12:28 ` [PATCH 09/10] drm/bochs: Validate display modes against available video memory Thomas Zimmermann
2024-08-29 20:37 ` kernel test robot
2024-08-23 12:28 ` [PATCH 10/10] drm/gem-vram: Remove support for simple display pipelines Thomas Zimmermann
2024-08-23 14:34 ` [PATCH 00/10] rm/bochs: Modernize driver Gerd Hoffmann
2024-08-23 15:00 ` Thomas Zimmermann [this message]
2024-08-26 7:32 ` Gerd Hoffmann
2024-08-26 8:08 ` Thomas Zimmermann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=42389f21-1ddb-428d-8471-92eae5a5f45a@suse.de \
--to=tzimmermann@suse.de \
--cc=airlied@gmail.com \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=kraxel@redhat.com \
--cc=maarten.lankhorst@linux.intel.com \
--cc=mripard@kernel.org \
--cc=virtualization@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox