[lkml]   [2007]   [Jan]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: kernel + gcc 4.1 = several problems
    >>> (in which case, nearly all real-world code is broken)
    >> Not "nearly all" -- but lots of code, yes.
    > I wouldn't say "lots of code". I would say "all real projects".

    All projects that tell the compiler they're written in ISO C,
    while they're not, can easily break, sure. You can't say this
    is GCC's fault; sure in some cases decisions were made that
    resulted in more of those programs breaking than was really
    necessary, but it's obviously *impossible* to prevent all
    from breaking.

    And yes it's true: most people do not program in ISO C at all,
    _even if they think they do_, simply because they are not aware
    of all the rules. For some of the areas where most of the
    mistakes are made, for example aliasing rules and signed overflow,
    GCC provides helpful options to switch behaviour to something
    that makes those people's programs work. You can also use those
    options if you have made a conscious decision that you want to
    write your code in one of the resulting dialects of C.


    p.s. If it's decided to not use -fwrapv, a debug option that
    sets -ftrapv can be introduced -- it will make it a BUG() if
    any (accidental) signed overflow happens after all.

    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to
    More majordomo info at
    Please read the FAQ at

     \ /
      Last update: 2007-01-04 20:01    [W:0.027 / U:22.232 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site