Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (475)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (530)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Why are primitive operations slower on OGL?  (Read 691 times)
0 Members and 1 Guest are viewing this topic.
Offline Hopper

Junior Newbie





« Posted 2005-06-03 14:13:38 »

Hi there!

I noticet that OGL accerlation speeds up expensive accerlation a lot, but simple operations like drawLine, fill... are slower according to Java2Demo.
It seems especially operations relying OGLFillSpans are slower than on X or GDI.

I tested against: GF460mx, GF5200

cu Hopper
Offline campbell

Junior Member




Java games rock!


« Reply #1 - Posted 2005-06-03 17:39:06 »

Which release are you using?  JDK 5.0 or 6.0?  We've made huge performance improvements, especially for simple primitives (with OGL enabled) in various Mustang builds.  For example, in b27 we improved performance of all operations (e.g. drawLine 20-25x, fillRect 15-20x, drawImage 3-5x).  And in build 39 (should be out today or Monday), I made another performance improvement that improves on those numbers by another 30-60%, depending on the operation.  For more info, see here:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6273431

I think you will find that we are now faster than X11 for many OGL operations in JDK 6.0.  There are still some simple primitives that will be faster with X11, e.g. fillOval, because Xservers have optimized loops for those operations, where as we go through a fillSpans approach.  Even simple fillRects can sometimes be faster with X11 because after all, they have a simple 2D implementation tuned for that sort of thing.  OGL is both a 2D and 3D library, but it can't always do as good a job at optimizing simple 2D operations like these (there's a longer pipeline to go through).

We're always looking at ways to improve performance, so this isn't the final word on the story.

Thanks,
Chris
Offline Hopper

Junior Newbie





« Reply #2 - Posted 2005-06-04 10:25:52 »

Which release are you using?  JDK 5.0 or 6.0?  We've made huge performance improvements, especially for simple primitives (with OGL enabled) in various Mustang builds.  For example, in b27 we improved performance of all operations (e.g. drawLine 20-25x, fillRect 15-20x, drawImage 3-5x).  And in build 39 (should be out today or Monday), I made another performance improvement that improves on those numbers by another 30-60%, depending on the operation.  For more info, see here:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6273431
Thanks for poiting this up - I was referring to mustang-b35.
I have seen great improvements since jdk-1.5, bigger apps like netbeans only even worked on mustang (seems most gl drivers are serious broken) and the netbeans-gui performs 25% faster running on OGL.

1.6 performs very well, especially in areas where i never thought it could - like Sw->Surface blits where it performs sometimes even better than the X11 implementation.

One drawback STR has: Context switching / Process Management overhead. On your dual-power systems you maybe don't see it, but its there (althought its still a lot faster compared to 5.0). Nevermind since dual-cores are coming up, this will also make x-servers fly Wink

Quote
I think you will find that we are now faster than X11 for many OGL operations in JDK 6.0.  There are still some simple primitives that will be faster with X11, e.g. fillOval, because Xservers have optimized loops for those operations, where as we go through a fillSpans approach.  Even simple fillRects can sometimes be faster with X11 because after all, they have a simple 2D implementation tuned for that sort of thing.  OGL is both a 2D and 3D library, but it can't always do as good a job at optimizing simple 2D operations like these (there's a longer pipeline to go through).
Never thought this way - you are right. It must be lot harder for a driver to know howto optimize OGL commands compared to simple blit/drawLine/fillOval stuff 2d systems are optimized for.

Quote
We're always looking at ways to improve performance, so this isn't the final word on the story.
I am definitivly happy to hear that work on OGL will continue - I was a bit sad when I heard the D3D pipeline will be started, because I thought work on OGL will be stoppped. Great to hear this isn't true!


A last thing which would interrest me: Are there any SwingMark results available showing how the different pipelines affect swing?

Thanks a lot, lg Hopper
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

ctomni231 (34 views)
2014-07-18 06:55:21

Zero Volt (30 views)
2014-07-17 23:47:54

danieldean (25 views)
2014-07-17 23:41:23

MustardPeter (27 views)
2014-07-16 23:30:00

Cero (42 views)
2014-07-16 00:42:17

Riven (44 views)
2014-07-14 18:02:53

OpenGLShaders (32 views)
2014-07-14 16:23:47

Riven (31 views)
2014-07-14 11:51:35

quew8 (30 views)
2014-07-13 13:57:52

SHC (66 views)
2014-07-12 17:50:04
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!