ติดตั้ง Steam
เข้าสู่ระบบ
|
ภาษา
简体中文 (จีนตัวย่อ)
繁體中文 (จีนตัวเต็ม)
日本語 (ญี่ปุ่น)
한국어 (เกาหลี)
български (บัลแกเรีย)
Čeština (เช็ก)
Dansk (เดนมาร์ก)
Deutsch (เยอรมัน)
English (อังกฤษ)
Español - España (สเปน)
Español - Latinoamérica (สเปน - ลาตินอเมริกา)
Ελληνικά (กรีก)
Français (ฝรั่งเศส)
Italiano (อิตาลี)
Bahasa Indonesia (อินโดนีเซีย)
Magyar (ฮังการี)
Nederlands (ดัตช์)
Norsk (นอร์เวย์)
Polski (โปแลนด์)
Português (โปรตุเกส - โปรตุเกส)
Português - Brasil (โปรตุเกส - บราซิล)
Română (โรมาเนีย)
Русский (รัสเซีย)
Suomi (ฟินแลนด์)
Svenska (สวีเดน)
Türkçe (ตุรกี)
Tiếng Việt (เวียดนาม)
Українська (ยูเครน)
รายงานปัญหาเกี่ยวกับการแปลภาษา
Things to keep in mind when you plan of getting parts for a desktop PC.
Get dual sticks of RAM because that gives better performance. Even if the single stick is in both higher capacity and speed. Aim for either 8 GB(4x2) or 16 GB(8x2) with speeds at 3000 or higher.
You don't need the most expensive motherboard either. Just make sure it can handle the CPU you buy. This will be listed on the store page for each motherboard.
If you want a smoother Windows a SSD as boot drive is a good idea. 256 GB is a nice size and they shouldn't be that expensive. You can spend much more and get some of the bigger SSD so you can use it both for boot drive and gaming. I did that because my HDD made a lot of noise.
Then with Intel vs AMD. Generally Intel perform better in games where as AMD perform much better when it comes to rendering programs.
...
not all of you only rogue rabbit has any clue what he is talking about.
allocating more ram doesn't quite make the game run better but it will increase performance,
reducing stutters, faster loading time. on top of that playing minecraft at 4GB and 20GB shouldn't make a difference but I can get up to 380 more frames by allocating 20GB of ram to minecraft
the steam launch option literally tell the game its max memory their is a launch option along the lines of "-MaxMem=10000" i cant quite remember but it sets your max ram usage for that game to 10000 megabytes
Intel(R) UHD Graphics 620
Just 20gb ram missing?
FINALLY someone mentions how to change your max memory and does not just talk about the purpose of allocating more RAM. Thank you!
btw: to my knowledge, minecraft handles the game better, the more RAM you are allocating to it up until 16GB. allocating more than 16GB to minecraft either does not change anything or can even slightly decrease the performance. so try 16GB and see, if the game performance has changed by any amount. also: even 16GB is super overkill. usually, 8GB should be more than enough for any modpack.
"increasing performance" is literally a synonym for running better.
TL;DR - most of the info provided is right, but due to Minecraft being written in Java it's an exception because it runs on the JVM instead of directly on the host OS. But when it comes to games Minecraft is the exception, not the rule.
Full Response:
I came across this while trying to see if there was a fix for an out of memory exception in a Java game, and there is obviously some confusion going on in regards to how memory works and I thought I'd try to see if this clears some things up. For some context, I'm a software engineer with 30 years experience in various languages from C++, Java, Python, Go, Scala, PHP, C, C#, and more.
Most of the info given to you that you're calling wrong is correct, the confusion is that in a few games (like Minecraft) there is another layer between the game and the operating system. That's because Minecraft was written in a language called Java and Java applications don't run directly on the host operating system. Instead there is what's called the JVM (Java Virtual Machine) that sits between the Java application and the Operating System. Java (and other interpreted languages) do this so that you can write you program once and it can then run on any system that has a JVM and the Java app doesn't have to be ported to that system, but it also has some trade offs, most of which are performance related (which is why you don't see as many games written in Java and other interpreted languages).
What you were told about programs not using memory unless they need it is true, and that's the way the JVM gets memory from the host operating system. But Java does things a little different. There are 3 main command line arguments for Java memory management. The first is -Xmx (Format: -Xmx<size>[g|G|m|M|k|K] i.e. -Xmx1g or -Xmx256m) which is the maximum heap size that Java will use and on most systems defaults to 256 MB. The heap is where programs keep their data and if you're getting a java OutOfMemory exception and your system still has free ram this is what you likely need to increase as java will not use more RAM than this for application data. The next one is -Xms (same format as Xmx, i.e. -Xms1g or -Xms256m) which is the starting heap size. When Java starts it will allocate this much RAM for heap even if the application never needs that much RAM, which is how you can get a Java app, like Minecraft, to allocate 20GB of RAM even if it only uses a fraction of that. The last one is -Xss which is the stack size and on most 32 bit systems the default is 320 KB and most 64 bit systems the default is 1024 KB. The stack is where an application keeps track of which functions have been called to in what order to get to the current command / line of code that is currently being executed. It's a fixed size and is allocated when Java starts up and if you have an error about running out of stack space then you can try setting this to an insanely large value (like -Xss256m or -Xss1G) but if it doesn't fix your problem you might as well remove it because it shouldn't be needed.
So when a Java application starts the JVM will ask the OS for the amount of memory specified by Xss (or the default if it wasn't passed in) for the stack and Xms (or again the default if it wasn't set) amount of RAM for the heap. Then if the Java application asks for more memory and the heap is full the JVM will ask the host OS for more ram, but it won't ask for just the amount it needs, it will allocate more heap space in chunks (of some unspecified size that could vary based on OS, Java version, Xss, Xms, or other factors) up to the size set by Xmx (or the default if not specified). So if Xms was set to 256 MB the first time the application asks for a 257th MB or more the JVM will allocate another chunk of RAM of unspecified size and the heap could end up being any size up to Xmx. So usually you'll want to set Xms to about what the minimum amount of RAM you'll need (so say in Minecraft you create a new game and immediately go see how much RAM is being used by Minecraft and set the Xms to about that amount) or else leave it alone.
If you set it to something too large (like say 20GB) all you're doing is make the JVM allocate RAM but the application will never use it, but no other application can because the host OS has allocated that RAM to the instance of the JVM Minecraft is running in. Now I say the "instance of the JVM Minecraft is running in" because if you have more than one Java application open they will both have their own instance of the JVM and can't share RAM between the instances. So say I have Xms and Xmx set to 20G on Minecraft and I also have IntelliJ running (another Java program that's an IDE or a program used to write other programs). Since Minecraft's JVM has Xms and Xmx both set to 20 GB then Minecraft's Java instance will allocate 20 GB of RAM for the heap on startup and won't let Minecraft use more than 20 GB. But if Minecraft is only using say 3GB of RAM the host OS will still have all 20 GB allocated or reserved for Minecraft and it won't be able to be used by anything else on the system, including an other Java programs, like say IntelliJ. So say in this example Minecraft's Xmx and Xms are set to 20GB and I IntelliJ's Xmx and Xms are set to 10G but I only have 24GB of RAM in my system then IntelliJ would get an out of memory exception (assuming Minecraft can't be moved to swap).
But most games in Steam aren't written in Java and so these command line arguments will just be ignored if you try to set them. Most games are written in C++ or use a game engine that was (like Unreal or Unity). And so they have to allocate memory as they need it and you don't "reserve" memory for them. For example if you load a new level and it requires new assets (like terrain, models, textures, etc.) the game will have to ask the operating system for memory to store those assets and the operating system will either give the application that memory or give it an error saying that it is out of memory (or it could be possible that there is that much memory free in total, but it doesn't have that much contiguous memory. i.e., the app asked for 1 GB, and there is 1.5GB free, but there isn't one contiguous 1GB chunk so the app gets an out of memory error). But once the OS allocates memory for these applications the application can do whatever it wants with it until it either frees that memory (freeing memory is when an application tells the OS it's done with a chunk of memory previously allocated to it letting the OS know it can allocate it for something else) or the application ends (doesn't matter if it crashes or exits gracefully, the OS obviously knows if the application isn't running it doesn't need that memory). So some games or game engines may try to do optimizations where they allocate memory in large chunks and use it for various things or may try and re-use memory that isn't needed anymore (like say you load a new level, instead of freeing the memory for the old level back to the OS and then requesting memory for the new level from the OS it may reuse some of the memory it used for the old level on the new one, but that's probably overkill when it comes to optimization). And because with most games they allocate memory as need from the OS they could add their own custom memory flags to control any memory management that they do, but this is probably pretty rare and I haven't seen any games that have done it, but it is possible.
Sorry, this ended up being much longer than expected. I hope it makes sense.
im sure all here agree on User mistake no matter how we try to help. hes not the first and wont be the last.
( U-procesor is worst , you need game that require even lesser that match that )
just so all know that is known as cheepman CPU and can give performance issue compare to standard pc.