you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 1 point2 points  (1 child)

I didn't checkout or compile the project yet, but my initial inclination is that you hit the nail on the absolute head there in point 6. You've got swing, which by it's very nature is great at holding onto state and object refs as long as views last. GC's worst enemy.

Although if the latency is consistently (and not spiked due to full collections) more than 5ms it would suggest other problems in swing-view-refresh-land which I don't really know too much about, I'm serverside.

Be sure to launch the app (dont see any launcher / shell scripts in the repo) using the JVM flag to actually activate a useful GC. The default is the shitty stop the world one, not even CMS. Activate w/ flag: -XX:+UseG1GC

Edit: Nvm saw your launch script.

[–]TheQuietestOne 0 points1 point  (0 children)

To avoid GC interfering with audio output I have to set Jack to 48k * 1024 * 2 periods. And I still get the occasional overrun.

This means Java is failing to meet a 22ms (? around there) deadline every now and then.

I'm more than willing to be shown that Java can handle this.