Path: csiph.com!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: Preprocessor Overheads Date: Fri, 03 Feb 2017 13:39:03 -0800 Organization: None to speak of Lines: 32 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: mx02.eternal-september.org; posting-host="abc513047bd7eb6502f52aab060309cd"; logging-data="9903"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+XOI582MKDryTUV6nV9KBK" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) Cancel-Lock: sha1:uF8k2nWUTtMkUhzpt5fWeTHZvSQ= sha1:RSC3lwwrZM2C6vP3lu6oqxJ5mX0= Xref: csiph.com comp.lang.c:103086 antispam@math.uni.wroc.pl writes: > BartC wrote: >> >> In that case I might as well just use long long instead of int64_t. I >> think long long will be 64 bits on all the targets I'm interested in. > > Old gcc manuals said that 'long long' is type of size twice the > native machine word. Alpha was 64 bit machine, so on Alpha > that would give 128 bits. When Alpha users complained that > on Alpha 'long long' is only 64-bit instead of fixing > compiler (implementing 128 bit type) gcc folks changed the > manual. But this does not change the fact than on 64 > bit machine natural size for 'long long' would be 128 bits. Do you have a basis for that other than "old gcc manuals"? The oldest one I can find (2.8.1) says that long long is "twice as long as int". int is typically 32 bits even on 64-bit systems. [...] The standard requires long long to be at least 64 bits. It certainly *can* be 128 bits, or even more, but I know of no implementations that make it anything other than exactly 64 bits. (gcc's 128-bit integers are provided as an extension; they're not even treated as "extended integer types" in the sense described in the standard.) -- Keith Thompson (The_Other_Keith) kst-u@mib.org Working, but not speaking, for JetHead Development, Inc. "We must do something. This is something. Therefore, we must do this." -- Antony Jay and Jonathan Lynn, "Yes Minister"