From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13188 invoked by alias); 9 Jul 2014 07:49:12 -0000 Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner@cygwin.com Mail-Followup-To: cygwin@cygwin.com Received: (qmail 13166 invoked by uid 89); 9 Jul 2014 07:49:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=2.2 required=5.0 tests=AWL,BAYES_40,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: nm9.bullet.mail.ne1.yahoo.com Received: from nm9.bullet.mail.ne1.yahoo.com (HELO nm9.bullet.mail.ne1.yahoo.com) (98.138.90.72) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Wed, 09 Jul 2014 07:49:10 +0000 Received: from [98.138.100.102] by nm9.bullet.mail.ne1.yahoo.com with NNFMP; 09 Jul 2014 07:49:08 -0000 Received: from [98.138.87.8] by tm101.bullet.mail.ne1.yahoo.com with NNFMP; 09 Jul 2014 07:49:07 -0000 Received: from [127.0.0.1] by omp1008.mail.ne1.yahoo.com with NNFMP; 09 Jul 2014 07:49:07 -0000 Received: (qmail 29199 invoked by uid 60001); 9 Jul 2014 07:49:07 -0000 Received: from [192.88.166.1] by web122402.mail.ne1.yahoo.com via HTTP; Wed, 09 Jul 2014 00:49:07 PDT Message-ID: <1404892147.73620.YahooMailNeo@web122402.mail.ne1.yahoo.com> Date: Wed, 09 Jul 2014 07:49:00 -0000 From: Dragos Tarcatu Reply-To: Dragos Tarcatu Subject: Problem with gprof for code containing static functions To: "cygwin@cygwin.com" MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="1494295045-441981906-1404892147=:73620" X-SW-Source: 2014-07/txt/msg00108.txt.bz2 --1494295045-441981906-1404892147=:73620 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Content-length: 1741 I've been encountering some problems using gprof (GNU gprof (GNU Binutils) = 2.24.51.20140623) in the most recent cygwin (32 bits) . Basically gprof see= ms to be missing static functions calls in the flat profile report. For the= attached source file (compiled with -Wall -g -pedantic -std=3Dc99 -pg -O0)= if I disable the USE_STATIC macro the flat report seems ok.=20 Each sample counts as 0.01 seconds.=20 =A0 % cumulative self self total=20 =A0time seconds seconds calls s/call s/call name=20 =A089.24 1.99 1.99 100000000 0.00 0.00 f5=20 =A0 8.07 2.17 0.18 _mcount_private=20 =A0 1.79 2.21 0.04 1000000 0.00 0.00 f4=20 =A0 0.90 2.23 0.02 _fentry__=20 =A0 0.00 2.23 0.00 10000 0.00 0.00 f3=20 =A0 0.00 2.23 0.00 100 0.00 0.02 f2=20 =A0 0.00 2.23 0.00 1 0.00 2.03 f1=20 =A0=20 But if I enable it (making those functions static) I get pretty weird resul= ts:=20 Each sample counts as 0.01 seconds.=20 =A0 % cumulative self self total=20 =A0time seconds seconds calls Ts/call Ts/call name=20 =A087.78 1.94 1.94 f5=20 =A0 8.60 2.13 0.19 _mcount_private=20 =A0 1.81 2.17 0.04 _fentry__=20 =A0 1.81 2.21 0.04 f4=20 =A0 0.00 2.21 0.00 101010000 0.00 0.00 __gcc_deregister_f= rame=20 =A0 0.00 2.21 0.00 100 0.00 0.00 f2=20 =A0 0.00 2.21 0.00 1 0.00 0.00 f1=20 Is this a known issue?=20 --1494295045-441981906-1404892147=:73620 Content-Type: text/plain; name="test.c" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="test.c" Content-length: 940 I2luY2x1ZGU8c3RkaW8uaD4NCiNpbmNsdWRlPHN0ZGxpYi5oPg0KDQoNCiNk ZWZpbmUgTjEgMTAwDQojZGVmaW5lIE4yIDEwMA0KI2RlZmluZSBOMyAxMDAN CiNkZWZpbmUgTjQgMTAwDQoNCiNkZWZpbmUgVVNFX1NUQVRJQw0KDQojaWZk ZWYgVVNFX1NUQVRJQw0Kc3RhdGljDQojZW5kaWYNCnZvaWQgZjUoKSB7DQog ICAgaW50IGk7DQogICAgZm9yIChpID0gMDsgaSA8IDEwOyBpKyspIHsNCiAg ICB9DQp9DQoNCiNpZmRlZiBVU0VfU1RBVElDDQpzdGF0aWMNCiNlbmRpZg0K dm9pZCBmNCgpICB7DQogICAgaW50IGk7DQogICAgZm9yIChpID0gMDsgaSA8 IE40OyBpKyspIHsNCiAgICAgICAgZjUoKTsNCiAgICB9DQp9DQoNCiNpZmRl ZiBVU0VfU1RBVElDDQpzdGF0aWMNCiNlbmRpZg0Kdm9pZCBmMygpIHsNCiAg ICBpbnQgaTsNCiAgICBmb3IgKGkgPSAwOyBpIDwgTjM7IGkrKykgew0KICAg ICAgICBmNCgpOw0KICAgIH0NCn0NCg0KDQp2b2lkIGYyKCkgew0KICAgIGlu dCBpOw0KICAgIGZvciAoaSA9IDA7IGkgPCBOMjsgaSsrKSB7DQogICAgICAg IGYzKCk7DQogICAgfQ0KfQ0KDQp2b2lkIGYxKCkgew0KICAgIGludCBpOw0K ICAgIGZvciAoaSA9IDA7IGkgPCBOMTsgaSsrKSB7DQogICAgICAgIGYyKCk7 DQogICAgfQ0KfQ0KDQoNCmludCBtYWluKCkgew0KICAgIGYxKCk7DQogICAg cmV0dXJuIDA7DQp9DQoNCg== --1494295045-441981906-1404892147=:73620 Content-Type: text/plain; charset=us-ascii Content-length: 218 -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple --1494295045-441981906-1404892147=:73620--