Architecture of Windows 9x
This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these template messages)(Learn how and when to remove this template message)
- 1 Critical files
- 2 Boot sequence
- 3 Kernel
- 4 See also
- 5 References
- 6 Further reading
- 7 External links
Windows 95 boots using the following set of files:
32-bit shell and command line interpreter;
- SHELL.DLL and SHELL32.DLL – Shell API,
- EXPLORER.EXE – Windows shell and file manager,
- COMMAND.COM – command line shell executable,
Windows 95 Core;
- KERNEL32.DLL and KRNL386.EXE – Windows API for Windows resources,
- ADVAPI32.DLL Functionality additional to the kernel. Includes functions for the Windows registry and shutdown and restart functions,
- GDI32.DLL and GDI.EXE - Graphic device interface,
- USER32.DLL and USER.EXE - GUI implementation,
- COMMCTRL.DLL and COMCTL32.DLL - Common controls,
- DDEML.DLL Dynamic Data Exchange Management Library (DDEML) provides an interface that simplifies the task of adding DDE capability to an application,
- MSGSRV32.EXE Acts as a 32-bit message server and will never appear in the Windows task list,
- WIN.COM - responsible for loading the GUI and the Windows portion of the system,
Registry and other configuration files;
- SYSTEM.DAT, USER.DAT - contains the Windows Registry,
- MSDOS.SYS - contains some low-level boot settings such as disabling double-buffering or the GUI logo,
- WIN.INI and SYSTEM.INI - configuration files from Windows 3.1, processed in Windows 9x also,
Virtual Machine Manager and configuration manager;
- VMM32.VXD - Virtual machine manager and default drivers,
Installable file System Manager;
- IFSHLP.SYS - enables Windows to make direct file system calls bypassing MS-DOS methods,
- IFSMGR.VXD - 32-bit driver for the installable file system,
- IOS.VXD I/O Supervisor that controls and manages all protected-mode file system and block device drivers,
- MPREXE.EXE MPRSERV.DLL and MPR.DLL - Multiple Provider Router, required for network authentication and user profiles,
- MSPWL32.DLL Password list management library,
- IO.SYS - executable handling all of the basic functions, such as I/O routines,
- HIMEM.SYS - DOS device driver which allows DOS programs to store data in extended memory via the Extended Memory Specification,
- SYSTEM.DRV, MMSOUND.DRV, COMM.DRV , VGA.DRV, MOUSE.DRV, BIGMEM.DRV, KEYBOARD.DRV - 16-bit drivers,
- CP 1252.NLS, CP 437.NLS, UNICODE.NLS, LOCALE.NLS - keyboard layouts,
- RMM.PDR Real Mode Mapper Virtual Device.
The system may also use CONFIG.SYS, which contains settings and commands executed before loading the command interpreter) and AUTOEXEC.BAT, which is a batch file automatically executed after loading COMMAND.COM. However, these two files are not critical to the boot process, as IO.SYS contains a default setting for both, in case of absence from the system. In Windows ME, CONFIG.SYS and AUTOEXEC.BAT are not processed and LOGO.SYS may be used as a splash screen.
Phase 1 - The ROM BIOS Bootstrap Process
The ROM BIOS starts the execution at the physical memory address FFFF0h. During this phase, BIOS first executes the Power-on self-test, then checks for the existence of a boot disk on drive A. If it is not found in drive A, the ROM BIOS checks for a hard disk. If the computer has a Plug and Play BIOS, in addition, BIOS checks the RAM for I/O port addresses, interrupt lines and DMA channels for Plug and Play devices, disables found devices, creates maps of used and unused resources and re-enables devices.
Phase 2 - The Master Boot Record and Boot Sector
The Master boot record is loaded at address 7C00h and loads the boot sector of the Windows Disk partition. The boot sector contains the disk boot program and BIOS Parameter Block table which searches for the location of the root directory and IO.SYS file, which then loads the IO.SYS file into memory.
IO.SYS initializes the minimal File Allocation Table driver and loads MSDOS.SYS into memory. It then displays "Starting Windows" depending on the BootDelay=<n> line in the MSDOS.SYS file. It then loads the LOGO.SYS file and displays a startup image on the screen. If the DRVSPACE.INI or DBLSPACE.INI file exists, it also loads drivers for compressed disks. Windows then attempts to open the registry file SYSTEM.DAT. If that fails, it attempts to open SYSTEM.DA0. If configured in MSDOS.SYS or in the registry, double buffering is also enabled.
Phase 4 - CONFIG.SYS and real mode configuration
Windows 95 and Windows 98 now analyze CONFIG.SYS and load MS-DOS real mode drivers. Windows ME ignores this. If the CONFIG.SYS file does not exist, the IO.SYS file loads the drivers IFSHLP.SYS, HIMEM.SYS and SETVER.EXE. Windows reserves all upper memory blocks for Windows 95 operating system use or for expanded memory. Windows 95 and Windows 98 execute COMMAND.COM to process AUTOEXEC.BAT. It loads terminate and stay resident programs into memory. Windows ME ignores this step.
Phase 5 - Initialize drivers
IO.SYS now runs WIN.COM. WIN.COM loads the VMM32.VXD file into memory or accesses it from the hard disk. This file contains the most important drivers. The real-mode virtual device driver loader checks for duplicate virtual device drivers that exist both in the Windows\System\Vmm32 folder and the VMM32.VXD file. In a case of duplicates, the driver in the Windows\System\Vmm32 directory will be loaded. Windows 95 and 98 now query real mode drivers calling INT 2Fh and search for drivers in registry entry HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\VxD marked to be loaded as an external file. Vmm32 then analyzes the [386 Enh] section of the Windows\System.ini file and loads drivers listed there. Some important drivers are loaded even if they are not listed in the Windows Registry, SYSTEM.INI or in the Windows\System\Vmm32 directory.
Once the real-mode virtual device drivers are loaded, driver initialization on Windows 95 and Windows 98 occurs. Vmm32 then switches the CPU from real mode to protected mode. The next step is the initialization of protected mode drivers, executed in three phases for each device: a critical part of initialization (while interrupts are disabled), device initialization (when file I/O is allowed) and InitComplete phase. After initialization of the display driver, Windows switches to graphical mode.
Phase 6 - Win32 initialization
Once all of the drivers are loaded, the Kernel32.dll, gdi32.dll, Gdi.exe, user32.dll, User.exe, shell32.dll and Explorer.exe files are loaded. The next step in the startup process is to load the network environment. The user is prompted to log on to the network that is configured. When a user logs on, their desktop settings are loaded from the registry, or the desktop configuration uses a default desktop. Windows then starts programs defined in the StartUp folder, WIN.INI and programs defined in registry keys Run, RunOnce, RunServices and RunServicesOnce inside the branches HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion and HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\. After each program in the RunOnce registry key is started, the program is removed from the key.
The Windows 9x kernel is a 32-bit kernel with virtual memory. Drivers are provided by .VXD files or, since Windows 98, the newer WDM drivers can be used. However, the MS-DOS kernel stays resident in memory and Windows will use the old MS-DOS 16-bit drivers if they are installed.
- Schulman, Andrew (November 1994). Unauthorized Windows 95 - Developer's Resource Kit (1st ed.). Foster City, California, USA: John Wiley & Sons, Inc. ISBN 1-56884-305-4. ISBN 978-1-56884-305-6.
- Schulman, Andrew; Brown, Ralf D.; Maxey, David; Michels, Raymond J.; Kyle, Jim (1994). Undocumented DOS: A programmer's guide to reserved MS-DOS functions and data structures - expanded to include MS-DOS 6, Novell DOS, and Windows 3.1 (2nd ed.). Reading, Massachusetts: Addison Wesley. ISBN 0-201-63287-X. ISBN 978-0-201-63287-3.
- Paul, Matthias (2002-04-10). "[fd-dev] HMA access from TSR". Archived from the original on 2017-09-09. Retrieved 2017-09-09.
[…] MS-DOS 7.0+ […] introduced a […] for the most part undocumented RMD data structure usually located in the HMA. The kernel collects and records configuration and Real Mode Driver data during boot (type of driver, interrupts hooked by driver, CONFIG.SYS line of invocation, etc.) and stores this information in a […] complicated […] growing data structure. Presumably […] meant to be used by the Windows core to get a better picture of the loaded Real Mode drivers […] or even attempt to unhook or unload some of them, […] it is only used to a very limited extent ([…] some of the info reflected in the log files created on […] startup, and some parts of the […] configuration manager also make use of it), […] leaving room […] beyond the technical side […] because nothing of the interesting stuff is documented […]
- Paul, Matthias (2002-08-13). "Suche freien Speicherbereich unterhalb von 1 MB, der nicht von OS überschrieben wird". de.comp.lang.assembler.x86 (in German). Archived from the original on 2017-09-03. Retrieved 2017-09-03. (NB. Also on MS-DOS 7+ HMA usage and \WINDOWS\IOS.LOG.)
- King, Adrian (1994). Inside Microsoft Windows 95 (2nd ed.). Redmond, Washington, USA: Microsoft Press. ISBN 1-55615-626-X. ISBN 978-1-55615-626-7.
- Programmer's Guide to Microsoft Windows 95: Key Topics on Programming for Windows from the Microsoft Windows Development Team. Technical Reference (1st ed.). Redmond, Washington, USA: Microsoft Press. 1995-07-01. ISBN 1-55615-834-3. ISBN 978-1-55615-834-6. Retrieved 2016-05-26.
- Oney, Walter (1995). Systems Programming for Windows 95 (1st ed.). Redmond, Washington, USA: Microsoft Press. ISBN 1-55615-949-8. ISBN 978-1-55615-949-7.
- Pietrek, Matt (November 1995). Windows 95 System Programming Secrets. The Secrets Series (1st ed.). John Wiley & Sons, Inc. ISBN 1-56884-318-6. ISBN 978-156884-318-6. Retrieved 2016-05-26.
- Hazzah, Karen (1997). Writing Windows VxDs and Device Drivers - Programming Secrets for Virtual Device Drivers (2nd printing, 2nd ed.). Lawrence, Kansas, USA: Miller Freeman, Inc. ISBN 0-87930-438-3. ISBN 978-0-87930-438-6.
- Mitchell, Stan (1997-05-11). Schulman, Andrew, ed. Inside the Windows 95 File System. Nutshell handbooks (1st ed.). Sebastopol, California, USA: O'Reilly & Associates, Inc. ISBN 1-56592-200-X. ISBN 978-1-56592-200-6. Retrieved 2016-05-26.
- Microsoft. "Windows 95 Architecture Components". Microsoft. Archived from the original on 2014-10-17. Retrieved 2016-05-27.
- Microsoft (2006-11-15). "Description of the Windows 95 Startup Process". 1.1. Microsoft. Q174018. Archived from the original on 2014-02-14. Retrieved 2016-05-27.
- Microsoft (2013-10-26). "Understanding Win16Mutex". 5.0. Microsoft. KB125867. Q125867. Archived from the original on 2014-01-16. Retrieved 2016-05-27.