473,769 Members | 5,072 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

gcc compiling for profiler question

Hi

I'm trying to create a gmon.out file with gcc so I can run my program
through gmon. However the -pg option doesn't seem to work. Is there a
trick to generating this file?

Thanks for any help

B2003
Jan 30 '08 #1
3 1593
On 30 Jan, 09:30, Boltar <boltar2...@yah oo.co.ukwrote:
Hi

I'm trying to create a gmon.out file with gcc so I can run my program
through gmon. However the -pg option doesn't seem to work. Is there a
trick to generating this file?
I meant gprof , not gmon.

B2003

Jan 30 '08 #2
You must run the program once before the output is generated.
Same as gcov.
Jan 30 '08 #3
Boltar wrote:
>
I'm trying to create a gmon.out file with gcc so I can run my
program through gmon. However the -pg option doesn't seem to work.
Is there a trick to generating this file?
Look up gprof (either "man gprof" or "info gprof" or both). This
is off-topic on c.l.c.

--
[mail]: Chuck F (cbfalconer at maineline dot net)
[page]: <http://cbfalconer.home .att.net>
Try the download section.

--
Posted via a free Usenet account from http://www.teranews.com

Jan 31 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
2075
by: aurora | last post by:
I have a parser I need to optimize. It has some disk IO and a lot of looping over characters. I used the hotspot profiler to gain insight on optimization options. The methods show up on on the top of this list seems fairly trivial and does not look like CPU hogger. Nevertheless I optimized it and have 25% performance gain according to hotspot's number. But the numbers look skeptical. Hotspot claim 71.166 CPU seconds but the actual...
1
1127
by: Mac | last post by:
I'm writing a bunch of algorithms in Python for solving a certain class of problems, and I was interested in doing some comparisons between them and would like to collect various high-level runtime stats, such as the number of invocations of certain key subroutines. I have my own code to do this. Then just earlier today it hit me that I'm really just profiling, albeit in a more restricted way than the "profile" module. This got me...
3
1561
by: jw56578 | last post by:
Where is the information coming from that is displayed in query profiler. Is it the command that is retrieved before it is processed, or is it what is actually processed.
3
1326
by: Phil | last post by:
I'm currently running Profiler sessions to track down Lock Timeout problems. My Profiler view contains (amongst others) the dbid column. Much of the time, this displays familiar dbids, such as 2 (tempdb) and 5 (my main user db). However, it also regularly displays IDs of 0 and 132. Using SELECT DB_NAME(), these translate as "master" and "NULL"
9
3279
by: Franco Gustavo | last post by:
Hi, All What's is the best .net profiler for Debug an application. I have to buy one but I don't know which one!! I tried some of them like Borland and AQTime. My big problem is, my application is a big application, and many times I have many EventHandlers associated to an object, then this object never is free from the memory. AQTime for .Net can tell me how many references of EventHandler the object
1
1143
by: Bhargavan | last post by:
Hi, I am running a .Net windows application. When I check the memory usuage of that application in the windows task manager, it shows around 66MB. But when I check the memory usuage using .NET memory profiler (a third party tool) it shows only 4MB. Anybody have any idea why there is such a high discrepency? Thanks, Bhargavan
8
2149
by: Bryan | last post by:
Does anyone have an example of an application that can connect to a running process and capture Trace.WriteLine calls like in SQL Server Profiler? I know that we can inherit from a TraceListener class to write to files, databases, etc..., but I would really like to attach to running .NET processes and get the results without any logging and instead capture the real-time results when troubleshooting.
3
3684
by: Sam Samson | last post by:
Can any-one recommend some good sites detailing how to code a simple memory profiler? How do they "look under the hood"? I built an uber simple service that tracks the process' memory but I need to "get inside" and look a bit deeper and I don't have a clue where to start ... a commercial memory profiler is not an option due the nature of the environment the application is deployed in .. My app runs fine for weeks (in 8 locations) but...
0
5056
by: anweshadash | last post by:
Using SQL Profiler: (Ref: http://msdn2.microsoft.com/en-us/library/ms181091.aspx) Sometimes it’s very beneficial to use sql profiler. Let’s have an idea about that and how to use that by taking some scenarios. Microsoft SQL Server Profiler is a graphical user interface to SQL Trace for monitoring an instance of the SQL Server Database Engine or Analysis Services. You can capture and save data about each event to a file or table to...
1
1779
by: =?Utf-8?B?Um9oaXQ=?= | last post by:
I am using the CLR Profiler to investigate the memory efficiency of my .NET applications; however, I am puzzled as to the memory allocation size that the tool reports for my applications. I am profiling 2 applications: (1) a simple app that has 1 button which when pressed displays the string "Hello World!" in a messagebox, and (2) a slightly more complex application which populates a database with data from a remote machine and then...
0
10214
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10048
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9996
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9865
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7410
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6674
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5304
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
2
3563
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2815
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.