Skip to content

[llvm-gcc] Crash on structure with variable length array member #571

@llvmbot

Description

@llvmbot
Bugzilla Link 199
Resolution FIXED
Resolved on Feb 22, 2010 12:54
Version 1.1
OS All
Depends On #534
Attachments Preprocessed C code that reproduces the problem., Reduced test case, Proposed fix
Reporter LLVM Bugzilla Contributor
CC @lattner

Extended Description

The llvm-gcc program crashes when it tries to compile the attached pre-processed
code. It occurs because we have an FIELD_DECL tree whose DECL_SIZE returns a
NULL_TREE. We deference this NULL_TREE with TREE_INT_CST_LOW, causing the error:

C-ctype.c:685: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See URL:http://llvm.cs.uiuc.edu for instructions.

The source file comes from glibc.

I'm assigning it to myself for now since I've figured what is causing it, have
devised a hack to work around it, and am now looking at how to fix it correctly.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions