memory - Differences in calculating address bits between word / byte addressable machines -



memory - Differences in calculating address bits between word / byte addressable machines -

im trying larn memory addressing (this uni) , im unsure effect word addressable memory have when need calculate number of address bits.

i explain (i think) understand first.

to calculate number of address bits utilize : log2(n) n number of bits of memory.i.e 1gb (1024mb * 1024 * 1024)= 1073741824 bits hence log2(1073741824 ) = 30 meaning 1gb memory require 30 address bits. think im understanding correctly.

the part im not sure byte addressable memory versus word addressable memory , how might effect number of address bits.

the question: above illustration right byte addressable , if instance memory word addressable , using 16 bit or 32 bit words number of address bits required less (1/2 or 1/4 in case of 16 , 32 bit words)??

my thinking if cel holds 8 bits in byte addressable machine cel in word addressable memory hold 16bits or 32bits , hence address bits required should less.

further notes - aware memory nowadays byte addressable , word size in computer specific processor / bus , problems im working on not mention , inquire effect byte /word addressable have.

i have searched other questions on , not found 1 answers (or understand reply it) . examplehttps://stackoverflow.com/questions/19528750/byte-word-addressable seems asking similar thing op seems have posted question incorrectly specifying memory 4m x 16 (instead of 4mb x 16bit) leading people calculate memory 64mb.

first off, need careful bits , bytes, original illustration have seems deal bits, each seem want know bytes. matter when dealing bit addressable memory or byte addressable memory. so, lets talk things in terms of byte addressable or word addressable memory.

as stated, analysis of how number of bits needed address memory correct; can generalized. in order minimum number of bits need address memory, need know how many unit-size things can address. in case, calculating number of addresses need address 1 gb (giga-bit) memory. can in bytes, in order byte address 1 gb (giga-byte) memory, need know number of addressable things (bytes) there , take log2 of it. so, number of things there easy get, (1 gb has 1024^3 or 1 g bytes in it) need log2 that; log2(1 g) = log2(1024*1024*1024) = 3*log2(1024) = 3 * 10 = 30. so, need 30 bits address space.

now lets talk in words. first knowing word size. word size not strictly 32 or 16 bits, can range of values, typically dependent on whatever processor decides phone call word (or spec is). lets deal in 32-bit words our example.

now have word size, need know memory size. lets assume same 1 gb before, word addressing (its word addressable memory , word size 32 bits or 4 bytes). so, before, need know number of addressable things (now words) there in memory size. well, time isnt 1 g, because our addressable thing 4 b in size instead of 1 b. need take our 1 gb memory size , split word size (1 gb / 4 b = 0.25 g). before, have number of addressable things (0.25 g), need log2 of it; log2(0.25g) = log2 (256*1024*1024) = log2(256) + 2*log2(1024) = 8 + 2 * 10 = 28.

it downwards number of addressable things (words, bytes, bits) in given memory. typically give memory sizes in bytes, byte addressable calculations easy, others take little manipulation dimensional value (1 gb) dimensionless value (1 g, ie 1024^3).

memory computer-architecture

Comments

Popular posts from this blog

assembly - What is the addressing mode for ld, add, and rjmp instructions? -

vowpalwabbit - Interpreting Vowpal Wabbit results: Why are some lines appended by "h"? -

Is there a way to convert an HTML page styled with Bootstrap CSS into email-compatible html? -