Microsoft used to have two main lines of operating systems. The first was the Windows line. Ignoring everything before win95, this would include Windows 95, 98, and ME. The other line was the NT line, which is NT 4.0, Windows 2000, and XP. To give you a clearer idea of what is going on underneath the hood, windows operating systems identify themselves as follows:
Windows 95: windows 4.0
Windows 98: windows 4.1
Windows ME: windows 4.2
Windows NT: NT 4.0
Windows 2000: NT 5.0
Windows XP: NT 5.1
This also helps to put them in perspective with older versions, which used the regular numbering scheme (i.e. windows 3.1).
95, 98, and ME are all designed to be backwards compatible to MS-DOS. They allow DOS programs to do what DOS programs normally do, which is access all of the hardware themselves (since DOS didn’t have drivers, there wasn’t much of a choice, the software had to access the hardware itself).
All of the NT versions take a different approach. The NT versions have what is called a “hardware abstraction layer” aka HAL. NT doesn’t allow software to directly access hardware. Instead the software has to ask HAL to access the hardware for it. This prevents really badly misbehaving programs from doing some major damage to the running environment. HAL is the major thing that prevents a lot of windows and DOS programs from working, because the software thinks it’s trying to access real hardware and HAL only gives them simulated hardware (I’m sorry Dave, but I can’t do that…).
There are two basic things you need to consider. First is that the underlying structure of the operating systems are completely different. Old games will often not run under NT. A lot of DOS software won’t run under NT. Generally speaking, software that runs on Windows (95, 98, and ME) operating systems will run ok on other Windows operating systems, and software running on NT operating systems will work on other NT systems, but you face a larger risk when jumping between product lines.
The second thing to consider is that microsoft very much intentionally will break backwards compatibility if they think they can make the software “better.” This means that the operating system calls that your software uses may work differently between different versions of windows. This can very easily cause a program written to run on NT 4.0 to not run at all under XP, despite the fact that they are both NT versions of windows.
Your largest risks of having something not work are when you jump product lines (between windows and NT) and the larger the version number change (for example, between NT and XP, which is 4.0 to 5.1). 2000 to XP is a relatively safe jump, because it’s really only a minor version change (5.0 to 5.1). Despite the totally different look and feel, XP and 2000 are almost identical underneath the hood.
Later operating systems also use a lot of fancy things to make them look better, like fades between windows and all sorts of little visual tricks that you may not really notice much, but give you the general appearance of it working “better.” This requires more CPU time to do all of these fancy effects, so later versions of windows tend to require much higher CPU speeds just to run the basic desktop.