Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
I'm trying to get a memory map from grub, and there you have two addresses (base_low and base_high) and both are unsigned long. When trying to combine these two, I get the following compiler exception:
unsigned long long ll = ((unsigned long long)mmap->base_addr_high) << 32) ^ mmap->base_addr_low)
Notice the typecast to long long before the shift, just to make absolutely sure the compiler knows what we want (I'm usually more pedantic than the compiler).
64bit values are the largest that GCC supports natively, I think. They're certainly the largest required by the C standard (#include <stdint.h> and use the types int64_t and uint64_t if you can).
On the x86, you'll have problems with integers greater than 64bits since you get 4 core registers of 32bits each. A 128bit value would use all 4 registers (eax-edx). Larger size integers are usually supported by a 'big int' or 'big num' software library, for situations like cryptography where 1024bit (or more) arithmatic is needed.
I don't think the phrase 'int char' will work but I've never tried it. If 'int char' works, I'd assume 'long int char' works.
Lastly, anything ending 'long' or 'short' implicitly has 'int' on the end. 'long' is really just an alias for 'long int', etc.