Is that the right way to refer to 32-bit and 64-bit machines?
Technically x86 simply refers to a family of processors and the instruction set they all use. It doesn't actually say anything specific about data sizes.
x86 started out as a 16-bit instruction set for 16-bit processors (the 8086 and 8088 processors), then was extended to a 32-bit instruction set for 32-bit processors (80386 and 80486), and now has been extended to a 64-bit instruction set for 64-bit processors. It used to be written as 80x86 to reflect the changing value in the middle of the chip model numbers, but somewhere along the line the 80 in the front was dropped, leaving just x86.
Blame the Pentium and it's offspring for changing the way in which processors were named and marketed, although all newer processors using Intel's x86 instruction set are still referred to as x86, i386, or i686 compatible (which means they all use extensions of the original 8086 instruction set).
x64 is really the odd man out here. The first name for the 64-bit extension to the x86 set was called x86-64. It was later named to AMD64 (because AMD were the ones to come up with the 64-bit extension originally). Intel licensed the 64-bit instruction set and named their version EM64T. Both instruction sets and the processors that use them are all still considered x86.
Yes that's correct:
The term x86 refers to a family of instruction set architectures based on the Intel 8086. The 8086 was launched in 1978 as a fully 16-bit extension of Intel's early 8-bit based microprocessors and also introduced segmentation to overcome the 16-bit addressing barrier of earlier chips. The term x86 derived from the fact that early successors to the 8086 also had names ending in "86".