I've looked at this some, but I'm not having any luck fixing it. sgiCC
generates unnecessary definitions of __FUNCTION__ and
__PRETTY_FUNCTION__. An example that shows this behavior is attached.
WFE_Initialize_Decl claims it ignores unnecessary declarations by checking
DECL_IGNORED_P, but that doesn't seem to work.
> cat hello.cc
#include <stdio.h>
int
main ()
{
printf("Hello World\n");
}
> sgiCC -v
SGIcc Compilers: Version 0.01.0-12
> sgiCC -O2 hello.cc -S
> cat hello.s
// /usr/lib/gcc-lib/ia64-sgi-linux/sgicc-1.0/be::0.01.0-12
//-----------------------------------------------------------
// Compiling hello.cc (/tmp/ccI.XOud7p)
//-----------------------------------------------------------
//-----------------------------------------------------------
// Options:
//-----------------------------------------------------------
// Target:Itanium, ISA:ISA_1, Pointer Size:64
// -O2 (Optimization level)
// -g0 (Debug level)
// -m1 (Report warnings)
//-----------------------------------------------------------
.section .text, "ax", "progbits"
.align 16
.section .rodata, "a", "progbits"
.align 8
.section .sbss, "wa", "nobits"
.align 1
.section .bss, "wa", "nobits"
.align 1
.section .sbss
.org 0x0
.align 0
.type __func___82, @object
.size __func___82, 1
__func___82: // 0x0
.skip 1
.org 0x1
.align 0
.type __FUNCTION___84, @object
.size __FUNCTION___84, 1
__FUNCTION___84: // 0x1
.skip 1
.section .bss
.org 0x0
.align 0
.type __PRETTY_FUNCTION___83, @object
.size __PRETTY_FUNCTION___83, 10
__PRETTY_FUNCTION___83: // 0x0
.skip 10
.section .text
// Program Unit: main
.proc main#
.global main#
main#: // 0x0
.file 1 "/usr/local/home/goodwin/hello.cc"
.loc 1 5 0
// 1 #include <stdio.h>
// 2
// 3 int
// 4 main ()
// 5 {
.BB1_main: // 0x0
//<freq>
...
|