<br><br><div class="gmail_quote">On Wed, Dec 24, 2008 at 3:39 AM, Chris Lattner <span dir="ltr"><<a href="mailto:clattner@apple.com">clattner@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="Ih2E3d"><br>
On Dec 23, 2008, at 12:36 AM, Zhongxing Xu wrote:<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
As the comments said, BitstreamReader::GetCurrentBitNo() should return the bit # of the bit we are reading. But the current implementation actually return 4 more bytes than the bit we are reading. It calculate the bit number by<br>

<br>
(NextChar-FirstChar)*8 + ((32-BitsInCurWord) & 31);<br>
<br>
But 'NextChar' is already after the word that we are reading. I propose to fix this by the following patch.<br>
</blockquote>
<br></div>
Hi Zhongxing,<br>
<br>
This is ok as long as it doesn't cause any regressions in the *llvm* dejagnu regression tests, thanks!</blockquote><div><br>OK.<br> </div><br></div><br>