COMBATSIM.COM: The Ultimate Combat Simulation and Strategy Gamers' Resource.
 

Tools of the TradePart III    By Shui-Che Lim
 

Performance Tuning

After you click on the Performance tab, you’ll get a summary of the amount of memory on your system, the percentage of resources remaining, the type of file and virtual memory system (16-bit or 32-bit), whether you’re using disk compression and whether or not there are any PCMCIA slots available (usually only found on notebook PCs).

The next item is particularly important and you should pay attention to it. If the next line says "Your system is configured for optimal performance" that means that Windows is using virtual device drivers for all your system devices. If you get a message that says that certain hard disks are using compatibility mode, this means that Windows 95 is using real mode drivers which will slow down performance.

Windows has its own 32-bit virtual device drivers that allows Windows to allocate and deallocate the driver as needed and also to allow effective system multitasking. Real mode drivers are 16-bit drivers that have some portion of itself (a memory stub) within the first 1MB of system memory space. This driver cannot be unloaded and Windows must make a transition from 32-bit to 16-bit operating mode which will slow down performance.

Usually, you get this compatibility mode message when there is something wrong with the hard disk controller setting or hard disk drivers under the Device Manager tab. It is beyond the scope of this article to list all the possible reasons for this error to appear. There are any number of reasons. However, they are generally related to the installation of third party hard disk device drivers such as Bus Mastering IDE drivers which are shipped with most motherboards.

Many people will argue that you want bus mastering drivers for your hard disks. However, there is some evidence that these drivers are a bunch of smoke and mirrors. To get details, check out Tom’s Hardware Guide at www.tomshardware.com and see what he has to say about them. I personally have not used any bus mastering drivers and have had no problems with the standard drivers supplied by Windows 95.

If you have any problem with third party drivers, you will need to uninstall these drivers from your system and then use the Add New Hardware icon under the Control Panel to redetect your hard disks and get the standard Windows 95 hard disk drivers reinstalled.

Compression Blues

Also worth noting is the line about Disk Compression. While the disk compression software shipped with Windows 95 will generally give up 1.5x more hard disk space, it does so at a performance cost. Windows creates a "compression volume" on your hard drive that is used to store all the compressed files and file structures. Windows tricks itself into seeing this file as the disk volume by loading certain drivers at system startup. These files are DRVSPACE.BIN and DBLSPACE.BIN, and they are located in your C:\ and C:\WINDOWS\COMMAND folders.

Windows compresses and decompresses files on the fly as they are accessed from the "compression volume" file on your hard disk. However, all this takes up valuable CPU resources so any games you play that rely heavily on the CPU will be affected every time Windows loads or saves files to your hard disk. A decent EIDE 2.1GB hard disk can be found nowadays for less than $120; and for another $80 or so you can go all the way up to a 6.4GB drive! Just say "NO" to disk compression and get yourself a large and fast hard disk.

TIP: Even if you’re not using disk compression, DRVSPACE.BIN and DBLSPACE.BIN may be loading at startup, consuming precious memory and increasing system startup times. From Windows Explorer, just delete or rename these files in C:\ and C:\WINDOWS\COMMAND. Don’t do this if you’re using disk compression. Altering these files will cause you not to be able to boot into Windows.

The Windows File System

On the Performance tab, you’ll see three buttons near the bottom marked, File System, Graphics, and Virtual Memory. Click on the File System button and you’re presented with another set of tabs labeled Hard Disk, CD-ROM and Troubleshooting. Chances are, your hard disk is set to "Desktop computer" in the drop down list box. The other settings are "Mobile or docking system" and "Network server." There is also a little slider bar that allows you to set the amount of read-ahead optimization.

The different file system profiles set up Windows 95 to behave differently depending on the type of system you’re using. These profiles make certain assumptions about system memory and hard disk space, as well as other variables, that affects the way Windows will utilize system resources on your machine. This will have an effect on overall system performance.

In the drop down list box, you want to choose "Network server" and also ensure that the slider bar is set to "Full" for read-ahead optimization. Choosing "Network server" will optimize how Windows 95 uses system memory. Windows 95 will aggressively use system memory to enhance performance and will usually page out to virtual memory during system idle.

Server, Shmerver I Dont Do Windows!

If it was really all that simple, I’d be out of a job. But, thankfully, Windows has some quirks and bugs that ensure that I’ll be gainfully employed for quite some time to come. If you’re using OSR2.x then choosing "Network server" should give you a nice little boost in performance. However, if you’re using either the original retail Windows 95 or Windows 95A, then you’ll most likely see a no increase or a decrease in performance. Huh?

There is a confirmed bug in the retail offerings of Windows 95, either the full or upgrade versions, that assigns the wrong values to the NameCache and PathCache registry keys. Actually the data for NameCache gets assigned the PathCache and vice versa for PathCache to NameCache. To get full details on this bug, you can access Microsoft’s Knowledge Base at: SUPPORT

If you’re using any of the retail versions of Windows, i.e. 4.00.950 or 4.00.950a, then you’re going to need to use a utility program supplied with Windows 95 called REGEDIT, to squash this bug. Press the "Start" button on your Windows taskbar and choose "Run…" When the dialog box comes up just type: regedit and hit the Enter key.

When REGEDIT opens up, it will display a list of folders with little plus signs next to them. The key you’re looking for is located in this location: Hkey_Local_Machine\Software\Microsoft\Windows\CurrentVersion\FS Templates. Under the FS Templates folder you’ll see three additional folders labeled Desktop, Mobile and Server. Double-click on the Server folder.

 

You will see values for Default, NameCache and PathCache. Double click on NameCache. Highlight the four hexadecimal digits and type in the following: a9 0a 00 00. Ensure that you use zeros, not "O’s" and that each number is separated with a space. Click on the "OK" button to save the new data. Repeat the same process with PathCache using this data: 40 00 00 00. Again, ensure that you’re using zeros and not "O’s" with spaces between each hexadecimal value. Click "OK" and you’re done!

Now all you need to do is go back to the Control Panel and double-click on the System icon. Choose Performance and File System. Ensure that you reselect "Network server" and click on the "OK" button. You will need to reboot Windows 95 for this change to take effect.

TIP: Remember what I said about making backups of your registry files SYSTEM.DAT and USER.DAT? Well, need I say more?

CD-ROM Optimizations

The next thing you want to do is click on the CD-ROM tab under File System. You’ll want to make sure that the Supplemental cache size slider bar is set to "Large" and the Optimize access patterns for drop down list is set correctly for the type of CD-ROM drive you have. Normally these are set correctly by default, but it never hurts to check this yourself, just to be thorough.

There are some games, however, such as Rowan’s Flying Corps and iMagic’s iF-22 that load terrain data from CD-ROM during gameplay. Setting up your CD-ROM for optimum access will actually cause intermittent pauses during CD-ROM access since the data that must be loaded must be loaded in a specific order. Setting the cache size to "Large" causes Windows to just load in whatever data it thinks is relevant into the memory cache. If the data is not correct, this will force Windows to reload the correct data, causing a pause. These games recommend that you turn down the cache setting to "Small" to keep this from happening. Of course, this will impact normal CD-ROM reading performance.

TIP: You should load the terrain data to the hard disk from the CD-ROM if you have a reasonably large hard disk and the game in question allows you to do so. Reading data from hard disk is infinitely faster than reading data from a CD-ROM, and using this method won’t require you to keep changing the CD-ROM cache size followed by a reboot of Windows 95 each time.

The Swap File Revisited

Windows 95 uses a swap file to enable a feature called Virtual Memory. Virtual memory allows Windows to temporarily make extra memory available when a situation arises that causes running programs to require more memory than you physically have in your system. When data or program code must be read into memory but there is no physical memory available, Windows will page out (save) some of the existing data or code from physical memory to the swap file. It will then load the requisite program code or data for execution or manipulation. When necessary, the original data or code that was swapped out to the swap file will be recalled back into physical memory.

While all this sounds pretty neat and works well in reality, it causes performance degradation since memory is about 1000 times faster than the fastest hard drive. Therefore, the first thing you can do to improve system performance, which I had mentioned previously, is to buy more memory. The second thing you can do, is to set up a separate partition for the swap file and ensure that it is also the last partition on your disk drive. Why do we want a separate partition for the swap file, though?

Windows 95 will normally use a dynamically configured swap file. What this means is that Windows 95 will dynamically allocate disk space for the swap file on an "as needed" basis. While this is great for conserving hard disk space, this causes some performance issues. Firstly, Windows must constantly figure out where there is extra disk space available if it needs to grow the size of the swap file. It will usually use the first free disk space it finds. Since we cannot guarantee that free disk space will be in contiguous blocks, you will have swap file data all over your hard disk as you continue to work under Windows.

Secondly, since data is haphazardly saved and removed from your hard disk, this will increase fragmentation, not only for the swap file, but also for the data that resides on your hard disk. Both of these issues will affect overall hard disk performance and ultimately, Windows 95 performance. Even if we set up a permanent swap file on the hard drive, we cannot always guarantee that it will end up occupying the innermost tracks. Windows 95 will just allocate a fixed block of hard disk space from the first area it finds that can encompass the size that you specify. Note that on badly fragmented drives, there will also be limits on how big of a block you can allocate to the swap file, i.e. the single largest contiguous block of free disk space. Therefore, creating a partition specifically for the swap file and ensuring that this is the last partition on your hard disk solves all of these issues.

Under the Performance tab, choose Virtual Memory. Select the radio button that says "Let me specify my own virtual memory settings." This will enable the drop down list that will allow you to select the drive you want to put your swap file on. Note that Windows will treat each of your hard disk partitions as separate drives and they will each have their own drive letters. Choose the drive letter that corresponds with the partition for the swap file and enter the same number (equal to the maximum drive space) for both the Minimum and Maximum settings. Click "OK" and reboot.

When Windows 95 starts up again, you notice that disk performance has improved. You also notice that the system will run quite a bit faster, even when it has to make use of the swap file.

TIP: To get the best disk performance, you should periodically run ScanDisk to spot errors on your hard disk and Defrag to defragment all the files and data.

That’s a Wrap!

Well that just about does it this time out. There is literally a treasure trove of sites that include lots of very useful information and utilities for keeping Windows 95 running optimally. I’m including a short list of some of my favorite sites:

Troubleshooting/Tweeking:

Windows 95 Annoyances: http://www.annoyances.org/
Microsoft Support: http://support.microsoft.com/
Microsoft Homepage: http://www.microsoft.com/

General Hardware:

Tom’s Hardware Guide: http://www.tomshardware.com/
Anand’s Hardware Tech Page: http://www.anandtech.com/

Industry News:

Ziff-Davis ZDNet: http://www.zdnet.com/
Cnet: http://www.news.com/

Software/Utilities:

Windows 95 Updates: http://www.microsoft.com/windows95/info/updates.htm
WinFiles: http://www.winfiles.com/
Tucows: http://www.tucows.com/

Watch for Part IV later this week.

Send mail to Shui-Che: Shu-Che Lim

 

 

© 1997 - 2000 COMBATSIM.COM, Inc. All Rights Reserved. .
Last Updated April 6th, 1998

© 2014 COMBATSIM.COM - All Rights Reserved