Intel
Let's start with Intel's products. When they moved to the new LGA775 style processors, they went from using a product name and processor speed, to using a product name and processor number. The product numbers are three digits long, the first digit tends to signify part of a series. These series currently work as follows:
800 – Pentium D or Pentium Extreme Edition
700 – Pentium M
600 – Pentium 4
500 – Pentium 4
300 – Celeron D or Celeron M
You'll see that without introducing any more numbers, things are a little confusing already. A 300 chip could be a desktop Celeron D or a mobile Celeron M and there are both 500 and 600 range Pentium 4s. The 800s could be Pentium D or Pentium Extreme Edition CPUs. Luckily, some of these can be explained quite easily.
What's important to remember is that the name of an Intel CPU isn't based solely on the number. Look at both the brand and the number. An '840' could represent either a Pentium Extreme Edition 840, or a Pentium D 840. Both are very similar in specifications, but the Pentium Extreme Edition 840 features HyperThreading support.
The same rings true for the difference between a Celeron M and a Celeron D. Don't just check the number, check the name too, then it'll be clear whether you're dealing with a desktop or mobile Celeron.
The main difference between the two Pentium 4 ranges is that the 500 range have 1MB of L2 cache, whereas the 600 range have 2MB. These differences, while not obvious just from the numbers, are logical.
Let's look now at the remaining two digits. These distinguish between the different processors within a particular family. A Pentium 4 540 will perform better than a Pentium 4 530. A Pentium 4 541 is very similar to the Pentium 4 540, but features EM64T (64-bit) support – a subtler difference in product codes to signify a change to the set of features than performance.
Certain processors feature a 'J' suffix to the product number, to signify a different stepping to its brethren, introducing new features such as 'Execute Disable Bit'.
Clearly, there's a lot to take in, but Intel don't want to make it too hard to understand. Processors that are part of the same family will all have the same first number (except the Pentium 4, where we have both 500 and 600 thanks to the doubled cache of the latter chips.) The second and third numbers indicate where within the family that processor fits in terms of performance, the third number sometimes used to signify product differences where the clock speed doesn't actually change.