Like Tree1Likes

Memory and storage

This is a discussion on Memory and storage within the C++ Programming forums, part of the General Programming Boards category; Originally Posted by Salem Some of the more obscure DSP chips apparently have CHAR_BIT set to 32 (and by implication, ...

  1. #16
    Registered User
    Join Date
    Jun 2005
    Posts
    6,625
    Quote Originally Posted by Salem View Post
    Some of the more obscure DSP chips apparently have CHAR_BIT set to 32 (and by implication, sizeof(int)==sizeof(char)==1)
    That implication is not necessarily valid. sizeof(char) is 1, by definition, but even if CHAR_BIT is 32 there is no requirement that an int must be 32 bits.
    Right 98% of the time, and don't care about the other 3%.

    If I seem grumpy or unhelpful in reply to you, or tell you you need to demonstrate more effort before you can expect help, it is likely you deserve it. Suck it up, Sunshine, and read this, this, and this before posting again.

  2. #17
    Programming King Mr.777's Avatar
    Join Date
    Mar 2011
    Location
    Middle of NoWhere
    Posts
    320
    Depending upon the register/word size of your machine. Also, you can check the size by using sizeof() operator.
    I don't care if someone doesn't like me, i was not put on earth to entertain everyone.

    No King, no Queen, I am the ACE of battle.

Page 2 of 2 FirstFirst 12
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Memory issue
    By abraham2119 in forum C Programming
    Replies: 10
    Last Post: 08-18-2009, 11:24 PM
  2. sorting number
    By Leslie in forum C Programming
    Replies: 8
    Last Post: 05-20-2009, 05:23 AM
  3. Replies: 7
    Last Post: 02-06-2009, 12:27 PM
  4. Free Store of memory
    By George2 in forum C++ Programming
    Replies: 6
    Last Post: 11-12-2007, 02:27 PM
  5. True Errors in Memory and Storage
    By Procyon in forum A Brief History of Cprogramming.com
    Replies: 3
    Last Post: 02-07-2002, 07:31 AM

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