JDK-6933331 : (d3d/ogl) java.lang.IllegalStateException: Buffers have not been created
  • Type: Bug
  • Component: client-libs
  • Sub-Component: 2d
  • Affected Version: 6u18,7,11,12,13
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • OS: windows_xp,windows_vista
  • CPU: x86
  • Submitted: 2010-03-09
  • Updated: 2020-02-26
  • Resolved: 2019-05-19
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11 JDK 13 JDK 14
11.0.8-oracleFixed 13 b24Fixed 14Fixed
Related Reports
Duplicate :  
Duplicate :  
Relates :  
Relates :  
Description
FULL PRODUCT VERSION :
java version "1.6.0_18"
Java(TM) SE Runtime Environment (build 1.6.0_18-b07)
Java HotSpot(TM) Client VM (build 16.0-b13, mixed mode, sharing)

ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows [Version 6.0.6001]

EXTRA RELEVANT SYSTEM CONFIGURATION :
[I] D3DInitializer::InitImpl
[I] OS Version = OS_VISTA or newer
[I] CheckAdaptersInfo
[I] ------------------
[I] Adapter Ordinal  : 0
[I] Adapter Handle   : 0x10001
[I] Description      : NVIDIA Quadro NVS 160M
[I] GDI Name, Driver : \\.\DISPLAY1, nvd3dum.dll
[I] Vendor Id        : 0x10de
[I] Device Id        : 0x06eb
[I] SubSys Id        : 0x2331028
[I] Driver Version   : 7.15.11.7607
[I] GUID             : {D7B71E3E-45AB-11CF-2F6E-382201C2CA35}
[I] D3DPPLM::CheckDeviceCaps: adapter 0: Passed
[I] ------------------
[I] >>D3DAdapterInitializer::InitImpl(0)
[I] D3DContext::InitContext device 0
[I] D3DContext::ConfigureContext device 0
[I] D3DGD_getDeviceCapsNative
[I] D3DContext::ConfigureContext: successfully created device: 0
[I] D3DContext::InitDevice: device 0
[I] D3DContext::InitDefice: successfully initialized device 0
[I] <<D3DAdapterInitializer::InitImpl(0)
[I] D3DContext::InitContext device 0
[I] D3DContext::ConfigureContext device 0
[I] D3DContext::ConfigureContext: successfully created device: 0
[I] D3DContext::InitDevice: device 0
[I] D3DContext::InitDefice: successfully initialized device 0

A DESCRIPTION OF THE PROBLEM :
The d3d pipeline throws an java.lang.IllegalStateException starting with release 6u18.  When changing display resolutions or running other fullscreen media players.  In this case, the user base is running Cisco IPTV viewer.

STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Must be release 6u18.  This seemed to work under release 6u17 and previous.  Start a swing application on a system that supports the direct 3d pipeline.  With the main window open change the resolution or open a media player and switch it to fullscreen.  Toggle back a forth between applications.

EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
No crash.
ACTUAL -
There seem to be no visual artifacts.  An ISE is thrown at WComponentPeer.getBackBuffer to the uncaught exception handler first.  Followed by some internal code in the JDK that is catching an ISE at WComponentPeer.flip and is printing the stacktrace out to System.err.

Also noticed that running IPTV can cause j.a.MouseInfo.getPointerInfo to sometimes return null on systems with a connected mouse when IPTV has focus.  In some cases when the pointer info was returned on a display of 1024x768 would return values like:
1. x=171898600,y=171898600
2. x=1015013056,y=0
3. x=276260448,y=276260448

ERROR MESSAGES/STACK TRACES THAT OCCUR :
java.lang.IllegalStateException: Buffers have not been created
	at sun.awt.windows.WComponentPeer.getBackBuffer(Unknown Source)
	at java.awt.Component$FlipBufferStrategy.getBackBuffer(Unknown Source)
	at java.awt.Component$FlipBufferStrategy.updateInternalBuffers(Unknown Source)
	at java.awt.Component$FlipBufferStrategy.revalidate(Unknown Source)
	at java.awt.Component$FlipBufferStrategy.revalidate(Unknown Source)
	at java.awt.Component$FlipBufferStrategy.getDrawGraphics(Unknown Source)
	at javax.swing.BufferStrategyPaintManager.prepare(Unknown Source)
	at javax.swing.BufferStrategyPaintManager.paint(Unknown Source)
	at javax.swing.RepaintManager.paint(Unknown Source)
	at javax.swing.JComponent.paint(Unknown Source)
	at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
	at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
	at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
	at java.awt.Container.paint(Unknown Source)
	at java.awt.Window.paint(Unknown Source)
	at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
	at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
	at javax.swing.RepaintManager.seqPaintDirtyRegions(Unknown Source)
	at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(Unknown Source)
	at java.awt.event.InvocationEvent.dispatch(Unknown Source)
	at java.awt.EventQueue.dispatchEvent(Unknown Source)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
	at java.awt.EventDispatchThread.run(Unknown Source)

java.lang.IllegalStateException: Buffers have not been created
	at sun.awt.windows.WComponentPeer.flip(Unknown Source)
	at java.awt.Component$FlipBufferStrategy.flipSubRegion(Unknown Source)
	at java.awt.Component$FlipBufferStrategy.showSubRegion(Unknown Source)
	at java.awt.Component$FlipSubRegionBufferStrategy.showIfNotLost(Unknown Source)
	at javax.swing.BufferStrategyPaintManager.show(Unknown Source)
	at javax.swing.RepaintManager.show(Unknown Source)
	at javax.swing.SwingPaintEventDispatcher.createPaintEvent(Unknown Source)
	at sun.awt.windows.WComponentPeer.postPaintIfNecessary(Unknown Source)
	at sun.awt.windows.WComponentPeer.handleExpose(Unknown Source)
	at sun.awt.windows.WToolkit.eventLoop(Native Method)
	at sun.awt.windows.WToolkit.run(Unknown Source)
	at java.lang.Thread.run(Unknown Source)


REPRODUCIBILITY :
This bug can be reproduced often.

CUSTOMER SUBMITTED WORKAROUND :
Disable d3d using -Dsun.java2d.d3d=false

Release Regression From : 6u17
The above release value was the last known release where this 
bug was not reproducible. Since then there has been a regression.
CAP member has experienced same problem and found more frequently on JDK7 b100 and JNLP. With JDK 6, they only experienced sporadically but much more frequently with JDK 7.

Here is the console output
 -

===================================
Java Web Start 1.7.0-ea
Verwendung der JRE-Version 1.7.0-ea-b100 Java HotSpot(TM) Client VM
Home-Verzeichnis des Benutzers = C:\Users\Volker
----------------------------------------------------
c:   Konsole l����schen
f:   Objekte in Finalisierungswarteschlange finalisieren
g:   Speicherbereinigung
h:   Diese Hilfemeldung anzeigen
m:   Speicherbelegung anzeigen
o:   Protokollierung ausl����sen
p:   Proxy-Konfiguration neu laden
q:   Konsole ausblenden
r:   Richtlinien-Konfiguration neu laden
s:   System- und Bereitstellungseigenschaften ausgeben
t:   Threadliste ausgeben
v:   Thread-Stack ausgeben
0-5: Trace-Stufe auf <n> setzen

----------------------------------------------------

Reading certificates from 7888 http://localhost:9000/core/JnlpDesigner.jar | C:\Users\Volker\AppData\LocalLow\Sun\Java\Deployment\cache\6.0\19\7bec92d3-24cbfacd.idx
�������.

Exception in thread "AWT-EventQueue-1" java.lang.IllegalStateException: Buffers have not been created
                at sun.awt.windows.WComponentPeer.getBackBuffer(Unknown Source)
                at java.awt.Component$FlipBufferStrategy.getBackBuffer(Unknown Source)
                at java.awt.Component$FlipBufferStrategy.updateInternalBuffers(Unknown Source)
                at java.awt.Component$FlipBufferStrategy.revalidate(Unknown Source)
                at java.awt.Component$FlipBufferStrategy.revalidate(Unknown Source)
                at java.awt.Component$FlipBufferStrategy.getDrawGraphics(Unknown Source)
                at javax.swing.BufferStrategyPaintManager.prepare(Unknown Source)
                at javax.swing.BufferStrategyPaintManager.paint(Unknown Source)
                at javax.swing.RepaintManager.paint(Unknown Source)
                at javax.swing.JComponent.paint(Unknown Source)
                at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
                at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
                at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
                at java.awt.Container.paint(Unknown Source)
                at java.awt.Window.paint(Unknown Source)
                at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
                at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
                at javax.swing.RepaintManager.prePaintDirtyRegions(Unknown Source)
                at javax.swing.RepaintManager.access$700(Unknown Source)
                at javax.swing.RepaintManager$ProcessingRunnable.run(Unknown Source)
                at java.awt.event.InvocationEvent.dispatch(Unknown Source)
                at java.awt.EventQueue.dispatchEvent(Unknown Source)
                at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
                at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
                at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
                at java.awt.Dialog$1.run(Unknown Source)
                at java.awt.Dialog$3.run(Unknown Source)
                at java.security.AccessController.doPrivileged(Native Method)
                at java.awt.Dialog.show(Unknown Source)
                at java.awt.Component.show(Unknown Source)
                at java.awt.Component.setVisible(Unknown Source)
                at java.awt.Window.setVisible(Unknown Source)
                at java.awt.Dialog.setVisible(Unknown Source)
                at com.sun.deploy.ui.DialogTemplate$10.run(Unknown Source)
                at com.sun.deploy.ui.DialogTemplate.setVisible(Unknown Source)
                at com.sun.deploy.ui.UIFactory$11.execute(Unknown Source)
                at com.sun.javaws.ui.JavawsSysRun.delegate(Unknown Source)
                at com.sun.deploy.util.DeploySysRun.execute(Unknown Source)
                at com.sun.deploy.util.DeploySysRun$1.run(Unknown Source)
                at java.security.AccessController.doPrivileged(Native Method)
                at com.sun.deploy.util.DeploySysRun.executePrivileged(Unknown Source)
                at com.sun.deploy.ui.UIFactory.showProgressDialog(Unknown Source)
                at com.sun.javaws.ui.DownloadWindow$11.run(Unknown Source)
                at java.awt.event.InvocationEvent.dispatch(Unknown Source)
                at java.awt.EventQueue.dispatchEvent(Unknown Source)
                at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
                at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
                at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
                at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
                at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
                at java.awt.EventDispatchThread.run(Unknown Source)

J2D_TRACE_LEVEL=4 output from a standalone application because JNLP does not print it.
===============================
[I] OS Version = OS_VISTA or newer
[I] CheckAdaptersInfo
[I] ------------------
[I] Adapter Ordinal  : 0
[I] Adapter Handle   : 0x10001
[I] Description      : Radeon X1300/X1550 Series
[I] GDI Name, Driver : \\.\DISPLAY1, atiumdag.dll
[I] Vendor Id        : 0x1002
[I] Device Id        : 0x7183
[I] SubSys Id        : 0x3021028
[I] Driver Version   : 7.14.10.597
[I] GUID             : {D7B71EE2-32C3-11CF-CD71-0823A1C2CA35}
[I] D3DPPLM::CheckDeviceCaps: adapter 0: Passed
[I] ------------------
[I] D3DGD_getDeviceCapsNative
[I] D3DContext::InitContext device 0
[I] D3DContext::ConfigureContext device 0
[V] dwBehaviorFlags=D3DCREATE_FPU_PRESERVE|D3DCREATE_HARDWARE_VERTEXPROCESSING
[I] D3DContext::ConfigureContext: successfully created device: 0
[I] D3DContext::InitDevice: device 0
[I] D3DContext::InitDefice: successfully initialized device 0
[V]   | CAPS_DEVICE_OK
[V]   | CAPS_RT_PLAIN_ALPHA
[V]   | CAPS_RT_TEXTURE_ALPHA
[V]   | CAPS_RT_TEXTURE_OPAQUE
[V]   | CAPS_LCD_SHADER | CAPS_BIOP_SHADER | CAPS_PS20
[V]   | CAPS_AA_SHADER
[V]   | CAPS_PS30
[V]   | CAPS_MULTITEXTURE
[V]   | CAPS_TEXNONSQUARE

Comments
Fix Request (11u) Backport to 11u requested because it is a part of 11.0.8-oracle. Patch applies cleanly to 11u. Test is included with the patch.
24-02-2020

FYI: Why buffersper window were implemented: https://bugs.openjdk.java.net/browse/JDK-4967886 When BufferStrategy was implemented: https://bugs.openjdk.java.net/browse/JDK-4189326
14-05-2019

Please re-open if - if fix is in progress or on the plan to fix soon - if this is a P3 (file as P3, not P4)
18-03-2014

EVALUATION I would say that this issue and CR 6432092 are duplicates.
03-05-2012

EVALUATION This problem is not a regression in 6u18. Similar problem was reported against early builds of jdk6 (see CR 6432092). Observed exception is a manifestation of a thread race between double buffering machinery and accelerated pipelines (d3d, ogl). Due to some changes, this problem becomes a bit more visible in 6u18 time, but roots of the problem seem to exist from early jdk6 time. So, I am removing the regression keyword. Note also, that this problem is hard to reproduce, and has no consequences other than a stack trace dump in a console (no hang, no visual artifacts were reported). Because of this, I am decreasing the priority for this CR.
23-12-2010