Silly things kill SDL/MiniGL performance on the WB screen

This forum is for general developer support questions.
User avatar
Raziel
Posts: 1170
Joined: Sat Jun 18, 2011 4:00 pm
Location: a dying planet

Re: Compositing kills SDL/MiniGL performance on the WB scree

Post by Raziel »

Raziel wrote:...or finally support the whole gfx ram available on a gfx card, instead of only 128 MB...
We'll get there eventually, although that won't help users of older Radeon cards (and the Radeon M9) that genuinely have less than 256 MiB.

Hans
Not to sound harsh, but with the speed of development, the boards using this chip respectively the "older" Radeon cards will be dead and/or upgraded by then anyway.
People who know about the limitations of the M9 will have to live with them, people with older Radeon cards will have to upgrade.

We need to move on! We need to get the new stuff out and not lock development by supporting the old and obsolete!

Heck, thats why i upgraded from an XE to X1K, because i knew about the limitations and wanted to use the new stuff.
People are dying.
Entire ecosystems are collapsing.
We are in the beginning of a mass extinction.
And all you can talk about is money and fairytales of eternal economic growth.
How dare you!
– Greta Thunberg
capehill
Posts: 24
Joined: Sun Jun 18, 2017 1:07 pm

Re: Silly things kill SDL/MiniGL performance on the WB scree

Post by capehill »

@all

I think I found the root cause. Still some more diagnostic to do, but as a last resort, I removed a piece of code that updates window title (some stats), and performance is back. So it is not VRAM/pager issue definitely.

I will try to limit the window title update rate to work around this issue.
User avatar
salass00
AmigaOS Core Developer
AmigaOS Core Developer
Posts: 530
Joined: Sat Jun 18, 2011 3:12 pm
Location: Finland
Contact:

Re: Compositing kills SDL/MiniGL performance on the WB scree

Post by salass00 »

Raziel wrote:
Raziel wrote:...or finally support the whole gfx ram available on a gfx card, instead of only 128 MB...
We'll get there eventually, although that won't help users of older Radeon cards (and the Radeon M9) that genuinely have less than 256 MiB.

Hans
Not to sound harsh, but with the speed of development, the boards using this chip respectively the "older" Radeon cards will be dead and/or upgraded by then anyway.
People who know about the limitations of the M9 will have to live with them, people with older Radeon cards will have to upgrade.

We need to move on! We need to get the new stuff out and not lock development by supporting the old and obsolete!

Heck, thats why i upgraded from an XE to X1K, because i knew about the limitations and wanted to use the new stuff.
Graphics.library being able to use all the video memory of the gfx cards and not just the part that is accessible by the CPU (as the situation is now) would be very useful for newer gfx cards too.
User avatar
Hans
AmigaOS Core Developer
AmigaOS Core Developer
Posts: 703
Joined: Tue Dec 21, 2010 9:25 pm
Location: New Zealand
Contact:

Re: Silly things kill SDL/MiniGL performance on the WB scree

Post by Hans »

@vapehill
capehill wrote:@all

I think I found the root cause. Still some more diagnostic to do, but as a last resort, I removed a piece of code that updates window title (some stats), and performance is back. So it is not VRAM/pager issue definitely.
Glad to hear you figured it out.


@Raziel & Salass0
salass00 wrote:
Raziel wrote: Not to sound harsh, but with the speed of development, the boards using this chip respectively the "older" Radeon cards will be dead and/or upgraded by then anyway.
People who know about the limitations of the M9 will have to live with them, people with older Radeon cards will have to upgrade.

We need to move on! We need to get the new stuff out and not lock development by supporting the old and obsolete!

Heck, thats why i upgraded from an XE to X1K, because i knew about the limitations and wanted to use the new stuff.
Graphics.library being able to use all the video memory of the gfx cards and not just the part that is accessible by the CPU (as the situation is now) would be very useful for newer gfx cards too.
I agree with both of you, and I've been focusing on newer hardware precisely for that reason. Rest assured that the old stuff isn't holding us back. In fact, I designed the Radeon_RM.resource so that it could use all of VRAM even though the graphics.library can't (without a major rewrite). Like I said, we'll get there.

Hans
http://hdrlab.org.nz/ - Amiga OS 4 projects, programming articles and more. Home of the RadeonHD driver for Amiga OS 4.x project.
capehill
Posts: 24
Joined: Sun Jun 18, 2017 1:07 pm

Re: Silly things kill SDL/MiniGL performance on the WB scree

Post by capehill »

I did a small window title "benchmark". On Sam440ep M9 combo setting window title is about 10x slower when compositing is enabled. 1000 changes takes 7 seconds. Without compositing it takes about 0,8 seconds.

I will paste the code here if somebody is interested.

Code: Select all

/*

Compile with:

gcc windowtitle.c -lauto

*/

#include <proto/intuition.h>
#include <time.h>
#include <stdio.h>

int main(void)
{
	struct Window *w = IIntuition->OpenWindowTags(
		NULL,
		WA_Title, "Window Title",
		WA_InnerWidth, 100,
		WA_InnerHeight, 100,
		TAG_DONE);

	if (w) {
		STRPTR title = "blab blab";
		int i;

		struct timeval start, finish;
		long long duration;

		gettimeofday(&start, NULL);

		for (i = 0; i < 1000; i++) {
			IIntuition->SetWindowTitles(w, title, title);
		}
		
		gettimeofday(&finish, NULL);

		duration = 1000000 * finish.tv_sec + finish.tv_usec;
		duration -= (1000000 * start.tv_sec + start.tv_usec);
	
		printf("Took %llu microseconds\n", duration);

		IIntuition->CloseWindow(w);
	}

	return 0;
}
xenic
Posts: 1185
Joined: Sun Jun 19, 2011 12:06 am

Re: Silly things kill SDL/MiniGL performance on the WB scree

Post by xenic »

capehill wrote:I did a small window title "benchmark". On Sam440ep M9 combo setting window title is about 10x slower when compositing is enabled. 1000 changes takes 7 seconds. Without compositing it takes about 0,8 seconds.
I compiled and tried your test code on my X5000 and the difference between conpositing and non-compositing was insignificant so the problem does appear to be hardware related.
Without compositing: Took 390390 microseconds
With compositing on: Took 405765 microseconds
AmigaOne X1000 with 2GB memory - OS4.1 FE
User avatar
javierdlr
Beta Tester
Beta Tester
Posts: 389
Joined: Sun Jun 19, 2011 10:13 pm
Location: Donostia (GUIPUZCOA) - Spain
Contact:

Re: Silly things kill SDL/MiniGL performance on the WB scree

Post by javierdlr »

#gcc windowtitle.c -lauto
#a.out [COMPOSITING DISABLED]
Took 100650 microseconds
#a.out [COMPOSITING ENABLED]
Took 113135 microseconds
#cpu
Sistema: AMCC PPC460EX (MC68020/FPU emulado) (INST:NoCaché)
Caché CPU: L1=32768 bytes, L2=262144 bytes.
#

RadeonHD 6570 & RadeonHD.chip 2.22 (25.3.2017)
Post Reply