diff options
author | Jan Hubicka <jh@suse.cz> | 2010-05-20 16:57:27 +0200 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2010-05-20 14:57:27 +0000 |
commit | a14f187843d81107e4100e6934c59480d2a26007 (patch) | |
tree | d2568f6b58e3ac9afbc0611694d00ca312fccdf0 /gcc | |
parent | ab6bfd90cb6aac5628a32d063de4ae33a8828ae1 (diff) | |
download | gcc-a14f187843d81107e4100e6934c59480d2a26007.zip gcc-a14f187843d81107e4100e6934c59480d2a26007.tar.gz gcc-a14f187843d81107e4100e6934c59480d2a26007.tar.bz2 |
re PR middle-end/44197 ([4.6 Regresssion] varpool SEGV)
PR middle-end/44197
* varpool.c (varpool_remove_node): Handle in-varpool aliases.
* gcc.c-torture/compile/pr44197.c: New file.
From-SVN: r159629
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/testsuite/gcc.c-torture/compile/pr44197.c | 22 | ||||
-rw-r--r-- | gcc/varpool.c | 2 |
4 files changed, 33 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 972f604..5f96aa7 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2010-05-20 Jan Hubicka <jh@suse.cz> + + PR middle-end/44197 + * varpool.c (varpool_remove_node): Handle in-varpool aliases. + 2010-05-20 Kenneth Zadeck <zadeck@naturalbridge.com> PR bootstrap/43870 diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index e5412e8..7272fe5 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2010-05-20 Jan Hubicka <jh@suse.cz> + + PR middle-end/44197 + * gcc.c-torture/compile/pr44197.c: New file. + 2010-05-20 Uros Bizjak <ubizjak@gmail.com> * gcc.target/i386/i386.exp (check_effective_target_3dnow): diff --git a/gcc/testsuite/gcc.c-torture/compile/pr44197.c b/gcc/testsuite/gcc.c-torture/compile/pr44197.c new file mode 100644 index 0000000..9a97d77 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr44197.c @@ -0,0 +1,22 @@ +typedef unsigned short int __uint16_t; +enum +{ + _ISupper = (1 << (0)), _ISlower = (1 << (1)), _ISalpha = + (1 << (2)), _ISdigit = (1 << (3)), _ISxdigit = (1 << (4)), _ISspace = + (1 << (5)), _ISprint = (1 << (6)), _ISgraph = (1 << (7)), _ISblank = + (1 << (8)), _IScntrl = (1 << (9)), _ISpunct = (1 << (10)), _ISalnum = + (1 << (11)) +}; +typedef __uint16_t __ctype_mask_t; +extern const __ctype_mask_t *__C_ctype_b; +extern +__typeof (__C_ctype_b) + __C_ctype_b __asm__ ("" "__GI___C_ctype_b") + __attribute__ ((visibility ("hidden"))); + static const __ctype_mask_t __C_ctype_b_data[] = { + }; + +const __ctype_mask_t *__C_ctype_b = __C_ctype_b_data + 128; +extern +__typeof (__C_ctype_b) + __EI___C_ctype_b __attribute__ ((alias ("" "__GI___C_ctype_b"))); diff --git a/gcc/varpool.c b/gcc/varpool.c index c713a77..7185c85 100644 --- a/gcc/varpool.c +++ b/gcc/varpool.c @@ -167,7 +167,7 @@ varpool_remove_node (struct varpool_node *node) node->prev->next = node->next; else { - if (node->alias) + if (node->alias && node->extra_name) { gcc_assert (node->extra_name->extra_name == node); node->extra_name->extra_name = node->next; |