title: What precision are floating-point arithmetic operations done in?
body: <p>Consider two very simple multiplications below:</p>
  
  <pre><code>double result1;
  long double result2;
  float var1=3.1;
  float var2=6.789;
  double var3=87.45;
  double var4=234.987;
  
  result1=var1*var2;
  result2=var3*var4;
  </code></pre>
  
  <p>Are multiplications by default done in a higher precision than the operands? I mean in case of first multiplication is it done in double precision and in case of second one in x86 architecture is it done in 80-bit extended-precision or we should cast operands in expressions to the higher precision ourselves like below?</p>
  
  <pre><code>result1=(double)var1*(double)var2;
  result2=(long double)var3*(long double)var4;
  </code></pre>
  
  <p>What about other operations(add, division and remainder)? For example when adding more than two positive single-precision values, using extra significant bits of double-precision can decrease round-off errors if used to hold intermediate results of expression.</p>