Re: Integral type with sizeof(T) == 1 and distinct aliasing class

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, May 25, 2012 at 3:01 PM, Florian Weimer <fw@xxxxxxxxxxxxx> wrote:
> * Ian Lance Taylor:
>
>> Florian Weimer <fw@xxxxxxxxxxxxx> writes:
>>
>>> Is there a type which is basically an (unsigned) char, but with the
>>> additional feature that a pointer derived from it wouldn't alias with
>>> basically anything?
>>>
>>> This type would be handy for optimizing marshaling code.
>>
>> There is no such type.  However, use of the restrict qualifier should
>> achieve a similar effect.
>
> It turns out that I can't get GCC to eliminate redundant bounds
> checks, no matter what the type is.  I guess I have to do this in a
> library after all, using template metaprogramming.

is it possible to use one of those GCC type mode extensions to
typedef int with mode saying it has 8-bit and use that?

-- Gaby



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux