Designing a memory system

This is a discussion on Designing a memory system within the Tech Board forums, part of the Community Boards category; I am new to the hardware realm and am having difficulty with some work i've been assigned from a text ...

  1. #1
    Registered User
    Join Date
    Sep 2007
    Posts
    119

    Designing a memory system

    I am new to the hardware realm and am having difficulty with some work i've been assigned from a text book. Any help would be greatly appreciated.

    Question:
    --------------------------------------
    Given a supply of 4 bit wide DRAM chips containing 2^29 locations, you are asked to design a memory system for a machine with 8 DIMM slots where each DIMM slot provides word (32bit) wide data transfers and has a capacity of 2GB. How many chips are required per DIMM?

    Given a 32 bit address: <A31 A30 A2 A1 A0>, which bits will be used to:
    a) select a location on a given chip,
    b) select between chips on a DIMM and
    c) select between DIMM slots.

    Real-world memory systems commonly allow you to choose between different sized DIMMs (e.g. you can plug in either 1GB or 2GB DIMM sticks). How does this affect the address bits used in selecting chips, DIMMs, etc.? How do you think this is done?
    ----------------------------------------------------

    I'm not worried about the rest of the question yet, i'm still stuck on the first part (opening paragraph), "How many chips are required per DIMM?".

    I'm not looking for handouts, just something to get me started or point me in the right direction. Thanks in advance!

  2. #2
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,659
    2GB/8 (the number of slots) is the memory (in bytes) for each DIMM.
    Then divide that by 2^29 for the number of chips to span the address range.
    Since each chip is only 4 bits, you need 2 for a byte.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  3. #3
    Registered User
    Join Date
    Sep 2007
    Posts
    119
    I'm a bit confused,

    2 GB = 2, 147, 483, 648 bytes

    2, 147, 483, 648 bytes / 8 DIMM Slots = 268, 435, 456 bytes/Dimm slot

    268, 435, 456 bytes / 2^29 locations = 0.5 bytes/location

    0.5 bytes = 4 bits

    So only 1 chip per DIMM slot? (is that right?)

    Aside: These are some variables I gathered from the book

    *need main memoery word width of W bits made out of chips of width w
    -main memory word width W = 32 bits?
    -chip width w = 4 bits?

    *if address space is M and memory chip has N locations
    -address space M is...?
    -locations N is....?

    *You will need M/N rows of W/w chips where M >= N and W >= w (where N is a multiple of M and w is a multiple of W)

    I tried working with that somewhat, but get lost and am not 100% sure about the numbers i'm using.

    p.s. Thanks for the help so far!

  4. #4
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,659
    How about approaching it from the other end.
    How much is 2^29 and how many of them do you need to get to 2^31
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  5. #5
    Registered User
    Join Date
    Sep 2007
    Posts
    119
    2^31 / 2^29 = 4?

    so I need 4 chips per DIMM slot?

  6. #6
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,659
    Another thought.
    2^31 bytes = 2^29 dwords
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  7. #7
    Registered User
    Join Date
    Sep 2007
    Posts
    119
    I'm kind of lost at this point....further re-reads of the text book hasn't helped and i'm not sure what your trying to indicate to me at this point. Sorry...

  8. #8
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,659
    Two DRAM chips in parallel would be 2^29 bytes (8 bits wide)
    Four in parallel would be 2^30 bytes (16 bits wide)
    Eight in parallel....
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  9. #9
    Registered User
    Join Date
    Oct 2008
    Posts
    1
    -main memory word width W = 32 bits?
    -chip width w = 4 bits?
    Yup. So W/w = 8. You'll need 8 chips in parallel.

    -address space M is...?
    -locations N is....?
    address space M was given--2 GB.
    locations N was also given--2^29 bits.

    So M/N = 4; you will need 4 rows of chips.

    I'm probably missing something here... But what I don't understand is how you can select a, b, and c with just 32 bits. You'll need 29 bits to select the location, 5 bits to select the chip on a DIMM, and 3 bits to select a DIMM. Which equals... 37 bits.

  10. #10
    Registered User
    Join Date
    Sep 2007
    Posts
    119
    hold on a sec, you mean 32 rows, isn't 2GB => 2^34 bits. Than 2^34 / 2^29 = 32, so it's 32 rows of 8 chips.....Than is that the total amount of chips I need, 32 * 8...or what's the next step?

  11. #11
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    2GB = 2^31 bytes.

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  12. #12
    Registered User
    Join Date
    Sep 2007
    Posts
    119
    oh ok, so since the number of rows are 4, 4 rows of 8 chips....that means the total number of chips per DIMM slot is 32?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. To find the memory leaks without using any tools
    By asadullah in forum C Programming
    Replies: 2
    Last Post: 05-12-2008, 07:54 AM
  2. Memory usage and memory leaks
    By vsanandan in forum C Programming
    Replies: 1
    Last Post: 05-03-2008, 05:45 AM
  3. Replies: 4
    Last Post: 01-13-2008, 01:14 AM
  4. Pointer's
    By xlordt in forum C Programming
    Replies: 13
    Last Post: 10-14-2003, 02:15 PM
  5. System memory size?
    By dark_fusion in forum C Programming
    Replies: 3
    Last Post: 02-03-2002, 10:36 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21