Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
* Profiling under Linux Alpha ?
@ 1997-11-18 22:00 Miguel A Sepulveda
  0 siblings, 0 replies; 5+ messages in thread
From: Miguel A Sepulveda @ 1997-11-18 22:00 UTC (permalink / raw)


Hi Everyone,

I am trying to profile and program of mine under my Alpha platform
Kenerl 2.0.30.

I compiled the sources with -g2 -pg, then run the executable. After the
executable finishes it is suppose to generate a gmon.out, instead the
program crash and dump a core. The program is fine because without
the -pg option it works just fine.

Next I compile the sources with -g2 -p, to get a plain profile output.
In this casae it did work. It generated a gmon.out. However, gprof
does not understand the format of this gmon.out. I need a system utility
prof based ona kernel call, which as I undertand is not supported yet.

Has anyone any idea how to go profile a program on Alpha Linux???

By the way my sources are in C++ (I assumed that if C profiling is
supported so is C++, Am I wrong?)

Thanks,

----------------------------------------------------------------------
Miguel Angel Sepulveda

University of Pittsburgh
Space Research Coordination Center, Room 207
Pittsburgh  PA 15260 (USA)

email:   sepulved+@pitt.edu                  phone: (412)6241184
www  :   http://www.pitt.edu/~sepulved
ftp  :   soon to come.....
----------------------------------------------------------------------

-- 
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Profiling under Linux Alpha ?
       [not found] <Pine.GSO.3.96L.971118165438.12429A-100000@unixs1.cis.pitt.edu>
@ 1997-11-18 22:55 ` Hugo van der Kooij
  1997-11-19  2:18 ` Andreas Johansson
  1 sibling, 0 replies; 5+ messages in thread
From: Hugo van der Kooij @ 1997-11-18 22:55 UTC (permalink / raw)


On Tue, 18 Nov 1997, Miguel A Sepulveda wrote:

> By the way my sources are in C++ (I assumed that if C profiling is
> supported so is C++, Am I wrong?)

Having seen the C++ vs C discussions with GCC I tend to say you may be
less fortunate.

Hugo.

	+------------------------+------------------------------+
	| Hugo van der Kooij     | Hugo.van.der.Kooij@caiw.nl   |
	| Oranje Nassaustraat 16 | http://www.caiw.nl/~hvdkooij |
	| 3155 VJ  Maasland      | (De man met de rode hoed)    |
	+------------------------+------------------------------+
			Werkt u al met Linux?
	(U rijdt toch ook niet meer met stepwieltjes aan uw fiets?)

-- 
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Profiling under Linux Alpha ?
       [not found] <Pine.GSO.3.96L.971118165438.12429A-100000@unixs1.cis.pitt.edu>
  1997-11-18 22:55 ` Hugo van der Kooij
@ 1997-11-19  2:18 ` Andreas Johansson
  1 sibling, 0 replies; 5+ messages in thread
From: Andreas Johansson @ 1997-11-19  2:18 UTC (permalink / raw)


On Tue, 18 Nov 1997, Miguel A Sepulveda wrote:

> 
> Hi Everyone,
> 
> I am trying to profile and program of mine under my Alpha platform
> Kenerl 2.0.30.
> 
> I compiled the sources with -g2 -pg, then run the executable. After the
> executable finishes it is suppose to generate a gmon.out, instead the
> program crash and dump a core. The program is fine because without
> the -pg option it works just fine.

You're not by coincidence linking in the math library?
In that case I think you should try linking your program static.

I have had problems with profiling as well. At some point no profiling was
working at all. Right now I'm using RedHat's mustang distribution (beta),
and it seems that profiling works as long as you don't make the file
dynamic AND link in the math library:

ajo@wopr ~/tmp2 >cat >test.cc
main()
{
  printf ("Test\n");
}
ajo@wopr ~/tmp2 >gcc -pg -o test test.cc
test.cc: In function `int main()':
test.cc:3: warning: implicit declaration of function `int printf(...)'
ajo@wopr ~/tmp2 >./test
Test
ajo@wopr ~/tmp2 >gcc -pg -o test test.cc -lm
test.cc: In function `int main()':
test.cc:3: warning: implicit declaration of function `int printf(...)'
ajo@wopr ~/tmp2 >./test
Segmentation fault (core dumped)
ajo@wopr ~/tmp2 >gcc -pg -o test test.cc -lm -static
test.cc: In function `int main()':
test.cc:3: warning: implicit declaration of function `int printf(...)'
ajo@wopr ~/tmp2 >./test
Test
ajo@wopr ~/tmp2 >

I can 'gprof test' after this too.

/Andreas

--

<-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=->
: E-mail: ajo@wopr.campus.luth.se                                       :
: S-mail: Andreas Johansson, Karhusvagen 5  6:618, 977 54 Lulea, SWEDEN :
:     Have you had your dose of 261.62 BogoMIPS today? - Run Alpha!     :
<-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=->

-- 
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Profiling under Linux Alpha ?
       [not found] <Pine.LNX.3.96.971118235506.31837C-100000@hvdkooij.caiw.nl>
@ 1997-11-19  3:28 ` Jason Shiffer
  0 siblings, 0 replies; 5+ messages in thread
From: Jason Shiffer @ 1997-11-19  3:28 UTC (permalink / raw)


On Tue, 18 Nov 1997, Hugo van der Kooij wrote:

:On Tue, 18 Nov 1997, Miguel A Sepulveda wrote:
:
:> By the way my sources are in C++ (I assumed that if C profiling is
:> supported so is C++, Am I wrong?)
:
:Having seen the C++ vs C discussions with GCC I tend to say you may be
:less fortunate.
:

I however have had the same problems in C.

Jason Shiffer

-- 
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Profiling under Linux Alpha ?
@ 1997-11-19  9:16 Stefan Schroepfer
  0 siblings, 0 replies; 5+ messages in thread
From: Stefan Schroepfer @ 1997-11-19  9:16 UTC (permalink / raw)


Miguel A Sepulveda wrote:
> 
> Hi Everyone,
> 
> [...]
> 
> Has anyone any idea how to go profile a program on Alpha Linux???
> 
> By the way my sources are in C++ (I assumed that if C profiling is
> supported so is C++, Am I wrong?)
> 

For RedHat 4.1, I needed to apply two patches posted by David
Mosberger-Tang to this list:

http://www.redhat.com/support/mailing-lists/archives/axp-list/1997-March/0463.html
fix for gprof,

http://www.redhat.com/support/mailing-lists/archives/axp-list/1997-March/0464.html
fix for three object files in libc_p.a.

Someone from the list told me that these are applicable to
RedHat 4.2, too (hope this is of any help for you).

I never had problems with the math library.
C++ is no problem.
I always use static linking for profiling.

Good luck,
Stefan Schroepfer,
scr@iis.fhg.de

P.S.:
Will RedHat 5.0 be 'profile-safe' on the Alpha?

-- 
To unsubscribe: send e-mail to axp-list-request@redhat.com with
'unsubscribe' as the subject.  Do not send it to axp-list@redhat.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1997-11-19  9:16 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <Pine.LNX.3.96.971118235506.31837C-100000@hvdkooij.caiw.nl>
1997-11-19  3:28 ` Profiling under Linux Alpha ? Jason Shiffer
1997-11-19  9:16 Stefan Schroepfer
     [not found] <Pine.GSO.3.96L.971118165438.12429A-100000@unixs1.cis.pitt.edu>
1997-11-18 22:55 ` Hugo van der Kooij
1997-11-19  2:18 ` Andreas Johansson
  -- strict thread matches above, loose matches on Subject: below --
1997-11-18 22:00 Miguel A Sepulveda

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox