This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
On 09/08/2012 13:26, Göran Steen wrote:
I use gcc version 4.3.4, where int is 32-bit variables. Is it possible to setup compiler to compile int as 16-bit variables?
The size of an int depends on the target - gcc supports dozens of targets. Most have 32-bit ints, but some have 16-bit ints and at least one has a compile-time option to support 8-bit ints (though that goes against C standards, and is deprecated on current builds). There are probably also targets with 64-bit ints.
You mean the avr port? int is 16 bits wide and -mint8 implements the non-standard 8-bit int. That option was broken for quite some time, see PR46261. But that PR is fixed now.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |