title: Should I bit-shift to divide by 2 in Java?
body: <blockquote>
    <p><strong>Possible Duplicates:</strong><br>
    <a href="https://stackoverflow.com/questions/1168451/is-shifting-bits-faster-than-multiplying-and-dividing-in-java-net">Is shifting bits faster than multiplying and dividing in Java? .NET?</a><br>
    <a href="https://stackoverflow.com/questions/1514949/quick-java-optimization-question">Quick Java Optimization Question</a>  </p>
  </blockquote>
  
  
  
  <p>Many years ago in college, I learned that bit-shifting right by one accomplishes the same thing as dividing by two, but is generally significantly faster.  I'm not sure how Java has come along in that regards since the 9-10 years ago I learned about that.  Does the Java compiler automatically converts a divide-by-two into a bit-shift operation, or should I manually perform the bit-shift operation in the code myself?</p>