Skip to main content

Extremely slow performance, even after reinstalling windows

7 replies [Last post]
deaars
Offline
Joined: 2008-03-17

Hi everyone,
I have a strange problem with my current hardware configuration, java runs really slow on it. Currently I am working on a simple 2D RTS game, to practice a little. But when I made my game run full-screen, I noticed the performance is really bad, constantly around 2 seconds per frame. In the non-fullscreen level editor, which is already finished, I didn't notice the problem at first, but it is also less responsive than on other machines. At first I tought it could be a messed up Windows installation, it wasn

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
swv
Offline
Joined: 2007-05-28

I noticed supernaturally slow performance in NB and other java apps if I have certain other java apps running (which shall remain nameless)... I assume it's a memory leak in those other apps, but I am not sure why it impacts performance on java apps as opposed to other apps.. it's as though there's some leakage between VMS (which I am not saying there is, because I'm sure that's not possible )... but the effect is very very very slow scrolling and redraw... like.. VERY slow...

just a datapoint.

trembovetski
Offline
Joined: 2003-12-31

Is this with 6u10 or other release? What release the "other" apps are running?
What platform?

Dmitri

trembovetski
Offline
Joined: 2003-12-31

What java version is that on?

Could you try this:
[code]
#> set J2D_TRACE_LEVEL=4
#> java -jar YourApp.jar
[/code]

then run your app for a bit, quit it and post the output?

Also, could you try with -Dsun.java2d.d3d=false ? This will probably
help.

And, have you tried the upcoming 6u10 release (available from http://jdk6.dev.java.net)?

Dmitri

deaars
Offline
Joined: 2008-03-17

Thanks for your quick reply.
The java version I use is 6u5
I tried to run the program with -Dsun.java2d.d3d=false, but this didnt solve the problem.

Here is the output when running with the trace level set to 4:

[W] GetFlagValues: DDraw screen locking is disabled (W2K, XP+)
[I] InitDirectX
[V] CheckRegistry: Found Display Device 0: NVIDIA GeForce 8800 GTS
[V] CheckRegistry: Found Display Device 1: NVIDIA GeForce 8800 GTS
[I] CreateDevice: lpGUID=0x90cfb8 hMon=0x10003
[I] DDSetupDevice
[I] DDraw::CreateDDPrimarySurface: back-buffers=0
[V] DDSetupDevice: successfully created primary surface
[V] DDSetupDevice: successfully setup ddraw device
[I] CreateDevice: lpGUID=0x90cfb8 hMon=0x10001
[I] DDSetupDevice
[I] DDraw::CreateDDPrimarySurface: back-buffers=0
[V] DDSetupDevice: successfully created primary surface
[V] DDSetupDevice: successfully setup ddraw device
[I] InitDirectX
[V] CheckRegistry: Found Display Device 0: NVIDIA GeForce 8800 GTS
[V] CheckRegistry: Found Display Device 1: NVIDIA GeForce 8800 GTS
[I] DDSetupDevice
[I] DDraw::CreateDDPrimarySurface: back-buffers=0
[V] DDSetupDevice: successfully created primary surface
[V] DDSetupDevice: successfully setup ddraw device
[I] D3DContext::D3DContext
[V] D3DUtils_SelectDeviceGUID: using TNL rasterizer
[I] D3DContext::CreateD3DDevice
[I] D3DContext::CreateAndTestD3DDevice
[I] D3DContext::InitD3DDevice: d3dDevice=Oxb9a80
[V] D3DContext::CreateAndTestD3DDevice: D3D device creation/initialization succe
ssful
[W] TestRenderingResults: Quality test failed due to value ff at (34, 0)
[I] CreateD3DDevice: tests PASSED, d3d enabled (forced: no).
[I] DDSetupDevice
[I] DDraw::CreateDDPrimarySurface: back-buffers=1
[V] DDSetupDevice: successfully created primary surface
[V] DDSetupDevice: successfully setup ddraw device
[I] D3DContext::CreateD3DDevice
[I] D3DContext::CreateAndTestD3DDevice
[I] D3DContext::InitD3DDevice: d3dDevice=Oxb9a80
[V] D3DContext::CreateAndTestD3DDevice: D3D device creation/initialization succe
ssful
[W] TestRenderingResults: Quality test failed due to value ff at (34, 0)
[I] CreateD3DDevice: tests PASSED, d3d enabled (forced: no).
[I] InitDirectX
[V] CheckRegistry: Found Display Device 0: NVIDIA GeForce 8800 GTS
[V] CheckRegistry: Found Display Device 1: NVIDIA GeForce 8800 GTS
[I] InitDirectX
[V] CheckRegistry: Found Display Device 0: NVIDIA GeForce 8800 GTS
[V] CheckRegistry: Found Display Device 1: NVIDIA GeForce 8800 GTS
[E] DDraw::SetCooperativeLevel: lpPrimary->Restore() failed: DirectDraw Error: D
DERR_WRONGMODE
[E] DDCreateSurface: failed to restore primary surface

trembovetski
Offline
Joined: 2003-12-31

OK, thanks.

Could you try running with -Dsun.java2d.trace=count and post the output
when the app exits?

Also, please do try 6u10.

Thanks,
Dmitri

deaars
Offline
Joined: 2008-03-17

After installing 6u10 the app runs fine. Thanks for your help!

EDIT: When I try to run it in NetBeans, it still runs slow. The source level has been set to 6. I probably forgot another setting option, but I dont know what. Do you have a suggestion?

Message was edited by: deaars

trembovetski
Offline
Joined: 2003-12-31

Double check that netbeans now runs on 6u10. I'm running NB6 on my system
on 6u10 and it works pretty well.

Dmitri