5 ms·
>This impression is heightened by the fact that some well known garbage collected apps are written by people who just don’t seem to care about performance at al
by outworlder 10y ago
>This impression is heightened by the fact that some well known garbage collected apps are written by people who just don’t seem to care about performance at all, like Minecraft or Eclipse, leading people to blame GC for what is in reality just badly written code.
This assertion is too harsh. Eclipse does seem to be over-engineered(speaking from the point of view of someone who had to write a proprietary plugin for it) and Minecraft does seem to run slow on even the latest machines (compared to AAA games).
But Minecraft is not a trivial program to write, despite fooling people with low-resolution textures. it is, "algorithmically speaking", out of reach of many people, including those with a reasonable computer science background. I dare someone to do better (on the JVM!)
On a personal note, I cringe every time I have to go to a kid's computer and modify "-Xmx" settings. I'm running a game, I want it to have all available resources not otherwise allocated to the OS, just like almost every other game there is.
- DonbunEf7 10y agoHi, several years ago I produced an alternative to the "vanilla" Minecraft server. It easily spanked the vanilla server in terms of memory usage, latency, bandwidth usage, and overall stability. Oh, and I was writing Python, the "slow" language, using PyPy for speed. Minecraft's code is rotten throughout and nearly nobody in the community cares about code quality. Remember, this is a group that thought that TLS was easy to reinvent: http://wiki.vg/Protocol_Encryption http://wiki.vg/Protocol_Encryption
- buzzybee 10y agoI can second this notion, having worked on a Python server for a Minecraft-style game(Ace of Spades): it ran well with little optimization work. There are a few key algorithms that demanded fast computation, and the load got a little bit high on a full 32-player server, but there was never a performance crisis. I would also consider, though, that the client side code for such games is more complicated to reason about. More iterations through the voxel data needed to compute lighting and meshing. Still not something that should necessarily be impacted by GC. From what I've read, Minecraft's more recent versions switched to a strategy that boxed more function parameters in objects, adding to the load.
- wyldfire 10y agoIs your source available?
- DonbunEf7 10y agoSource: https://github.com/bravoserver/bravo https://github.com/bravoserver/bravo Docs: http://bravo.readthedocs.io/en/latest/ http://bravo.readthedocs.io/en/latest/
- mike_hearn 10y agoThere are client mods that speed up Minecraft significantly. Also, after Notch passed on the torch the new team decided to object-ify all 3D points: previously they were always passed around as three integers, now they are passed around as an object. That placed insane load on the GC and performance got a lot worse after that. I cringe every time I have to go to a kid's computer and modify "-Xmx" settings I think if you switch to the G1 collector you can just take it out? Minecraft really shouldn't need that kind of tuning though. Again, they don't really care.
- outworlder 10y agoI didn't know about this 3d point objectification. This is ridiculous. Tuning is required when you start to install mods. Or even texture packs.