libfirm / cparser

C99 parser and frontend for libfirm
http://pp.ipd.kit.edu/firm
GNU General Public License v2.0
336 stars 38 forks source link

cparser aborts on packed bitfields #30

Open GabrielRavier opened 4 years ago

GabrielRavier commented 4 years ago
struct s
{
    unsigned front;
    unsigned a : 8;
    unsigned b : 1;
} __attribute__((packed));

void f(struct s x)
{
    x.a && x.b;
}

This code aborts with :

Edge Verifier: Block BB[60:2] reachable by 22 node(s), but the list contains 23 edge(s)
Edge Verifier: Proj T[65:3] reachable by 2 node(s), but the list contains 3 edge(s)
Verify warning: Proj Lu[185:26](f[62]): IR_GRAPH_PROPERTY_CONSISTENT_OUT_EDGES set, but node cannot be found with normal edges
Aborted (core dumped)