egcs-19990824: g++ -g -O generating bad assembly on x86 linux glibc-2.1.1
Adam J. Richter
adam@yggdrasil.com
Tue Aug 31 21:57:00 GMT 1999
The latest snapshot (egcs-19990824) no longer generates an
internal compiler error in the example that I submitted previously.
In fact, it compiles that example without complaint. However, it
still fails to compile the file from which I made that example.
Now it causes gas-2.95 (using bfd 2.9.5.0.8) to complain with the
following error messages:
/tmp/ccKnAoYo.s: Assembler messages:
/tmp/ccKnAoYo.s:166: Error: Subtraction of two symbols in different sections ".LBB5" {*UND* section} - "updateDrawingObjects__7QWidget" {.text section} at file address 644.
/tmp/ccKnAoYo.s:167: Error: Subtraction of two symbols in different sections ".LBE5" {*UND* section} - "updateDrawingObjects__7QWidget" {.text section} at file address 656.
I have attached the smallest example that I could create of
code that generates the error. Note that this error only occurs if
g++ is run with *both* -O and -g.
Adam J. Richter __ ______________ 4880 Stevens Creek Blvd, Suite 104
adam@yggdrasil.com \ / San Jose, California 95129-1034
+1 408 261-6630 | g g d r a s i l United States of America
fax +1 408 261-6631 "Free Software For The Rest Of Us."
template <class Style, class Base>
class theme_map {
};
class QWidget {
protected:
virtual void *harmony_get_list_for_signal(const char *) const;
public:
static theme_map<int, QWidget> ContentsThemes;
protected:
virtual void updateDrawingObjects (void)
{
update_dro (QWidget::ContentsThemes);
}
/**
* Contents Drawing Object
*/
template <class S, class B>
void update_dro (theme_map<S, B>& themes)
{
}
};
void *QWidget::harmony_get_list_for_signal(const char *sig) const
{
return 0;
}
More information about the Gcc-bugs
mailing list