Re: bug in bit32?
Mark Slicker <[email protected]>
| Newsgroups | gmane.comp.lang.forth.colorforth |
|---|---|
| Message-ID | <[email protected]> |
On Fri, 6 May 2005, Albert van der Horst wrote: > I expect EAX to be three time a character value, such that it contains > all zero's in the upper 16 bits. > > Indeed bit16 is called 24 times. But only the first time > something is deposited at [DI]. After that zero's have been > shifted into AX. > Similarly bit32 is called 24 times. Again only the first > time something is deposited at [DI]. The second time > EAX is already zero, in view of the values supplied. > After that again EAX is certainly zero. > > So this would mean that it doesn't matter whether a 16 or 32 bits > register is shifted. Apart from that I don't claim to understand > much of what is going on. I don't follow this analysis. You should probably review again the source code. The way bit16 works is that is will shift the bits one by one into the carry bit, if the carry bit is set it will write a pixel. I does this 16 times. bit32 is similar execpt it will write four pixels if the carry bit is set. > Your conclusion could be checked by placing a character C on the > lowest line. It should look bad with one line missing. If you want a test to demonstrate try: : ok show black screen text 13 2emit ; 13 is the character 'g' which uses that bottom row.