title: What is the difference between intXX_t and int_fastXX_t?
body: <p>I have recently discovered existence of standard <em>fastest</em> type, mainly <a href="http://www.linuxbase.org/navigator/browse/type_single.php?cmd=display&amp;Tid=16619">int_fast32_t</a> and <a href="http://www.linuxbase.org/navigator/browse/type_single.php?cmd=display&amp;Tid=16620">int_fast64_t</a>.</p>
  
  <p>I was always told that, for normal use on mainstream architecture, one should better use classical <em>int</em> &amp; <em>long</em> which should always fit to the processor default reading capacity and so avoid useless numeric conversions.</p>
  
  <p>In the C99 Standard, it says in §7.18.1.3p2 : </p>
  
  <blockquote>
    <p>"The typedef name int_fastN_t designates the fastest signed integer type with a width of at least N. The typedef name uint_fastN_t designates the fastest unsigned integer type with a width of at least N."</p>
  </blockquote>
  
  <p>And there is also a quote about it in §7.18.1.3p1 :</p>
  
  <blockquote>
    <p>"The designated type is not guaranteed to be fastest for all purposes; if the implementation has no clear grounds for choosing one type over another, it will simply pick some integer type satisfying the signedness and width requirements."</p>
  </blockquote>
  
  <p>It's unclear to me what <em>fastest</em> really means. I do not understand when I should use this type and when I should not. </p>
  
  <p>I have googled a little on this and found that some <a href="http://lists.gnu.org/archive/html/qemu-devel/2011-03/msg00454.html">open</a> <a href="http://cekirdek.pardus.org.tr/~ismail/ffmpeg-docs/simple__idct__alpha_8c.html">source</a> <a href="http://patchwork.ozlabs.org/patch/85610/">projects</a> have changed some of their functions to it, but not all of them. They didn't really explain why they have changed a part, and <em>only</em> a part, of their code to it.</p>
  
  <p>Do you know what are the specific cases/usages when int_fastXX_t are <em>really</em> faster than the classical ones ? </p>