title: How are memory registers used to hold different types?
body: <p>I have come under the impression that if a program reserves memory for a variable type <strong>integer</strong> (which is 8 bytes in size) the memory that is reserved will be 8 different registers that appear sequentially in memory.</p>
  <p>My questions are as follows:</p>
  <ol>
  <li><p>Assuming that answers will vary is my statement above a good generalization that each byte required by different types of variables equate out to that variable using 1 register in memory? (that is 1 byte  requires one register in memory)</p>
  </li>
  <li><p>If that is true how many bits does each register in memory hold? Or if I bought a 32-bit computer does that mean each register in memory holds 32 bits?</p>
  </li>
  <li><p>And if integer type needed 8 different registers for its size of 8 bytes what is contained in each different register?</p>
  </li>
  <li><p>Also I am trying to understand the idea of types. I know that if you have 32 bits to work with you could represent <strong>unsigned integer</strong> values from 0 to 4294967295. Yet if I stored the <strong>unsigned integer</strong> 4294967295 in a memory cell of 32-bits how would the CPU know that the binary representation within this memory cell needs to be decoded into the <strong>unsigned integer</strong> format? That is, is the memory set aside for a certain type specify that certain type or does a pointer specify the type or perhaps something completely different?</p>
  </li>
  </ol>
  <p>I am generally knowledgeable in the ideas of binary arithmetic, assembly language, references, pointers, and how variables and arrays are stored in the memory heap (so I'll understand any answers using these contexts). And I can program in C, C++, and Java. Thanks for any given help.</p>