I have a java project running jMonkey Engine. On my normal laptop (not the greatest laptop there is) my project runs fine. But on my high-end gaming pc (GeForce GTX 970, Intel i5-6600K @3.50 GHz, 16 GB RAM) the program lags. Like every 2 seconds my engine just freezes for a couple ms which causes huge lags. I am using this java (recently updated it to see if that would fix it)
java version "1.8.0_131"
Java(TM) SE Runtime Environment (build 1.8.0_131-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.131-b11, mixed mode)
From your description it is very hard to answer this question. You might want to try the JME forums where a more discussion and troubleshooting approach is possible than here.
The only thing I can think of that might explain what you are seeing is that you are generating a lot of garbage. On a PC with more memory then it can build up a lot of garbage then do a long pause to collect it all. On the lower spec PC it is forced to run the GC more often which means the GC pauses are too small to notice.
The engine has been carefully written not to generate much garbage in general use, so you should look at what you are generating each frame. Try attaching a Profiler (there are some decent ones provided with the JDK such as jConsole) and looking at whether there is a large GC linked to the pauses.