Java and Nvidia

  • Please make sure you are posting in the correct place. Server ads go here and modpack bugs go here

xSINZx

New Member
Jul 29, 2019
305
0
0
Hi All,

Did a couple searches on Nvidia nothing under FTB for Nvidia (werid! swear I saw some post using the word Nvidia). Just wondering if anyone has any kind of setup for Nvidia Card through Nvidia Inspector, or even the main Nvidia 3D manager. I have messed around with Inspector in the Past as I also do a bit of flight simming using FSX. Which when using Nvidia Inspector greatly increases preformance, FPS and look.
I kid you not I have pushed F3 in the past and seen my FPS over 1000 frames per sec. Can't remember what version of MC it was, or if there were mods installed whatever. May have been a bug I don't know.
I gather that servers and clients today would be trying to limit fps to a certain value?
Anyways just added the Javaw.exe to Nvidia 3d Manager. Just wondering if there is anything more I could be doing to Improve things. Do I need to add the FTBserver.jar as well? Any others I should add Java.exe itself?
Not that the FPS I have is not good, but always looking to improve things.
I run my Local Server at 4gig and my client at 4gig. System is using like 50 to 63% ram and about 30% cpu. Even when I start using fraps it only goes to about 37% cpu.

Whole reason I'm asking is because I have seen others post they are getting around 75fps and I'm sitting on anywhere between 30 and 50 odd.
Looking hard at the GTX 680 single gpu. As I think half my problems come from having a duel gpu card. Son would be better off with my 59o as I know WoW works well with it.

Any help / comments appreciated.
 

whythisname

New Member
Jul 29, 2019
474
0
0
I've got an Nvidia 560GTX and an Intel Q9450 and I also have ~30-50 FPS in most cases (with optifine, without I've seen it drop to ~10-20 in some areas). So I think your PC might be able to squeeze out a few more FPS (40-60), but not anywhere near 1000.

The big issue is machines though (could be mod specific, but I don't know and can't be bothered to figure out). My PC can handle the giant Redwood forests (with thousands of transparent blocks/leaves) with ease, but my chunk with 3 Peat farms, a large boiler, my ore processing and Redstone conduits slows my game to a crawl if I don't have optifine installed (only if I come near it though, so it's probably a graphical issue, but still).

So yeah, 30-50 FPS sounds to me like it won't get much better than that.
 

Omicron

New Member
Jul 29, 2019
2,974
0
0
Video card power is largely irrelevant in Minecraft. I myself have a GTX 460, which I actually underclocked by 10%, and the card is bored out of its mind by Minecraft on fullscreen 1920x1200. It actually enters the first of its energy saving states, clocking the shaders further down to 800 (default: 1350, my setting: 1220) and the memory one step down as well. It hovers around 50%-70% utilization that way. Try MSI Afterburner to display your video card utilization and clocks; you may be surprised.

The reason my video card is half asleep is the fact that my CPU and memory is bottlenecking performance. Java is really not a performance language, and it shows. Now, your CPU is obviously not an issue, but the point I'm trying to make is: I'm willing to bet that for you, too, something other than your video card is responsible.

For starters, remove Optifine if you have it, as well as any sort of texture pack. Also, try to make sure your client is set to Maximum FPS in the video options, and anything to do with VSync is disabled (including in the Nvidia driver profile you created for javaw.exe).
 

Hydra

New Member
Jul 29, 2019
1,869
0
0
Why would you want to disable vsync?

Also: the CPU bottlenecking has nothing to do with Java. If you rewrote minecraft to C++ there would hardly be any chance. MC is rather unique in the way it simulates a voxel world and this simply causes a lot of work for your CPU.
 

SReject

New Member
Jul 29, 2019
433
0
0
Why would you want to disable vsync?

Also: the CPU bottlenecking has nothing to do with Java. If you rewrote minecraft to C++ there would hardly be any chance. MC is rather unique in the way it simulates a voxel world and this simply causes a lot of work for your CPU.
After running a few java and video analyzers, it would appear about 63% of rendering is done on the CPU instead of the GPU. This might sound like a lot, but it isn't. Most of that is figuring out what goes where, then the GPU does the shading, coloring, etc. If written in a low level language like C or its offspring I could see minecraft running quite a bit faster, but then it'd require more from a system to run(does that make since?)


As for speeding things up, if you have a O-MEGA-MY-GOD-THE-BESTEST video setup, there's programs that allow for you to run specific processes on the GPU. So instead of javaw.exe being handled via the nVidia manager and processed via the CPU, it'd all be done on the graphics. Using programs of the such on a dual core video card with 4+gigs vram gives me ~90-100fps
 

Omicron

New Member
Jul 29, 2019
2,974
0
0
Because it is an option that stops the video card from generating as many frames per second as it could in some situations. Also, the way VSync works makes it lock itself to half performance if full cannot be reached. I.e. if the refresh rate it syncs to is 60 Hz, but you only get 55 FPS for whatever reason (even reasons independent of GPU performance), VSnyc will often throttle down to 30, thus artificially lowering your FPS.

The point here is not that "having VSync on is bad". The point is that the OP has less FPS than his computer config should be able to produce, and without knowing anything else about his system, suggesting to toy with FPS-related options to see if it changes anything is a first step to narrowing down the issue.
 

whythisname

New Member
Jul 29, 2019
474
0
0
For starters, remove Optifine if you have it

I don't completely agree with that, while it might hurt performance for some people for me it helps a lot (I get 2-3x more FPS with Optifine than without it, especially in chunks with lots of machines). I think you should test both with and without it.

I agree Java has terrible performance though. The low FPS we're getting is not because our PCs aren't powerful enough, it's because the game is just so poorly optimized and all the mods FTB adds don't help with that either (I'm pretty sure there is quite a bit of performance crippling code to be found among all these mods).
 

SReject

New Member
Jul 29, 2019
433
0
0
It's because the game is just so poorly optimized and all the mods FTB adds don't help with that either (I'm pretty sure there is quite a bit of performance crippling code to be found among all these mods).[/SIZE]
Im not so sure about that, at least not for vanilla minecraft or the more popular mods such as IC2 and buildcraft. Especially for those that have been out for quite a while. Generally the communities of such find the bottle necks, and help the devs narrow down the culprit to get them running nicely. With that said, I am not saying everything is perfect. I do know there are bottle necks in mods, just as redpower2; its known to be a lag maker but it is a fairly new release.
 

Omicron

New Member
Jul 29, 2019
2,974
0
0
Some mods definitely do hog performance. I was able to see this when I invited friends over to play via LAN. Someone brought an atom-based netbook, claiming that Minecraft ran just fine on it... even showed me. They got about 15-20 FPS in vanilla, which while far from pretty was actually quite playable.

And then, logging into a Mindcrack v6 world, with half the mods disabled and no ExtraBiomesXL at all, they got 3 FPS. With Optifine this actually dropped to 2.
 

Hydra

New Member
Jul 29, 2019
1,869
0
0
After running a few java and video analyzers, it would appear about 63% of rendering is done on the CPU instead of the GPU. This might sound like a lot, but it isn't. Most of that is figuring out what goes where, then the GPU does the shading, coloring, etc. If written in a low level language like C or its offspring I could see minecraft running quite a bit faster, but then it'd require more from a system to run(does that make since?)

I'm a java developer with over 14 years of experience and no that doesn't make sense at all. I wrote my own minecraft viewer a while ago and I know pretty well how the rendering works internally. Java isn't slower than C (in some cases it can be even faster). Java is compiled at runtime by the VM so its basically exactly the same code executing on your CPU.

The versatility of the minecraft terrain comes at a cost; the CPU has to do most of the work. In most games stuff cannot be destroyed or changed because allowing that would make the game unplayable. The way the minecraft engine works internally is completely different from the way for example a shooter or rts works.

As for speeding things up, if you have a O-MEGA-MY-GOD-THE-BESTEST video setup, there's programs that allow for you to run specific processes on the GPU. So instead of javaw.exe being handled via the nVidia manager and processed via the CPU, it'd all be done on the graphics.

Sorry but that's just bollocks. GPU's can't just run any code, not even close. GPU's are good at very simply very parallelized tasks. Applications are neither simple nor parallelized.[DOUBLEPOST=1360932980][/DOUBLEPOST]
Im not so sure about that

Be sure. IC2 used to be completely terrible, now it's just 'bad'. A lot of mods are being coded by programmers who got just beyond their "my first java applet" stage. And being self-taught has the problem that no one is there to slap you on the wrist if you do something very stupid.
 

SReject

New Member
Jul 29, 2019
433
0
0
@Hydra, not turning this into a flame war. I've been coding in C and it's variants for the last 10 years, so I'm not a nub when it comes to computers. I know java is compiled at run time. I wasn't stating that java is necessarily slower than C, but with a low level language you have more to work with(and deal with) that you wouldn't normally with java. AFAIK with java, you can't dictate where threads/process-seeds are processed. Its left to built in libraries to do as such, no?

As for the GPU processing of javaw.exe, I know you can't run 'any' code via the GPU but there are programs that transcode it. Infact I run a java plugin, released BY ORICALE that pushes the java runtime onto the GPU. (I'm looking for the download link now)


As for the mod optimization, I was only assuming, and I apologize for that. As a developer, I know people are quick to complain when software "just doesn't run as good as I thought". Even though the program(s) in question have been combed through with a magnifying glass to make sure it's as optimal as possible.
 

Hydra

New Member
Jul 29, 2019
1,869
0
0
I'm not turning anything in a flame war. I just don't like it when people blame Java for stuff that's not a java problem. The microoptimizations you propose would not help the general performance anyway.

As for the GPU running Java code: that's something completely different. You can translate almost any code to CUDA for example but that doesn't make it a task that's actually suitable for a GPU.
 

MinerDude333

New Member
Jul 29, 2019
49
0
0
@Hydra, not turning this into a flame war. I've been coding in C and it's variants for the last 10 years, so I'm not a nub when it comes to computers. I know java is compiled at run time. I wasn't stating that java is necessarily slower than C, but with a low level language you have more to work with(and deal with) that you wouldn't normally with java. AFAIK with java, you can't dictate where threads/process-seeds are processed. Its left to built in libraries to do as such, no?

As for the GPU processing of javaw.exe, I know you can't run 'any' code via the GPU but there are programs that transcode it. Infact I run a java plugin, released BY ORICALE that pushes the java runtime onto the GPU. (I'm looking for the download link now)


As for the mod optimization, I was only assuming, and I apologize for that. As a developer, I know people are quick to complain when software "just doesn't run as good as I thought". Even though the program(s) in question have been combed through with a magnifying glass to make sure it's as optimal as possible.
What is that java plugin, i'm very curious as to how it works. Is it Sumatra, or Rootbeer, or something else?
 

Eli Delano

New Member
Jul 29, 2019
21
0
0
a simple thing to try may be to simply, open mincraft. then open your task manager(windows) go to processes scroll down untill you see "javaw.exe" right click, then on the menu select set priority, then high, this will give minecraft a higher priority than other things that may be using java or java higher priority for memory usage. its not tremendous difference but every little bit helps.
 

netmc

New Member
Jul 29, 2019
1,512
0
0
I myself am using a 6 year old laptop with an embedded NVidia 8600 gpu. not even close to cutting edge. with it however, I can still get 12-20 fps with no optifine and far render distance. it is decently playable. if I enter an area with a lot of transparent leaf blocks, I have to lower the render distance down to normal to get a decent framerate. with optifine, I get another 5-7 fps along with a few additional visual glitches. all in all, not too bad. it might help that I have 4gb of ram, and running 64bit java.

as far as the OP question, I am not sure about dual/single video card setup, but the real speed of the system is only shown with parallel tasks. minecraft and java is no where even close to being good multithreaded programs, so the parallel processing speed of computers and video cards is largely wasted. For these types of workloads, you are often better served by a faster processor and video card rather than one that can do more things at once. (which is primarily opposite of all the computers made in the last 5 years)
 

Antice

New Member
Jul 29, 2019
729
0
0
Is there a way to trick minecraft into using more than one cpu core?

I was thinking something along the lines of starting a server on the same machine as the client... or was this done when they changed the SSP version to run as an internal server?
I know i can run a server and client in parallel on my machine without noticing much in the form of performance changes... (FPS remains more or less the same tbh) But my bottleneck atm is probably memory related. 4gig's just ain't nearly enough when running FTB mindcrack.

I have tested, and found that my kid's laptop get's a rather noticeable* FPS increase when she is connecting to a server set up on my machine on the LAN network, so there is definitely some game mechanics processes that are "server side" so to say, and that are not mirrored on the client. the cost in memory will likely kill my performance in my case, but Someone who's got plenty of RAM should maybe see an increase? (and trippling my RAM would be a cheap fix for a major increase in performance when editing and recording, so it's definately "on the books to do so already)
I do have an NVIDIA GF9500 GT. plenty of performance for doing far cry 3 on decent settings, altho i would have liked a better one.

*Noticeable indeed. going from 10-15fps to 20-30fps is a fairly major improvement tbh.... My kit get's around 60 on average when not recording. I record at 30 to save on space and rendering time. (I render to 30FPS 720p for YT)
 

netmc

New Member
Jul 29, 2019
1,512
0
0
more than one core is used, it's just not used well. the bulk of the program is single threaded as java is mainly single threaded. Most computer programs are this way. there is no way to get the software to use more than one core if the underlying architecture can't use it. when minecraft was merged into a unified server/client platform, it was made "multi-threaded" sort of. The server side runs in its own thread and the client runs in its own thread, and the two talk back and forth to each other. I am not a programmer, but this is generally how most programs work. you can only multi-thread portions of the program that don't depend on other portions to figure out. like particle effects for one. since the particle effects are not tied to what the rest of minecraft is doing, these would be good candidates for multi-threading (they may be already). So the program has to be changed to take advantage of it. The turbo boost feature of some of the new processors work well with lightly threaded applications since it boosts the clock rate of the processor.
 

Golrith

Over-Achiever
Trusted User
Nov 11, 2012
3,834
2,137
248
The overall problem is the mods. If I launch my vanilla MC with optifine and 64x texture pack, I can whizz around at 90fps. I load my FTB base (with optifine and 64x texture pack), and I'm crawling around at 2-5 FPS in my main base area, and 10-20fps once that's out of sight.
 

runlvlzero

New Member
Jul 29, 2019
46
0
0
1.4.7 vanilla is slow in general. With the new updated forge I am running optifine ultra with multicore support enabled and getting 60fps consistently on a geforce 640. This is with fancy graphics and tree's. No antialiasing. Before I had to turn fancy graphics off and was only getting 30 fps. I wouldn't blame the frame rate issues on FTBs mods.

I've had a lot of problems with optifine in the past, but this release seems to work like a charm for fps probs. I also updated java to the latest version. Multicore support gave me 40 fps increase when I turned it on, otherwise I would have 30fps or worse in redwood forests. I can't support optifine so if you are going to try that use their support forum threads.

And to the above, the textures for the 64x packs might be poorly compressed or formatted they are community developed and I had to optimize the sphax textures myself before I could get them to run smoothly using an image batch conversion program. With vanilla textures you get the same fps more or less client side. The reason you may see a difference is the vanilla packs are probably better supported by the artists, optimized, and theres less objects to load textures for. FTB will hog texture memory because there are allot more blocks loading different textures even if they are optimized. This is probably why the vanilla minecraft devs are careful about not creating a ton of new blocks every update.

Last update: the short and direct: More blocks ID's on screen = more texture load. Its impossible to work around it technically, try reducing textures to 32x.