Windows 7's Use of Virtual Environments to Support Applications

As I get ready for the Microsoft 70-680 I just wanted to share something that really impresses me about the way Windows 7 supports different applications. It does not allow every program and its strings access to the physical kernel, instead multiple VDMs are created based on the type of application being run.

Win32 Applications – Most common type of application used with operating systems like Windows XP. Becoming less popular as .Net replaces it. Each Win32 application runs in its own virtual memory space and is executed by the processor in user mode. If the Win32 application crashes, it will not affect other Win32 applications or the operating system's kernel Executive services.

Net Applications – The new preferred way for applications to access the operating system service. The .Net Framework provides a layer of abstraction that is useful for developers to perform complex tasks more simply because the .NET framework manages the details of accessing required services. Developers should create new applications by using the .NET framework not only to simplify development, but also to ensure compatibility with future operating systems. Future versions of Windows may not support Win32 applications. However, the .NET framework 3.0 isolates applications from any change to the Win32 subsystem.

DOS Applications – 32bit versions of Windows 7 support the execution of legacy DOS applications. A special Win32 process called ntvdm.exe creates a virtual DOS machine (VDM) environment for that DOS application. Ntvdm.exe and the Win32 subsystem control the applications access to the host computers hardware. Full screen support in these applications are not available in Windows 7.

Win16 Applications – ntvdm creates a virtual environment to run 16bit programs that were once compatible with Windows 3.x. Where as DOS applications get their own VDM, only one is created to handle Win16 apps. This is an instance of ntvdm.exe and an application called wowexec.exe. Wowexec.exe is part of the Windows 7 operating system and supports Win16-on-Win32 execution. Since these apps run on the same VDM, a single program crashing can wipe out all other Win16 apps. While this is the default setting, you can change it to allow all Win16 apps to have their own VDM.

x64 Application Considerations – This is a VDM for x64 versions of Windows 7 that can support 32bit applications with a Win32-on-Win64 (WOW64) virtual environment.
DOS and Win16 apps are not supported.

This entry was posted in . Bookmark the permalink.

Leave a Reply