[go: up one dir, main page]

Menu

#5 Judy1 bug with gcc 4.9 O1/O2

Judy-1.0.0
open
nobody
None
5
2014-12-27
2014-07-23
No

Judy1 fails if compiled with latest gcc 4.9.


for (i=1;i<50000000;i++) {
J1S(Rc_int, J1Array, Index); // set bit at 123456
if (Rc_int == JERR) printf("ERR - malloc\n");
if (Rc_int == 0) printf("BUG - bit already set at %lu\n", Index);
}


BUG - bit already set at 16777352
BUG - bit already set at 33554568


With O0, it works (stupid patch attached).

Regards,

Guillaume

1 Attachments

Related

Patches: #5

Discussion

  • Douglas L. Baskins

    Guillaume:

    The enclosed patched JudyPrivateBranch.h file will allow GCC to compile Judy with all options. (-O2 preferred).

    Doug -- author of Judy

    Doug Baskins dougbaskins@yahoo.com

    On Wednesday, July 23, 2014 12:14 PM, Guillaume Fougnies guillaume_f@users.sf.net wrote:


    [patches:#5] Judy1 bug with gcc 4.9 O1/O2
    Status: open
    Group: Judy-1.0.0
    Created: Wed Jul 23, 2014 06:14 PM UTC by Guillaume Fougnies
    Last Updated: Wed Jul 23, 2014 06:14 PM UTC
    Owner: nobody
    Judy1 fails if compiled with latest gcc 4.9.


    for (i=1;i<50000000;i++) {
    J1S(Rc_int, J1Array, Index); // set bit at 123456
    if (Rc_int == JERR) printf("ERR - malloc\n");
    if (Rc_int == 0) printf("BUG - bit already set at %lu\n", Index);
    }


    BUG - bit already set at 16777352
    BUG - bit already set at 33554568


    With O0, it works (stupid patch attached).
    Regards,
    Guillaume


    Sent from sourceforge.net because you indicated interest in https://sourceforge.net/p/judy/patches/5/
    To unsubscribe from further messages, please visit https://sourceforge.net/auth/subscriptions/

     

    Related

    Patches: #5

  • Guillaume Fougnies

    Hello Doug,

    The patch works nicely.
    Thanks a lot. Judy array is amazing.

    Regards,
    Guillaume

     

Log in to post a comment.