From: "Crim, Jason" <jason.crim@thyssenkrupp.com>
To: ptxdist@pengutronix.de
Subject: Re: [ptxdist] Including valgrind in the configuration doesn't trigger an un-optimized build of glibc.
Date: Thu, 5 Apr 2018 14:41:38 -0500 [thread overview]
Message-ID: <2D79272AFFD75A4392ED2D3EF16D3B53B5212F@mdcxch20.na.ops.local> (raw)
In-Reply-To: <20180329092053.fcnigz4wqs3p2dsh@pengutronix.de>
Michael, thank you for your suggestion.
I've got my toolchain switched to the arm-v7a-linux-gnueabihf (from the arm-cortexa8-linux-gnueabihf), and valgrind is now working. It complains about _armv7_tick being an unrecognized instruction, but my program does continue to run (in defiance of valgrind's warning message).
Long term, what are the trade-offs for using the v7a vs. the cortexa8 toolchains in production? I do not know the history of the decision in my organization, but the cortex toolchain was in place before my arrival. I'm trying to decide whether to keep the change local on my dev/debug system, or suggest a migration.
Thanks again.
- Jason
-----Original Message-----
From: ptxdist [mailto:ptxdist-bounces@pengutronix.de] On Behalf Of Michael Olbrich
Sent: Thursday, March 29, 2018 5:21 AM
To: ptxdist@pengutronix.de
Subject: Re: [ptxdist] Including valgrind in the configuration doesn't trigger an un-optimized build of glibc.
On Wed, Mar 28, 2018 at 10:43:14AM -0500, Crim, Jason wrote:
> Thanks for your information. My setup includes glibc 2.20 rather than
> the
> 2.16 referenced in your patch file, so I don't think it'll work
> directly (the source of 2.20 and 2.16 look pretty different -
> actually, I'm not even seeing the files referenced in the 2.16 source
> I pulled from the glibc archive today), but perhaps it'll help me find the answers I need.
>
> My results from readelf on libc.so.6 look a bit different:
> > 14499: 00058f21 0 FUNC GLOBAL DEFAULT 11 memcpy
> > 12773: 00056f11 740 FUNC GLOBAL DEFAULT 11 strcmp
> > 14536: 00057701 220 FUNC GLOBAL DEFAULT 11 strlen
>
> there are no "FUNC LOCAL DEFAULT" for the base functions - though memcpy does have a size of 0 here.
>
> My ld-2.20.so (which is the file valgrind referenced) yeilds similar results to yours:
> > 916: 00012921 0 FUNC LOCAL DEFAULT 10 memcpy
> > 1033: 00011b31 740 FUNC LOCAL DEFAULT 10 strcmp
> > 1083: 00012041 220 FUNC LOCAL DEFAULT 10 strlen
>
> with the exception of strcmp and strlen. Which makes sense given the
> valgrind output in my last message. Replacing ld-2.20.so moved the
> error from strcmp to memcpy.
>
> I'm actually seeing similar entries ('0 FUNC LOCAL DEFAULT') for memcpy,
> memchr, index, memset, and strchr in ld-2.20.so.
If you use the cortexa8 toolchain, the you can avoid the problem mentioned by Andrej by switching to the v7a toolchain. It optimizes a bit differently but should work for you.
Michael
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
next prev parent reply other threads:[~2018-04-05 19:41 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-28 10:01 Andrej.Gantvorg
2018-03-28 15:43 ` Crim, Jason
2018-03-29 9:20 ` Michael Olbrich
2018-04-05 19:41 ` Crim, Jason [this message]
2018-04-09 8:41 ` Michael Olbrich
2018-04-09 12:13 ` Crim, Jason
2018-04-09 13:49 ` Michael Olbrich
-- strict thread matches above, loose matches on Subject: below --
2018-03-22 17:38 Crim, Jason
2018-03-26 6:30 ` Michael Olbrich
2018-03-26 12:03 ` Crim, Jason
2018-03-27 7:33 ` Michael Olbrich
2018-03-27 11:54 ` Crim, Jason
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2D79272AFFD75A4392ED2D3EF16D3B53B5212F@mdcxch20.na.ops.local \
--to=jason.crim@thyssenkrupp.com \
--cc=ptxdist@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox