GCC problems

I am having 2 problems with gcc on qnx (the latest release of qnx, but
gcc -v says 2.95.2).

The first is minor since I have a workaround, but I’ll list it anyway. I
can do 64 bit operations with unsigned long long, but I can’t declare a
constant over 0xffffffff. Is there a compiler patch or command line option
I can use to get around this?

The second is that the compiler dies on some of my code (that compiles on
other platforms). Typically it is code that uses STL stuff, like a map.
The error I get is:

/usr/include/g+±3/stl_map.h:76: Internal compiler error in
`dwarfout_finish’, at dwarfout.c:6102

Any ideas here?

Don’t know about the c++ stuff but did you try something like:

unsigned long long poo = 0xffffffffffLL;
printf(“poo: %lld\n”, poo);

That works for me.

Kris

Chris Elliott <Chris.P.Elliott@ieee.org> wrote:

I am having 2 problems with gcc on qnx (the latest release of qnx, but
gcc -v says 2.95.2).

The first is minor since I have a workaround, but I’ll list it anyway. I
can do 64 bit operations with unsigned long long, but I can’t declare a
constant over 0xffffffff. Is there a compiler patch or command line option
I can use to get around this?

The second is that the compiler dies on some of my code (that compiles on
other platforms). Typically it is code that uses STL stuff, like a map.
The error I get is:

/usr/include/g+±3/stl_map.h:76: Internal compiler error in
`dwarfout_finish’, at dwarfout.c:6102

Any ideas here?


Kris Warkentin
kewarken@qnx.com
(613)591-0836 x9368
“You’re bound to be unhappy if you optimize everything” - Donald Knuth

Actually, regarding the C++, are you using optimization? There are a couple
optimization bugs that cause gcc to choke but will compile fine if you turn
it off for that particular file. An example is DDD in which one file needs
to be specially compiled but other than that works fine.

cheers,

Kris

Kris Eric Warkentin <kewarken@qnx.com> wrote:

Don’t know about the c++ stuff but did you try something like:

unsigned long long poo = 0xffffffffffLL;
printf(“poo: %lld\n”, poo);

That works for me.

Kris

Chris Elliott <> Chris.P.Elliott@ieee.org> > wrote:
I am having 2 problems with gcc on qnx (the latest release of qnx, but
gcc -v says 2.95.2).

The first is minor since I have a workaround, but I’ll list it anyway. I
can do 64 bit operations with unsigned long long, but I can’t declare a
constant over 0xffffffff. Is there a compiler patch or command line option
I can use to get around this?

The second is that the compiler dies on some of my code (that compiles on
other platforms). Typically it is code that uses STL stuff, like a map.
The error I get is:

/usr/include/g+±3/stl_map.h:76: Internal compiler error in
`dwarfout_finish’, at dwarfout.c:6102

Any ideas here?


Kris Warkentin
kewarken@qnx.com
(613)591-0836 x9368
“You’re bound to be unhappy if you optimize everything” - Donald Knuth


Kris Warkentin
kewarken@qnx.com
(613)591-0836 x9368
“You’re bound to be unhappy if you optimize everything” - Donald Knuth

Don’t know about the first one, but the second you can fix by the option
-Wc,-gstabs
Don’t even exactly know what this switch does, I just did a web search for
“dwarfout_finish” and got that answer. Works perfect so far for me.
Markus

“Chris Elliott” <Chris.P.Elliott@ieee.org> wrote in message
news:9du2mk$cfg$1@inn.qnx.com

I am having 2 problems with gcc on qnx (the latest release of qnx, but
gcc -v says 2.95.2).

The first is minor since I have a workaround, but I’ll list it anyway. I
can do 64 bit operations with unsigned long long, but I can’t declare a
constant over 0xffffffff. Is there a compiler patch or command line
option
I can use to get around this?

The second is that the compiler dies on some of my code (that compiles on
other platforms). Typically it is code that uses STL stuff, like a map.
The error I get is:

/usr/include/g+±3/stl_map.h:76: Internal compiler error in
`dwarfout_finish’, at dwarfout.c:6102

Any ideas here?

There is a bug in the dwarf1 debug generation. Setting -gstabs (you
don’t need -Wc,) tells the compiler to use stabs debugging information,
which is what linux uses btw.

BTW - what version of QNX are you using? I thought I had this
one licked. :frowning:

Markus Loffler <loffler@ces.clemson.edu> wrote:

Don’t know about the first one, but the second you can fix by the option
-Wc,-gstabs
Don’t even exactly know what this switch does, I just did a web search for
“dwarfout_finish” and got that answer. Works perfect so far for me.
Markus

“Chris Elliott” <> Chris.P.Elliott@ieee.org> > wrote in message
news:9du2mk$cfg$> 1@inn.qnx.com> …
I am having 2 problems with gcc on qnx (the latest release of qnx, but
gcc -v says 2.95.2).

The first is minor since I have a workaround, but I’ll list it anyway. I
can do 64 bit operations with unsigned long long, but I can’t declare a
constant over 0xffffffff. Is there a compiler patch or command line
option
I can use to get around this?

The second is that the compiler dies on some of my code (that compiles on
other platforms). Typically it is code that uses STL stuff, like a map.
The error I get is:

/usr/include/g+±3/stl_map.h:76: Internal compiler error in
`dwarfout_finish’, at dwarfout.c:6102

Any ideas here?


cburgess@qnx.com

Thanks for the gstabs suggestion. I will try that. I am using the latest
QNX with the latest compiler patches. In case it is useful, at the end of
this post is a program that will fail if compiled with “QCC -c -g test.cpp”,
but will work with “QCC -c test.cpp”

“Colin Burgess” <cburgess@qnx.com> wrote in message
news:9dur6j$ndq$2@nntp.qnx.com

BTW - what version of QNX are you using? I thought I had this
one licked. > :frowning:

#include “map”

class Class1
{
private:
typedef std::multimap<unsigned long, unsigned long> myMmap;
typedef myMmap::iterator myMmapItr;

typedef std::map<unsigned long, myMmapItr> myMap;

myMap m_Item;

public:
unsigned long NextP()
{
unsigned long DevP = 0;
return DevP;
}
};

class Class2
{
private:
Class1 m_DevQ;
public:
~Class2() {}
};