Programming Forums

Programming Forums (http://www.programmingforums.org/forumindex.php)
-   Assembly (http://www.programmingforums.org/forum20.html)
-   -   the cpu's memory addressing (http://www.programmingforums.org/showthread.php?t=13762)

odin Aug 13th, 2007 5:30 PM

the cpu's memory addressing
 
hi all
i am little confused about memory addressing
the 8080 processor can address 64k but it can only process 1byte

Quote:

so my first question is why address 64k while it only can process 1byte
while i was reading the writer said :
there is no relation between the number of address lines in a memory system and the size of the data stored at each location and still has 16 address lines??

Quote:

how come ? i mean the processor put 8 bit in each time so how can it put more than 8bits in one location ???
and i have another question is there is any difference between memory addressing and processing

like i said before it can address 64k but it can process 8bit(1byte) ? so what is the difference ?

thanks in advance

Wizard1988 Aug 13th, 2007 5:35 PM

Addressing and processing are two entirely different things. Addressing is the location of the data and processing is, well what you do to the data.

odin Aug 13th, 2007 5:39 PM

that was fast
Quote:

Addressing is the location of the data
why should it address more than it can process ?
does it take allot of time to address 8bits ? i know that 1bit takes 70nano second so i guess 1 byte will take 70*8=560 nanosecond
am i thinking wrong ?
thanks for your replay any way

odin Aug 13th, 2007 5:41 PM

one more thing
what if a program require more than 64k of memory :s
fuzzy :s

odin Aug 13th, 2007 5:44 PM

it takes more time if the processor address 1byt each time to fetch 1byt each time
instate it address 64k and reading from it each time using the ip(instruction pointer)

but wait doesn't the ip save the address of the next place to fetch from the address ? so it will address this memory again :-|

Quote:

one more thing
what if a program require more than 64k of memory :s
fuzzy :s

DaWei Aug 13th, 2007 6:05 PM

Odin, you are being a little bit dumb here. I may build a post office that serves 2000 people. Each post office box is designed to hold only one letter. If I work with the contents of one PO Box, I have only one letter. I can still choose to operate on any one of 2000 PO boxes. Therefore, I can operate on up to 2000 different letters (values).

The ip is one thing. It addresses instructions in sequence, unless instructed to jump. Memory addresses are another thing entirely. They are not instructions, but operands.

I don't know if you are unwilling to apply serious thought to tutorial materials, or if you are incapable of understanding simple precepts. If it takes actual experience to make you understand, then you need to learn about hardware logic and build a microprocessor from scratch. You'll either figure it out, or go have your hand fitted for a mop and settle for janitorial duties.

odin Aug 13th, 2007 6:40 PM

thanks for let me know i am dump :D i am just joking
sorry for bothering you
post office that serves 2000 --> processor serves 2000 bit of memory
post office box is designed to hold only one letter --> the address line that contain the address of the bit
can still choose to operate on any one of 2000 PO boxes --> bits of the memory

i am trying to organize my mind :@

first of all 16bit address lines can serve 64k bit how ?
i searched on googlde and i found
http://www.pcguide.com/vb/archive/in...p/t-30381.html
this man says that
Quote:

One address line can select up to two memory locations
so that's why it can access 64k of memory with 16bit address lines
that's one step
so when the book says address lines address 64k of memory means that it can access it and fetch from it

so that's why also the cpu can put more than 8bit in one location because it can access 64k of memory
that's another step

thanks allot and i hope if there is something wrong you will tell me

odin Aug 13th, 2007 6:43 PM

Quote:

don't know if you are unwilling to apply serious thought to tutorial materials
no i love to learn this stuff can you tell me where can i find this
or maybe give me some keywords and i will search

can i ask you a favor ?
can you tell me where i can find a place i can start in electronics from 0
so that i can understand this much better ?
thanks in advance

Wizard1988 Aug 13th, 2007 9:16 PM

Read this x2

http://en.wikipedia.org/wiki/Addressing_mode

lectricpharaoh Aug 13th, 2007 9:42 PM

Think of it this way. Imagine you have one of those CD players that can hold 200 discs. Thus, you can say that it has an addressing range of 200 units (discs, in this case). The unit can, however, only play (process) one disc at a time, much as the 8-bit processor can only process byte values.

The data bus dictates the size of operands, ie memory quantities (and often, but not always, register width). The address bus dictates the number of memory operands that can be accessed- not how many can be accessed at once, but how many can be accessed, period.

Remember that the data bus determiens the size, in bits, but the address bus determines the number of locations. Each location is typically several bits (often eight), and called a byte. A byte is the smallest quantity that you can address directly; if you want to access an individual bit within that byte, you must use bit-fiddling instructions (bit-shifting, AND/OR/XOR, etc).

One last thing: learn to edit your posts when you want to add content three minutes after your last post. It's much better that seeing five posts in the same thread from the same person in a five-minute span.


All times are GMT -5. The time now is 3:02 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC