[lkml]   [2003]   [Apr]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
    SubjectRe: [PATCH] only use 48-bit lba when necessary
    Juan Quintela wrote:

    >Reason is that:
    >if (expr)
    > var = true;
    > var = false;
    >is always a bad construct.
    >var = expr;
    >is a better construct to express that meaning.

    Yes, but:

    if (expr1 && expr2)
    var = true;
    var = false;

    is usually better turned into something that avoids jumps
    when it's safe to evaluate both parts unconditionally:

    var = (expr1 != 0) & (expr2 != 0);

    or (if you can stand it):

    var = !!expr1 & !!expr2;

    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: 2005-03-22 13:34    [W:0.020 / U:52.416 seconds]
    ©2003-2017 Jasper Spaans. hosted at Digital OceanAdvertise on this site