* [Qemu-devel] [Bug 1618122] [NEW] qemu-monitor screendump very slow
@ 2016-08-29 16:00 vans163
2016-08-29 17:39 ` [Qemu-devel] [Bug 1618122] " vans163
` (5 more replies)
0 siblings, 6 replies; 7+ messages in thread
From: vans163 @ 2016-08-29 16:00 UTC (permalink / raw)
To: qemu-devel
Public bug reported:
qemu-monitor screendump often using 10-20% cpu usage of one core to take
a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
56,592,286,124 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
40,288,379,712 ???:0x000000000000caa0 [/usr/lib64/libpixman-1.so.0.34.0]
3,585,795,168 ???:0x000000000006df20 [/usr/lib64/libpixman-1.so.0.34.0]
1,763,982,432 ???:0x0000000000052360 [/usr/lib64/libpixman-1.so.0.34.0]
1,517,832,033 ???:__memcpy_sse2_unaligned [/usr/lib64/libc-2.23.so]
993,997,885 ???:__GI_mempcpy [/usr/lib64/libc-2.23.so]
484,059,456 ???:0x0000000000050430 [/usr/lib64/libpixman-1.so.0.34.0]
460,109,168 ???:pixman_image_composite32 [/usr/lib64/libpixman-1.so.0.34.0]
I tried taking a look on how to fix this, but it seems pixman is deeply
enrooted inside the monitor. I wanted to try to simply take whats on
the display and memcpy it into .ppm format manually creating the file
header, but I cant figure out where the raw display buffer/image is
gotten from.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should just
work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp. No
need for libpixman.
** Affects: qemu
Importance: Undecided
Status: New
** Description changed:
qemu-monitor screendump often using 10-20% cpu usage of one core to take
a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
-
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
- Ir
+ Ir
--------------------------------------------------------------------------------
56,592,286,124 PROGRAM TOTALS
--------------------------------------------------------------------------------
- Ir file:function
+ Ir file:function
--------------------------------------------------------------------------------
40,288,379,712 ???:0x000000000000caa0 [/usr/lib64/libpixman-1.so.0.34.0]
- 3,585,795,168 ???:0x000000000006df20 [/usr/lib64/libpixman-1.so.0.34.0]
- 1,763,982,432 ???:0x0000000000052360 [/usr/lib64/libpixman-1.so.0.34.0]
- 1,517,832,033 ???:__memcpy_sse2_unaligned [/usr/lib64/libc-2.23.so]
- 993,997,885 ???:__GI_mempcpy [/usr/lib64/libc-2.23.so]
- 484,059,456 ???:0x0000000000050430 [/usr/lib64/libpixman-1.so.0.34.0]
- 460,109,168 ???:pixman_image_composite32 [/usr/lib64/libpixman-1.so.0.34.0]
+ 3,585,795,168 ???:0x000000000006df20 [/usr/lib64/libpixman-1.so.0.34.0]
+ 1,763,982,432 ???:0x0000000000052360 [/usr/lib64/libpixman-1.so.0.34.0]
+ 1,517,832,033 ???:__memcpy_sse2_unaligned [/usr/lib64/libc-2.23.so]
+ 993,997,885 ???:__GI_mempcpy [/usr/lib64/libc-2.23.so]
+ 484,059,456 ???:0x0000000000050430 [/usr/lib64/libpixman-1.so.0.34.0]
+ 460,109,168 ???:pixman_image_composite32 [/usr/lib64/libpixman-1.so.0.34.0]
- I tried taking a look on how to fix this, but it seems pixmap is deeply
+ I tried taking a look on how to fix this, but it seems pixman is deeply
enrooted inside the monitor. I wanted to try to simply take whats on
the display and memcpy it into .ppm format manually creating the file
header, but I cant figure out where the raw display buffer/image starts.
For example this is DisplaySurface:
struct DisplaySurface {
- pixman_format_code_t format;
- pixman_image_t *image;
- uint8_t flags;
+ pixman_format_code_t format;
+ pixman_image_t *image;
+ uint8_t flags;
#ifdef CONFIG_OPENGL
- GLenum glformat;
- GLenum gltype;
- GLuint texture;
+ GLenum glformat;
+ GLenum gltype;
+ GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should just
work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp. No
need for libpixman.
** Description changed:
qemu-monitor screendump often using 10-20% cpu usage of one core to take
a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
56,592,286,124 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
40,288,379,712 ???:0x000000000000caa0 [/usr/lib64/libpixman-1.so.0.34.0]
3,585,795,168 ???:0x000000000006df20 [/usr/lib64/libpixman-1.so.0.34.0]
1,763,982,432 ???:0x0000000000052360 [/usr/lib64/libpixman-1.so.0.34.0]
1,517,832,033 ???:__memcpy_sse2_unaligned [/usr/lib64/libc-2.23.so]
993,997,885 ???:__GI_mempcpy [/usr/lib64/libc-2.23.so]
484,059,456 ???:0x0000000000050430 [/usr/lib64/libpixman-1.so.0.34.0]
460,109,168 ???:pixman_image_composite32 [/usr/lib64/libpixman-1.so.0.34.0]
I tried taking a look on how to fix this, but it seems pixman is deeply
enrooted inside the monitor. I wanted to try to simply take whats on
the display and memcpy it into .ppm format manually creating the file
- header, but I cant figure out where the raw display buffer/image starts.
+ header, but I cant figure out where the raw display buffer/image is
+ gotten from.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should just
work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp. No
need for libpixman.
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1618122
Title:
qemu-monitor screendump very slow
Status in QEMU:
New
Bug description:
qemu-monitor screendump often using 10-20% cpu usage of one core to
take a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
56,592,286,124 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
40,288,379,712 ???:0x000000000000caa0 [/usr/lib64/libpixman-1.so.0.34.0]
3,585,795,168 ???:0x000000000006df20 [/usr/lib64/libpixman-1.so.0.34.0]
1,763,982,432 ???:0x0000000000052360 [/usr/lib64/libpixman-1.so.0.34.0]
1,517,832,033 ???:__memcpy_sse2_unaligned [/usr/lib64/libc-2.23.so]
993,997,885 ???:__GI_mempcpy [/usr/lib64/libc-2.23.so]
484,059,456 ???:0x0000000000050430 [/usr/lib64/libpixman-1.so.0.34.0]
460,109,168 ???:pixman_image_composite32 [/usr/lib64/libpixman-1.so.0.34.0]
I tried taking a look on how to fix this, but it seems pixman is
deeply enrooted inside the monitor. I wanted to try to simply take
whats on the display and memcpy it into .ppm format manually creating
the file header, but I cant figure out where the raw display
buffer/image is gotten from.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should
just work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp.
No need for libpixman.
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1618122/+subscriptions
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Qemu-devel] [Bug 1618122] Re: qemu-monitor screendump very slow
2016-08-29 16:00 [Qemu-devel] [Bug 1618122] [NEW] qemu-monitor screendump very slow vans163
@ 2016-08-29 17:39 ` vans163
2016-08-29 18:55 ` vans163
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: vans163 @ 2016-08-29 17:39 UTC (permalink / raw)
To: qemu-devel
Most of the CPU is coming from ppm_save(filename, surface, errp);
graphic_hw_update(con) takes an insignificant amount.
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1618122
Title:
qemu-monitor screendump very slow
Status in QEMU:
New
Bug description:
qemu-monitor screendump often using 10-20% cpu usage of one core to
take a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
56,592,286,124 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
40,288,379,712 ???:0x000000000000caa0 [/usr/lib64/libpixman-1.so.0.34.0]
3,585,795,168 ???:0x000000000006df20 [/usr/lib64/libpixman-1.so.0.34.0]
1,763,982,432 ???:0x0000000000052360 [/usr/lib64/libpixman-1.so.0.34.0]
1,517,832,033 ???:__memcpy_sse2_unaligned [/usr/lib64/libc-2.23.so]
993,997,885 ???:__GI_mempcpy [/usr/lib64/libc-2.23.so]
484,059,456 ???:0x0000000000050430 [/usr/lib64/libpixman-1.so.0.34.0]
460,109,168 ???:pixman_image_composite32 [/usr/lib64/libpixman-1.so.0.34.0]
I tried taking a look on how to fix this, but it seems pixman is
deeply enrooted inside the monitor. I wanted to try to simply take
whats on the display and memcpy it into .ppm format manually creating
the file header, but I cant figure out where the raw display
buffer/image is gotten from.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should
just work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp.
No need for libpixman.
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1618122/+subscriptions
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Qemu-devel] [Bug 1618122] Re: qemu-monitor screendump very slow
2016-08-29 16:00 [Qemu-devel] [Bug 1618122] [NEW] qemu-monitor screendump very slow vans163
2016-08-29 17:39 ` [Qemu-devel] [Bug 1618122] " vans163
@ 2016-08-29 18:55 ` vans163
2016-08-29 19:01 ` vans163
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: vans163 @ 2016-08-29 18:55 UTC (permalink / raw)
To: qemu-devel
** Description changed:
qemu-monitor screendump often using 10-20% cpu usage of one core to take
a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
- Ir
+ Ir
--------------------------------------------------------------------------------
- 56,592,286,124 PROGRAM TOTALS
+ 9,994,313,959 PROGRAM TOTALS
--------------------------------------------------------------------------------
- Ir file:function
+ Ir file:function
--------------------------------------------------------------------------------
- 40,288,379,712 ???:0x000000000000caa0 [/usr/lib64/libpixman-1.so.0.34.0]
- 3,585,795,168 ???:0x000000000006df20 [/usr/lib64/libpixman-1.so.0.34.0]
- 1,763,982,432 ???:0x0000000000052360 [/usr/lib64/libpixman-1.so.0.34.0]
- 1,517,832,033 ???:__memcpy_sse2_unaligned [/usr/lib64/libc-2.23.so]
- 993,997,885 ???:__GI_mempcpy [/usr/lib64/libc-2.23.so]
- 484,059,456 ???:0x0000000000050430 [/usr/lib64/libpixman-1.so.0.34.0]
- 460,109,168 ???:pixman_image_composite32 [/usr/lib64/libpixman-1.so.0.34.0]
+ 4,883,603,360 /usr/src/debug/pixman-0.34.0/pixman/pixman-access.c:store_scanline_b8g8r8 [/usr/lib64/libpixman-1.so.0.34.0]
+ 282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
+ 267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
+ 256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
+ 254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
+ 199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
- I tried taking a look on how to fix this, but it seems pixman is deeply
- enrooted inside the monitor. I wanted to try to simply take whats on
- the display and memcpy it into .ppm format manually creating the file
- header, but I cant figure out where the raw display buffer/image is
- gotten from.
+
+ I tried taking a look on how to fix this, but it seems pixman is deeply enrooted inside the monitor. I wanted to try to simply take whats on the display and memcpy it into .ppm format manually creating the file header, but I cant figure out where the raw display buffer/image is gotten from.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should just
work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp. No
need for libpixman.
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1618122
Title:
qemu-monitor screendump very slow
Status in QEMU:
New
Bug description:
qemu-monitor screendump often using 10-20% cpu usage of one core to
take a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
9,994,313,959 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
4,883,603,360 /usr/src/debug/pixman-0.34.0/pixman/pixman-access.c:store_scanline_b8g8r8 [/usr/lib64/libpixman-1.so.0.34.0]
282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
I tried taking a look on how to fix this, but it seems pixman is deeply enrooted inside the monitor. I wanted to try to simply take whats on the display and memcpy it into .ppm format manually creating the file header, but I cant figure out where the raw display buffer/image is gotten from.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should
just work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp.
No need for libpixman.
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1618122/+subscriptions
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Qemu-devel] [Bug 1618122] Re: qemu-monitor screendump very slow
2016-08-29 16:00 [Qemu-devel] [Bug 1618122] [NEW] qemu-monitor screendump very slow vans163
2016-08-29 17:39 ` [Qemu-devel] [Bug 1618122] " vans163
2016-08-29 18:55 ` vans163
@ 2016-08-29 19:01 ` vans163
2016-08-31 12:53 ` vans163
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: vans163 @ 2016-08-29 19:01 UTC (permalink / raw)
To: qemu-devel
** Description changed:
qemu-monitor screendump often using 10-20% cpu usage of one core to take
a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
- Ir
+ Ir
--------------------------------------------------------------------------------
9,994,313,959 PROGRAM TOTALS
--------------------------------------------------------------------------------
- Ir file:function
+ Ir file:function
--------------------------------------------------------------------------------
4,883,603,360 /usr/src/debug/pixman-0.34.0/pixman/pixman-access.c:store_scanline_b8g8r8 [/usr/lib64/libpixman-1.so.0.34.0]
- 282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
- 267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
- 256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
- 254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
- 199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
+ 282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
+ 267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
+ 256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
+ 254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
+ 199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
+
+ Calls to there start from.
+ qemu_pixman_linebuf_fill
+ pixman_image_composite
+ ????
+ pixman_image_composite32
+ general_composite_rect
I tried taking a look on how to fix this, but it seems pixman is deeply enrooted inside the monitor. I wanted to try to simply take whats on the display and memcpy it into .ppm format manually creating the file header, but I cant figure out where the raw display buffer/image is gotten from.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should just
work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp. No
need for libpixman.
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1618122
Title:
qemu-monitor screendump very slow
Status in QEMU:
New
Bug description:
qemu-monitor screendump often using 10-20% cpu usage of one core to
take a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
9,994,313,959 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
4,883,603,360 /usr/src/debug/pixman-0.34.0/pixman/pixman-access.c:store_scanline_b8g8r8 [/usr/lib64/libpixman-1.so.0.34.0]
282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
Calls to there start from.
qemu_pixman_linebuf_fill
pixman_image_composite
????
pixman_image_composite32
general_composite_rect
I tried taking a look on how to fix this, but it seems pixman is deeply enrooted inside the monitor. I wanted to try to simply take whats on the display and memcpy it into .ppm format manually creating the file header, but I cant figure out where the raw display buffer/image is gotten from.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
Which as you can see already has the pixman_image_t. Maybe I should
just work with that pixman_image_t?
The most effective solution IMO seems to just memcpy from the display
into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp.
No need for libpixman.
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1618122/+subscriptions
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Qemu-devel] [Bug 1618122] Re: qemu-monitor screendump very slow
2016-08-29 16:00 [Qemu-devel] [Bug 1618122] [NEW] qemu-monitor screendump very slow vans163
` (2 preceding siblings ...)
2016-08-29 19:01 ` vans163
@ 2016-08-31 12:53 ` vans163
2021-04-22 5:21 ` Thomas Huth
2021-06-22 4:17 ` Launchpad Bug Tracker
5 siblings, 0 replies; 7+ messages in thread
From: vans163 @ 2016-08-31 12:53 UTC (permalink / raw)
To: qemu-devel
** Description changed:
qemu-monitor screendump often using 10-20% cpu usage of one core to take
a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
9,994,313,959 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
4,883,603,360 /usr/src/debug/pixman-0.34.0/pixman/pixman-access.c:store_scanline_b8g8r8 [/usr/lib64/libpixman-1.so.0.34.0]
282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
Calls to there start from.
qemu_pixman_linebuf_fill
pixman_image_composite
????
pixman_image_composite32
general_composite_rect
-
- I tried taking a look on how to fix this, but it seems pixman is deeply enrooted inside the monitor. I wanted to try to simply take whats on the display and memcpy it into .ppm format manually creating the file header, but I cant figure out where the raw display buffer/image is gotten from.
+ I tried taking a look on how to fix this, but it seems pixman is deeply
+ enrooted inside the monitor. I wanted to try to simply take whats on
+ the display and memcpy it into .ppm format manually creating the file
+ header, but the image is all broken with colors being off or its
+ smeared.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
- Which as you can see already has the pixman_image_t. Maybe I should just
- work with that pixman_image_t?
- The most effective solution IMO seems to just memcpy from the display
- into a premade header for a .ppm or .bmp file assuming 24 or 32 bpp. No
- need for libpixman.
+ It appears graphic_hw_update(con) renders the vram to a pixman_image. Then ppm_save(filename, surface, errp) goes over it yet again, mutates the bytes in an expensive way to another pixman_image, and saves that row by row to a ppm.
+
+ Using sdl graphics (the default) the drawing starts in
+ https://github.com/qemu/qemu/blob/7fa124b273acd22a808e742ead78c065ccd9b4c4/hw/display/vga.c#L1466
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1618122
Title:
qemu-monitor screendump very slow
Status in QEMU:
New
Bug description:
qemu-monitor screendump often using 10-20% cpu usage of one core to
take a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
9,994,313,959 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
4,883,603,360 /usr/src/debug/pixman-0.34.0/pixman/pixman-access.c:store_scanline_b8g8r8 [/usr/lib64/libpixman-1.so.0.34.0]
282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
Calls to there start from.
qemu_pixman_linebuf_fill
pixman_image_composite
????
pixman_image_composite32
general_composite_rect
I tried taking a look on how to fix this, but it seems pixman is
deeply enrooted inside the monitor. I wanted to try to simply take
whats on the display and memcpy it into .ppm format manually creating
the file header, but the image is all broken with colors being off or
its smeared.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
It appears graphic_hw_update(con) renders the vram to a pixman_image. Then ppm_save(filename, surface, errp) goes over it yet again, mutates the bytes in an expensive way to another pixman_image, and saves that row by row to a ppm.
Using sdl graphics (the default) the drawing starts in
https://github.com/qemu/qemu/blob/7fa124b273acd22a808e742ead78c065ccd9b4c4/hw/display/vga.c#L1466
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1618122/+subscriptions
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug 1618122] Re: qemu-monitor screendump very slow
2016-08-29 16:00 [Qemu-devel] [Bug 1618122] [NEW] qemu-monitor screendump very slow vans163
` (3 preceding siblings ...)
2016-08-31 12:53 ` vans163
@ 2021-04-22 5:21 ` Thomas Huth
2021-06-22 4:17 ` Launchpad Bug Tracker
5 siblings, 0 replies; 7+ messages in thread
From: Thomas Huth @ 2021-04-22 5:21 UTC (permalink / raw)
To: qemu-devel
The QEMU project is currently considering to move its bug tracking to
another system. For this we need to know which bugs are still valid
and which could be closed already. Thus we are setting older bugs to
"Incomplete" now.
If you still think this bug report here is valid, then please switch
the state back to "New" within the next 60 days, otherwise this report
will be marked as "Expired". Or please mark it as "Fix Released" if
the problem has been solved with a newer version of QEMU already.
Thank you and sorry for the inconvenience.
** Changed in: qemu
Status: New => Incomplete
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1618122
Title:
qemu-monitor screendump very slow
Status in QEMU:
Incomplete
Bug description:
qemu-monitor screendump often using 10-20% cpu usage of one core to
take a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
9,994,313,959 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
4,883,603,360 /usr/src/debug/pixman-0.34.0/pixman/pixman-access.c:store_scanline_b8g8r8 [/usr/lib64/libpixman-1.so.0.34.0]
282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
Calls to there start from.
qemu_pixman_linebuf_fill
pixman_image_composite
????
pixman_image_composite32
general_composite_rect
I tried taking a look on how to fix this, but it seems pixman is
deeply enrooted inside the monitor. I wanted to try to simply take
whats on the display and memcpy it into .ppm format manually creating
the file header, but the image is all broken with colors being off or
its smeared.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
It appears graphic_hw_update(con) renders the vram to a pixman_image. Then ppm_save(filename, surface, errp) goes over it yet again, mutates the bytes in an expensive way to another pixman_image, and saves that row by row to a ppm.
Using sdl graphics (the default) the drawing starts in
https://github.com/qemu/qemu/blob/7fa124b273acd22a808e742ead78c065ccd9b4c4/hw/display/vga.c#L1466
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1618122/+subscriptions
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug 1618122] Re: qemu-monitor screendump very slow
2016-08-29 16:00 [Qemu-devel] [Bug 1618122] [NEW] qemu-monitor screendump very slow vans163
` (4 preceding siblings ...)
2021-04-22 5:21 ` Thomas Huth
@ 2021-06-22 4:17 ` Launchpad Bug Tracker
5 siblings, 0 replies; 7+ messages in thread
From: Launchpad Bug Tracker @ 2021-06-22 4:17 UTC (permalink / raw)
To: qemu-devel
[Expired for QEMU because there has been no activity for 60 days.]
** Changed in: qemu
Status: Incomplete => Expired
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1618122
Title:
qemu-monitor screendump very slow
Status in QEMU:
Expired
Bug description:
qemu-monitor screendump often using 10-20% cpu usage of one core to
take a small capture.
Most of the CPU usage seems to come from libpixman. There were many
reports of libpixman becoming 8 times slower in newer releases.
https://github.com/qemu/qemu/blob/0c56c6ab68902281094c7aac6305e2321c34c187/ui/console.c#L285
Simple Valgrind Ir report.
--------------------------------------------------------------------------------
Ir
--------------------------------------------------------------------------------
9,994,313,959 PROGRAM TOTALS
--------------------------------------------------------------------------------
Ir file:function
--------------------------------------------------------------------------------
4,883,603,360 /usr/src/debug/pixman-0.34.0/pixman/pixman-access.c:store_scanline_b8g8r8 [/usr/lib64/libpixman-1.so.0.34.0]
282,312,800 /usr/src/debug/pixman-0.34.0/pixman/pixman-implementation.c:_pixman_implementation_iter_init [/usr/lib64/libpixman-1.so.0.34.0]
267,394,160 /usr/src/debug/pixman-0.34.0/pixman/pixman-sse2.c:sse2_fetch_x8r8g8b8 [/usr/lib64/libpixman-1.so.0.34.0]
256,761,600 /usr/src/debug/pixman-0.34.0/pixman/pixman-private.h:store_scanline_b8g8r8
254,676,199 ???:0x0000000000011f40 [/usr/lib64/libjemalloc.so.2]
199,990,526 ???:0x0000000000011a10 [/usr/lib64/libjemalloc.so.2]
Calls to there start from.
qemu_pixman_linebuf_fill
pixman_image_composite
????
pixman_image_composite32
general_composite_rect
I tried taking a look on how to fix this, but it seems pixman is
deeply enrooted inside the monitor. I wanted to try to simply take
whats on the display and memcpy it into .ppm format manually creating
the file header, but the image is all broken with colors being off or
its smeared.
For example this is DisplaySurface:
struct DisplaySurface {
pixman_format_code_t format;
pixman_image_t *image;
uint8_t flags;
#ifdef CONFIG_OPENGL
GLenum glformat;
GLenum gltype;
GLuint texture;
#endif
};
It appears graphic_hw_update(con) renders the vram to a pixman_image. Then ppm_save(filename, surface, errp) goes over it yet again, mutates the bytes in an expensive way to another pixman_image, and saves that row by row to a ppm.
Using sdl graphics (the default) the drawing starts in
https://github.com/qemu/qemu/blob/7fa124b273acd22a808e742ead78c065ccd9b4c4/hw/display/vga.c#L1466
To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1618122/+subscriptions
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2021-06-22 4:56 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-29 16:00 [Qemu-devel] [Bug 1618122] [NEW] qemu-monitor screendump very slow vans163
2016-08-29 17:39 ` [Qemu-devel] [Bug 1618122] " vans163
2016-08-29 18:55 ` vans163
2016-08-29 19:01 ` vans163
2016-08-31 12:53 ` vans163
2021-04-22 5:21 ` Thomas Huth
2021-06-22 4:17 ` Launchpad Bug Tracker
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.