[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug gold/15662] New: gold (powerpc) internal error in do_relax() at gol
From: |
jingyuuiuc at gmail dot com |
Subject: |
[Bug gold/15662] New: gold (powerpc) internal error in do_relax() at gold/output.h:436 |
Date: |
Fri, 21 Jun 2013 17:32:50 +0000 |
http://sourceware.org/bugzilla/show_bug.cgi?id=15662
Bug ID: 15662
Summary: gold (powerpc) internal error in do_relax() at
gold/output.h:436
Product: binutils
Version: unspecified
Status: NEW
Severity: normal
Priority: P2
Component: gold
Assignee: ian at airs dot com
Reporter: jingyuuiuc at gmail dot com
CC: ccoutant at google dot com
I found a few link time failures, reporting
internal error in set_current_data_size_for_child, at
/usr/local/home/jingyu/opensource/binutils_trunk/src/gold/output.h:436
I am using top of trunk gold.
I investigated the failure and found that the error happens when
set_current_data_size_for_child is called through
this->rel_->add_relative(elfcpp::R_POWERPC_RELATIVE, this, off, to);
through
Target_powerpc<size, big_endian>::do_relax().
I notice that the data size for the failing object has been changed a
few times during relaxation. Every time before it is updated,
this->is_data_size_valid_ will be set to false. And after data size is
updated, is_data_size_valid_ will be set to true. However, when the
data size is updated through add_relative, the flag
is_data_size_valid_ is not set to false beforehand, which triggers the
assertion failure. I think it is a bug.
To verify my thought, I made a patch on powerpc.cc, though I am not sure it is
the proper way to fix. With the patch, the failing tests pass linking.
Index: powerpc.cc
===================================================================
RCS file: /cvs/src/src/gold/powerpc.cc,v
retrieving revision 1.91
diff -r1.91 powerpc.cc
2631a2632
> this->brlt_section_->reset_rel_data_size();
2638a2640
> this->brlt_section_->finalize_rel_data_size();
3015a3018,3029
> void
> reset_rel_data_size()
> {
> this->rel_->reset_data_size();
> }
>
> void
> finalize_rel_data_size()
> {
> this->rel_->finalize_data_size();
> }
>
Is the patch the proper way to fix the bug? Thanks!
--
You are receiving this mail because:
You are on the CC list for the bug.
- [Bug gold/15662] New: gold (powerpc) internal error in do_relax() at gold/output.h:436,
jingyuuiuc at gmail dot com <=