Using RAM and other Machine Resources

Before reading this essay, please read the Performance Tips topic if you have not already done so.

 

Manifold System was designed for the modern era of desktop machines. How is the modern era different from ancient days?

 

·      Random Access Memory (RAM) is cheap.

·      Disk storage is free.

·      Processors are cheap.

·      Graphics is both fast and cheap.

·      Local networks are fast.

·      Humans are very, very expensive.

 

Machine Architecture

 

Let's take a moment for a quick refresher on key factors in machine performance. The fastest thing in your computer is the processor. Modern processors will run at over a gigahertz in speed with certain internal parts of the processor running several times faster. Modern processors are so fast that they end up spending much of their time waiting for the slower parts of the computer system to catch up.

 

The second fastest thing is RAM, which usually operates at a third to a fourth of the speed of the key parts of the processor. The third fastest thing is the video subsystem, which usually consists of dedicated video RAM, a graphics processor and video circuitry that can read / display from video RAM at the same time that the graphics processor or main system processor can work with the video RAM. It is often said that the human retina is brain tissue that has been extended out into the eyeballs for the purpose of acquiring visual info. In a manner of speaking the RAM in video subsystems is like that in reverse: it is part of the processor - RAM ensemble that has been extruded out into a display subsystem for the purpose of projecting visual info.

 

A bottleneck in the high-speed part of your machine is the linkage between the processor and RAM. Processors are so much faster than ordinary RAM that it pays sometimes to install a bit of extra high speed RAM, a cache, so that for many memory interactions the processor need not be slowed by RAM. It also affects the speed and power of graphics cards that must exchange lots of data at high speed with the processor and system RAM.

 

Compared to the three-way ensemble of processor, system RAM and graphics engine everything else in your computer system runs thousands of times slower. It's quite literally the difference between a fast bullet and a slow walk. For example, the next fastest things in computer systems after processors and RAM are hard disk drives and the local network interface.

 

Hard disk drives and local networks are extremely slow compared to processors and RAM. A fast disk might have an average access time of a few milliseconds, which is over a thousand times slower than the microsecond access times typical of RAM. Although hard disks can transfer data faster once data is found they are nonetheless best understood as subsystems that are a thousand times slower than RAM.

 

Even hundred megabit networks are also extremely slow compared to processors and RAM. At best, a good network interface will end up being about as fast as a local hard disk. This is one of the main uses of a fast network, to enable the dispersion of hard disk storage to different machines on a local network without any performance penalty attached to using a disk on a different machine. That this is accomplished is not a tribute to the speed of the network but rather an indication of how terribly slow hard disks are compared to the speed of processors and RAM.

 

[An aside: Internet, by the way, is idiotically slow compared to even slow things like disks and networks. If the processor and RAM are like a fast bullet, and hard disks and local networks are like a slow walk by a human, then even a fast Internet connection is like a snail. Suggesting that doing GIS over Internet is a better idea than doing GIS locally is like suggesting that snails are fast enough to outrun bullets. ]

 

For a software designer the main message of the above is that keeping the entire application in RAM so that it executes at processor and RAM speeds means we can make the application go a thousand times faster than if we have to use hard disk. That's a payoff too big to overlook in an era of cheap RAM.

 

For someone buying software and hardware it means the most important hardware investment is in the amount of RAM installed. Lots of RAM means that the processor will not be standing around waiting for the hard disk to provide paged data. More RAM is usually better than investing in a faster processor because without adequate RAM it doesn't matter if the processor is faster: both a fast and a slow processor will be spending most of their time waiting for slow fetches of paged memory from hard disk.

 

This effect, by the way, is one reason why Intel processors surged ahead of other processors for UNIX use in the late 1980's even though Intel 386 and 486 series processors were usually slower than the Motorola, SPARC or Alpha alternatives. The Intel processors could be purchased within PCs where RAM was much cheaper than RAM sold for use in the more expensive workstations that used the faster processors. PC clones loaded up with lots of inexpensive RAM were more effective UNIX platforms than fast workstations hobbled by small amounts of expensive RAM. The extra RAM made the PCs faster overall even though their processors were slower.

 

Manifold Architecture

 

The good news is that RAM is cheap. At the present writing, 8 GB of RAM (eight gigabytes) retails for as little as $200. At such low prices it is simply criminal not to have at least 4 GB of RAM. Manifold therefore expects that we will have lots of RAM in our machine. Occasionally, one reads criticism of Manifold that the system uses a lot of memory. If the memory is available, of course it does! It would be irresponsible not to do so. By using RAM whenever possible Manifold assures that it will run very fast. You should, of course, run 64-bit Windows to take advantage of lots of inexpensive memory. See the 32-bit and 64-bit Manifold Editions topic.

 

There is no point in slowing down the system so that it uses disk just in case the user has not invested in RAM. Such architectures penalize all users including those people smart enough to have spent a few pennies on RAM. To use this RAM, of course, it is important to have a modern Windows system such as Windows Vista x64 or Server 2008 x64 or XP x64 that does a good job of managing large amounts of system RAM. Investment in RAM and into modern Windows is very smart.

 

Manifold also expects we will have lots of hard disk space on our machine because disk space is now free. Perhaps it is not completely free but it is so close to being free that for all practical purposes it is free. For under $120 one can now purchase over a terabyte (one thousand gigabytes) of storage so that inadequate disk space is no longer a factor for most people.

 

In contrast to the low cost of RAM and essentially free status of disk space the cost of educated humans has skyrocketed. Almost anything we can do from a hardware perspective is worth doing if it saves human time. This is one reason that Manifold now saves all components of a project within a single .map file. By keeping all data in a single file we eliminate any wasted time hunting about for different files that make up a project.

 

Finally, Manifold expects that one has a modern graphics card installed with serious hardware support for OpenGL and well-written graphics drivers. Very hot graphics cards with massive amounts of dedicated graphics memory are now commonplace and dirt-cheap. There is no reason to waste the time of a user with slow graphics when lightning-fast graphics is cheap.

 

Good Business

 

Manifold's business structure is designed to exploit the interplay of the above technical factors. The low price enables users to invest into modern Windows, lots of RAM, fast processors, fast graphics cards and large hard disks. These machine resources will serve you every day no matter what application you launch. Many users will already have modern machines in place and will need no investment at all.

 

The main difference between Manifold and other, non-GIS applications is that large GIS projects involving images will often be the very largest jobs in memory usage ever executed on a particular machine. GIS images, for example, can easily grow to tens of megabytes or even hundreds of megabytes. This is much, much larger than images typical of simple graphics arts work and a factor of ten or greater than even very large word processing documents. Adding RAM is therefore an expected step for serious GIS work involving large images.

 

Some readers are blessed with modern systems and will not have to worry about hardware resources. Others have to make do with less contemporary hardware. As time goes by and machines improve a 3 Gigahertz processor will be something so slow it is purchased only for children's machines. In that time a reference to a Core 2 Quad will seem positively antique. However, there are many people in the world who will be using slower systems for years to come so we offer the following advice.

 

Some suggestions when assembling a new system:

 

·      Just about any AMD or Intel dual core or quad core with 1 or 2 GB of RAM and Windows XP or Vista will be fine for working with small drawings in an ordinary vector GIS way. Databases and drawings are low-overhead items.

·      When working with images, we suggest at least a quad core machine with 4 to 8 GB of RAM running Windows XP x64 or Vista x64. This is excessive for small images but necessary for mid-sized images. In modern times, most people buying new machines will buy at least this much anyway. Images are computationally intensive.

·      RAM has become ludicrously cheap. Many Intel Core i7 machines can host 12 GB of RAM. Buy lots and lots of RAM. It's dirt-cheap and it saves you time, which is very expensive.

·      A fast graphics card must be installed when performing 3D rendering in terrain windows. NVIDIA-based cards currently selling for under $50 will provide smooth motion even with large terrains. We like cards using NVIDIA graphics processors and strongly suggest getting the hottest NVIDIA processor-based card you can afford. Using NVIDIA CUDA can be a huge performance advantage as well.

 

See also the advice in the Performance Tips topic.

 

As a reality check keep in mind that one can configure an incredibly hot machine and purchase Windows, Microsoft Office and Manifold System and still have thousands of dollars left over as compared to the cost of buying just the same GIS software capabilities from a legacy GIS vendor. On occasion, one encounters people who seem proud of having burned up many thousands of dollars per seat on legacy software that does less than Manifold. It is especially funny to realize that these are often the same people who complain about no longer having enough budget to afford modern machines, adequate RAM or even an upgrade to 64-bit Windows.

 

If people within your organization oppose increased Manifold procurement a good approach is a table in two columns that in one column lists the cost of legacy software required to approach Manifold's capabilities. In the other column one can present a list of all the wonderful modern hardware and software one can afford as a result of purchasing Manifold. The difference is real money that has a real impact on machine capability and organizational output.