title: Indirect function call uses odd address
body: <p>When the GCC 4.7.3 (20121207) for ARM Cortex-M3 takes the address of a function it doesn't get the exact address of the function. I can see an off-by-one in that pointer.</p>
  
  <pre><code>// assume at address 0x00001204;
  int foo() {
    return 42;
  }
  
  void bar() {
    int(*p)() = &amp;foo;  // p = 0x1205;
    p();               // executed successfully
    foo();             // assembly: "bl 0x00001204;"
  }
  </code></pre>
  
  <p>Although the pointer points to an odd address, the execution is successful. I would expect an exception at this point. Why does it takes that strange address and why doesn't it hurt.</p>
  
  <p><strong>Edit</strong></p>
  
  <ul>
  <li>The <a href="https://stackoverflow.com/questions/14120711/linux-kernel-why-a-functions-address-in-system-map-is-one-byte-before-its-add">SO article</a> describes a difference between thumb and ARM mode. Why is that offset not visible when the function is called directly although the CPU is in the same mode?</li>
  <li>Should the odd address be kept or would resetting the bit 0  cause hard? (what I could not see until now)</li>
  </ul>