@!@%*! <=== that's Klingon for Argggh!

Thanks Rex, we don't want to leave mangled claptrap 'round to further confuse the not-yet-knowing!

Yup, I was thinking hex and binary at the same time, and failed to keep them surgically separate! I'd originally represented the eax register content in hex, then thought it would be better, clearer, if I typed out the bits! (....! <= more Klingon, but cloaked!)

Of course, for the "bit" representation of eax I meant to type:

  eax:   00000000 00000000 00000001 00000010     <== binary
  eax:         00       00       01       20     <== hex


I also removed a discussion of bit order reversal (Least Significant Bit first) in serial comms lines, SYNC sequences, et cetera. Chris M. or any number of others would do that topic better than I would.

So much "stuff" has gone under the bridge in the last 50 or 60 years, but in 100 years time there will still be 6 year olds stumbling on rusted-up gems buried in <insertnameoffavouritesearchengineofthe22ndcenturyhere>. The Internet is becoming our muddy lake bottom, preserving stuff for far distant futures.

Graeme

At 06:13 AM 13/04/2011, you wrote:
Graeme,

Sorry, but I just have to do this. X86 registers work in trinary mode rather than binary? Your map of the eax register shows.

eax: 00000000 00000000 00000001 00000020 <====== What's the 00000020 mean? :-)

Rex

-----Original Message-----
From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf Of Graeme Gibson
Sent: Monday, April 11, 2011 11:42 PM
To: [email protected]
Subject: Re: New job for mainframes: Cloud platform

Well, let's not skew the kiddie's brains too much..

"Endian- ness", in the context used in these posts, refers to BYTE
order not BIT order.

The bit-order *within each byte* is still "most significant on the
left" in both big- and little- endian systems.

Another wrinkle:  In the x86 world (little-endian) Intel "names" the
bits within a byte, from the left, 7,6,5,4,3,2,1,0 whereas in the z..
world (big-endian) IBM "names" them 0,1,2,3,4,5,6,7.  Regardless of
the naming scheme used, the "rightmost" bit in each byte is the
least-significant. :-)

An x86 code fragment might help to illustrate:

         .code
         mov eax,258     ;let's start with 258 KG
         mov weight,eax
         ..
         ..
         ret
         .data
weight  dd  0           ;weight in kilograms

After that 2nd mov instruction, while the 32-bit eax register looks like:

        bits 32,31,..,24
        |        bits 23,22,..,16
        |        |        bits 15,14,..,8
        |        |        |        bits 7,6,5,..,0
        |        |        |        |
eax:   00000000 00000000 00000001 00000020

..the four bytes at label "weight" will look like:

weight 00000010 00000001 00000000 00000000
        |        |        |        |
        |        |        |        bits 32,31,..,24
        |        |        bits 23,22,..,16
        |        bits 15,14,..,8
        bits 7,6,5,..,0

So, bit numbering aside, it still looks like a big-endian world once
you're "inside" the processor.

Cheers,
Graeme

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to