lkml.org 
[lkml]   [2006]   [Oct]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [PATCH 1/4] LOG2: Implement a general integer log2 facility in the kernel [try #4]
    Date

    Jan Engelhardt <jengelh@linux01.gwdg.de> wrote:

    > Ouch ouch ouch. It should better be
    >
    > typedef uint32_t __u32;


    Actually, if you want to guarantee the size of an integer variable with gcc,
    you can do, for example, this:

    typedef int __attribute__((mode(SI))) siint;

    which creates a 32-bit signed integer type called "siint".

    The "mode" attribute is parameterised with one of the following values to
    indicate the specific size of integer required:

    QI 8-bit
    HI 16-bit
    SI 32-bit
    DI 64-bit
    TI 128-bit

    David
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2006-10-10 14:27    [W:0.019 / U:180.488 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site