Bit meaning for a compiler.

C

CoDE++

what does 32 bit or 16 bit means when it is referred in terms of a
compiler? For example what does 2 bit stand for when we state a
complier as 32 bit.
 
F

Francesco S. Carta

what does 32 bit or 16 bit means when it is referred in terms of a
compiler? For example what does 2 bit stand for when we state a
complier as 32 bit.

Bits are bits, always and regardless of anything else: just one or zero.

The thing that changes is the concept of byte. Ideally a set of 8 bits,
but better called an octet for precision, as a byte can very well have
other values (16 and 32, for example).

Look up "define:byte" and "define:bit" on google, exactly as they are
(no spaces around the colon but exclude the double quotes).

If you want to know how many bits a "C++ byte" is, to the eyes of your
compiler, print out the value of CHAR_BIT from <climits>.
 
G

Gennaro Prota

Bits are bits, always and regardless of anything else: just one or zero.

The thing that changes is the concept of byte. Ideally a set of 8 bits,
but better called an octet for precision, as a byte can very well have
other values (16 and 32, for example).

Look up "define:byte" and "define:bit" on google, exactly as they are
(no spaces around the colon but exclude the double quotes).

If you want to know how many bits a "C++ byte" is, to the eyes of your
compiler, print out the value of CHAR_BIT from <climits>.

I think he wanted to know what it means to say e.g. "this is a
32-bit compiler". Pretty much off-topic, here. And I'm sure that
with a little effort he can easily find the answer on the web.
 
G

Geoff

what does 32 bit or 16 bit means when it is referred in terms of a
compiler? For example what does 2 bit stand for when we state a
complier as 32 bit.

The number of bits in a compiler refers to the basic number of bits
that can be manipulated as a unit on the target machine (processor). A
32-bit machine has a word size of 32 bits and presumably a bus width
of that many bits. A 64-bit machine has twice that width. Compilers
can be native or cross-platform, for example, a compiler might be
capable of running on an x86 machine but targeting another processor
like the M68000 (16-bit) or Z180 (8-bit) processors.

It is also possible to run a 64-bit OS and a 64-bit version of a
compiler and create 32-bit or even 16 or 8 bit executables.

Apple's Xcode can produce "Universal" binaries that can run on their
32-bit Intel machines and also on the PPC machines which had 32 and 64
bit modes.
 
F

Francesco S. Carta

I think he wanted to know what it means to say e.g. "this is a
32-bit compiler". Pretty much off-topic, here. And I'm sure that
with a little effort he can easily find the answer on the web.

I know, I just wanted to fill the lower gap evidently contained in the
higher question :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,050
Latest member
AngelS122

Latest Threads

Top