#1633 sdcc-20100226 exits with "convilong: Assertion `0' failed."

closed-duplicate
5
2014-08-23
2010-04-06
No

This doesn't happen with an older version of the compiler.

user@instant-contiki:~/sdcc_bug2$ ../sdcc-20100226/bin/sdcc main.c
sdcc: SDCCopt.c:707: convilong: Assertion `0' failed.
Caught signal 6: SIGABRT
user@instant-contiki:~/sdcc_bug2$ ../sdcc-20100226/bin/sdcc -v
SDCC : mcs51 2.9.7 #5718 (Feb 26 2010) (UNIX)
user@instant-contiki:~/sdcc_bug2$ more main.c
typedef unsigned short rtimer_clock_t;
struct timetable_timestamp {
const char *id;
rtimer_clock_t time;
#if TIMETABLE_WITH_TYPE
uint8_t type;
#endif /* TIMETABLE_WITH_TYPE */
};
struct timetable {
struct timetable_timestamp *timestamps;
const int size;
unsigned int * const ptr;
};
rtimer_clock_t
timetable_timediff(struct timetable *t,
const char *id1, const char *id2)
{
int i;
int t1, t2;

t1 = t2 = t->size;

for(i = *t->ptr - 1; i >= 0; --i) {
if(t->timestamps[i].id == id1) {
t1 = i;
return t->timestamps[i].time;
}
}
return 0;
}
void main (void)
{
struct timetable_timestamp ts[3];
struct timetable tt;
tt.timestamps = ts;
timetable_timediff(&tt,ts[0].id, ts[1].id);
}

Discussion

  • Anthony Asterisk

    Any help with this issue? Has it been fied? I provided a testcase.

     
  • Maarten Brock

    Maarten Brock - 2010-07-17

    This is identical to bug 2889032.

     
  • Maarten Brock

    Maarten Brock - 2010-07-17
    • labels: --> Icode generator
    • milestone: --> known_bugs
    • assigned_to: nobody --> maartenbrock
    • status: open --> closed-duplicate
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks