Last update: 2000-09-08

MatroX files utilities

Click here to go to MatroX files main page.

MXINFO - detailed card type recognition and important data dump
MXCK and MXCKINFO - MGA chip clocking information display
MXSET - G200 control (overclocking) utility
NEW !!! - G4SET - G400 control (overclocking) utility
MXK6OPT - K6-2 "XT", K6-III, K6-X+  video memory access optimizer
BIOSPROG - an alternative to PROGBIOS with enhanced security and recovery functions.


MXINFO - Card type recognition and important data dump

MXINFO is a basic tool for troubleshooting of BIOS failures, driver installation problems and "what do I have" confussions. It also has the capability to analyze the dead BIOS and recover PINS data from it (to be further used by Progbios.

The program dumps some important data read from Matrox card BIOS image. It can recognize and report card type and some vital parameters. Works in DOS / Win9x. MXINFO may be used to troubleshoot PINS and SUBSYS_ID problems that influence Windows driver installation.

What to look for

Card model
If "Unknown" the card will have problems with driver installation (this results from loosing some info after BIOS programming failure, but it also occurs in some brand-new G100 cards and a few old G200s).
PINS data
If the values are strange (like 355 MHz RAMDAC,  strange date or memory size) - PINS structure is probably destroyed and must be restored, otherwise the Windows driver will not operate properly.

Dead BIOS

To analyze dead BIOS, use "-dead" option with MXINFO. This will not work under Windows nor under EMM386 (use "Restart in MS-DOS mode" under Win). One interesting thing about dead BIOS is that on G-series the destroyed BIOS may still contain correct PINS, which MXINFO is trying to find (and dump in PROGBIOS-compatible manner).

Clock info and refresh rates

MXINFO will show clock rates in various modes, possible clock speed reduction with add-in memory and max vertical sync frequencies with various pixel depths. Currently this should report the correct rates for G-series, and some correct rates Millenium II and Mystique. Note that these clock rates are the ones SPECIFIED in card's BIOS, not actually programmed (using overclocking utilities). See below.

MXCK, MXCKINFO - MGA clock info display

The current versions fix the problem with incorrect reporting of 2/2 (=1) dividers.
MXCK v0.5 - GUI app, reports the clocks continuously (requires mfc42.dll)
MXCKINFO v0.3 - Win32 console app, lists the clocks and exits
These two utilities show the clock frequencies and divisors currently used by the MGA chip. Both are intended for the overclockers and the people curious about MGA frequencies.
The utilities work only in Win9x. They cause protection faults under NT.
Actually this is a test release of some parts of code I am writing for a bigger, Windows-based application integrating the functionality of MXINFO and maybe BIOSPROG.

MXSET - G200 control/overclocking utility

MXSET sets important timing parameters in MGA chips. It is intended to control PLLs, clock dividers, memory refresh counter and other timing-related functions that may be controlled after MGA chip initialization.

MXSET v0.19 -

The current release accepts two set of commands: native MXSET and G200CLK-compatible (/1 /3 and /4). You may even rename it to G200CLK for compatibility.

Of course you know that overclocking is dangerous, and only you will be responsible for all the consequences of using this utility.
It may be a good idea to read the article on MGA clocking before using MXSET.

Usage:
MXSET - display current settings
MXSET -? - show MXSET usage options
MXSET sclk <frequency_in kHz> - set SClk frequency
MXSET div <GClkDiv *2> <MClkDiv*2> <WClkDiv*2> - set clock divisors (4 -> div by 2, 3 -> div by 1.5, 2 -> don't divide)
MXSET rfsh <rate> - set video memory refresh rate: 0 - stop refresh, 1..63 - fastest..slowest refresh. Slower refresh = faster memory operations plus possible loss of memory contents.
MXSET syspll <N> <M> <P> - program system PLL with given values (for hobbyists, as "sclk" command does it better...).


G4SET - G400 control/overclocking utility

G4SET sets important timing parameters in Matrox G400 chip. It is intended to control PLLs, clock dividers, memory refresh counter and other timing-related functions that may be controlled after MGA chip initialization.

Since I don'have my G400 yet, I couldn't test the utility. I already know it gives some strange effects, like sudden slowdown in 3D apps. I will not be able to resolve these problems until I have the card handy (I hope 2..3 weeks).

G4SET displays several clocking parameters. The mysterious "c" parameter is the duty cycle correction factor. It is automatically calculated according to Matrox prescriptions. Its value cannot be changed by the user and it does not influence the speed in any way, so you don't need to worry about it.

G4SET v0.11

Of course you know that overclocking is dangerous, and only you will be responsible for all the consequences of using this utility.
It may be a good idea to read the article on MGA clocking before using MXSET.

Usage:
G4SET - display current settings
G4SET -? - show usage options
G4SET -sclk <frequency_in MHz> - set SClk frequency
G4SET -div <GClkDiv> <MClkDiv> <WClkDiv> - set clock divisors
G4SET -rfsh <rate> - set video memory refresh rate: 0 - stop refresh, 1..63 - fastest..slowest refresh. Slower refresh = faster memory operations plus possible loss of memory contents.


MXK6OPT - K6-2 (XT core version) video memory access optimizer

Click here to go to MatroX files main page.

If you download and use the program, please report the results to me.
The current version also supports new K6-X+ CPUs

The program is yet another K6-2XT optimizer. The major advantage of MXK6OPT over other K62 utils is that it may work completely automatically, without any user-supplied parameters, and it can optimize access for two VGA compatible video cards.

How it works

MXK6OPT finds up to two VGA controllers in a PC and sets K6-2 (model 8..F, also called "XT core") or K6-3 CPU Memory Type Range Registers (MTRRs) to enable Write Combining during accesses to linear frame buffer aperture. It also sets GEWBED and DPE bits in EFER register, potentially speeding up all the memory accesses performed by the CPU.
The mechanisms are available starting with newer K6-2 CPUs of frequencies 300 MHz and above. Don't tell me that the features are K6-2 400-specific. My CPU is K6-2 300 and it is XT core. To check if CPU is a new version, look at the number printed in gold on the upper side of ceramic substrate. 26050 means old core, anything different than that (like 26351) - new core. Anyway MXK6OPT will check for CPU model before trying to optimize anything.
Write Combining is a feature which allows the CPU to collect several small data items with consecutive addresses into single 64-bit word before writing them to memory. This ability has severe impact on video memory accesses, because in most cases graphics software tends to write individual bytes or 16-bit words. Write Combining reduces the number of memory access cycles, trying to collect the data and transfer it in single, wide transfer instead of many small portions.
Once the registers are programmed, the program is finished and is no longer needed. It does not stay in memory nor actively influence the operation of computer.
Currently MXK6OPT works only in real mode, so for regular use it must be run from AUTOEXEC.BAT before Windows starts.

The effects

MXK6OPT speeds up the video memory accesses performed by CPU. This will influence data transfer rate and so-called "2D speed". The speed gain in benchmarks is between 3 and 15% (mostly 5..10%). Has no noticeable effects on "3D speed" - sometimes 1..3% speedup may be observed.

Command line options (v0.3 and newer)

Version 0.3 introduces some command line options. When run without any options it behaves exactly like v0.2 - the default behavior is marked with '*'.

First run

Boot plain DOS without EMM386 (or exit to DOS from Windows) and run MXK6OPT. The program is quite verbose in its current version - it will show what if finds and what it sets. It will also report the average video access speedup gained by setting the MTRRs. When you run the program for the second time, the speedup should be near 0 (may be from -2 to 2%).

Usage

If the program works correctly, configure your system to use it at every bootup.
MXK6OPT should be normally invoked from AUTOEXEC.BAT or CONFIG.SYS. In current version it cannot be used with EMM386. To call MX6OPT from CONFIG.SYS, put the following command "INSTALL=<full_path>MXK6OPT.EXE".

Problems, errors, testing

As for 99-01-13 the curren version of program was successfully tested on: The low-level video access speed on Mystique went up by 74% !!!
Once again: if the system becomes unstable, try -g option.
Please send me your results and remarks. Also, I would like to hear about running MXK6OPT on other video cards.

As a tribute to Matrox, pre-beta version 0.2 was made available on 9th Dec. 1998  :-).

Click here to go to MatroX files main page.