Re: Disassembly of Farbrausch's "fr-016: bytes"

Dave Long <[email protected]>
Newsgroups gmane.culture.people.kragen.discuss
Message-ID <[email protected]>
I was testing out a rudimentary python 16-bit x86 assembler with the  
code from:

http://canonical.org/~kragen/demo/fr-016.html

and, although my source:

> org 100
> mov ax,13
> int 10
> les bp,[bx]
>
> l loop
> stosb
> adc ax,di
> adc ax,1132
> jmp loop


results in a slightly different 15 bytes:

0000000: b813 00cd 10c4 2faa 11f8 1532 11eb f8    ....../....2...

I still get the same visual output in QEMU.

So:

I think the 1132 is an immediate, and the FS override is there (a) as  
padding or (b) to potentially confuse disassemblers.

dc -e '16i2o 1132p' yields 1000100110010, so it seems reasonable that  
the second adc helps create a nice LFSR-like term.  But I don't  
understand why your attempts at manually removing the FS override  
wouldn't have given the same behavior that I see.

-Dave

-- 
To unsubscribe: http://lists.canonical.org/mailman/listinfo/kragen-discuss
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.