LWJGL/lwjgl

Performance issues with integrated intel GPUs

jikuja opened this issue · 5 comments

Three newest generations of intel HD graphics GPU drivers seems to have bug which decreases performance. Current workarounds:

  • ask user to use other GPU if available.
  • ask user to wait patiently while MC is loading

Summary of my my findings:

  • Opengl drivers works but MC/forge load is really slow. Examples: http://paste.feed-the-beast.com/view/087c8312 notice timestamps in lines 6311 and 6322. Log with stacktraces: http://paste.feed-the-beast.com/view/a236c548. Clean stacktrace: https://paste.ee/p/PYVjj
  • Present with multiple operating systems(at least with windows 8 and windows 10) and java versions
  • drivers version 10.18.15.4248. (One months old support request with similar symptoms was using 10.18.15.4235 but might be caused by bad memory allocation)
  • driver version: GL info: ' Vendor: 'Intel' Version: '4.2.0 - Build 10.18.10.3540' Renderer: 'Intel(R) HD Graphics 4600' does not have performance problems. (Sorry I misplaced log for this :/) Source for this driver version?
  • Disabling new forge load screen does not fix this
  • Can't test this personally or write SSCCE. No hardware access.

My personal notes: https://paste.ee/p/RNmFU includes links to logs, lists of driver/OS/java versions

Does anyone has access for hardware and good knowledge of opengl to write SSCCE?

Ping #119

Spasi commented

Like issue 119, this cannot be something that LWJGL is able to fix. Isn't there an issue open for this at bugs.mojang.com?

Anyway, it looks like some texture creation/generation is taking place between 6311 and 6322. It could be something simple like a data format that forces the Intel driver out of the fast path. Using GL_BGRA and GL_UNSIGNED_INT_8_8_8_8_REV for texture uploads is known to be much faster on Intel hardware. Could someone produce a trace of LWJGL methods called during the slow part?

grum commented

Using GL_BGRA and GL_UNSIGNED_INT_8_8_8_8_REV for texture uploads is known to be much faster on Intel hardware.

Is there a public list/repo/collection of these 'known' things that are 'faster'?

Spasi commented

Search for intel GL_UNSIGNED_INT_8_8_8_8_REV and you'll find several references.

I started using it in LWJGL-FX, where texture transfer performance is critical. It made a huge difference on Intel hardware and hadn't any negative impact on other code paths or GPUs.

It might be entirely irrelevant to the problem of course, I don't know what Minecraft's doing there.

grum commented

Yeah, nice that vendors actually document these things .

To my surprise I picked exactly that way to upload the data just because it 'felt the easiest' to from the ARGB BufferedImage provides to BGRA the gpu seems to accept.

@jikuja maybe some mod/plugin uses another way to upload and not the one the game provides?

I fear I have nothing more to give for this discussion with my nonexistent opengl knowledge and with minor forge knowledge.

Should we ping forge devs?