Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

native profiling tools support #789

Merged
merged 5 commits into from
Apr 5, 2014
Merged

Conversation

LudwigKnuepfer
Copy link
Member

Only works with Linux for now.

Usage:
gprof: make -B clean all-gprof; make term-gprof; make eval-gprof
cachegrind: make -B clean all-cachegrind; make term-cachegrind; make eval-cachegrind

The native-only targets are being restructured along with this PR. They are now more accessible:

term
term-cachegrind
term-gprof
term-valgrind

all
all-cachegrind
all-debug
all-gprof
all-valgrind

eval-gprof
eval-cachegrind

I'll add documentation in the wiki when this gets merged.

Fixes #579

@OlegHahm
Copy link
Member

That's different to the "usual" profiling method for RIOT using -finstrument-functions I suppose?

@LudwigKnuepfer
Copy link
Member Author

This enables the use of gprof. The -finstrument-functions have nothing to do with it.

@LudwigKnuepfer
Copy link
Member Author

If you think this is too confusing I'll rename the make targets to *gprof.

@mehlis
Copy link
Contributor

mehlis commented Feb 26, 2014

works on my system with ccn-lite-client: ACK

@LudwigKnuepfer
Copy link
Member Author

@OlegHahm What do you think?

@LudwigKnuepfer
Copy link
Member Author

Actually - after looking into this a bit - I'd like to change this either way. gprof is not the only tool for the job and certainly not the best. I'll update the PR shortly.

@LudwigKnuepfer
Copy link
Member Author

Changed it.

@LudwigKnuepfer
Copy link
Member Author

rebased

only works with Linux for now
The new target names are easier to remember / decipher:

term
term-cachegrind
term-gprof
term-valgrind

all
all-cachegrind
all-gprof
all-valgrind
all-debug

eval-gprof
eval-cachegrind
@LudwigKnuepfer
Copy link
Member Author

rebased, restructured native-only targets

@LudwigKnuepfer
Copy link
Member Author

@OlegHahm ping

@LudwigKnuepfer LudwigKnuepfer assigned OlegHahm and unassigned mehlis Apr 1, 2014
@LudwigKnuepfer
Copy link
Member Author

@OlegHahm ping

@LudwigKnuepfer LudwigKnuepfer added this to the Release 2014.04 milestone Apr 2, 2014
@mehlis
Copy link
Contributor

mehlis commented Apr 4, 2014

ACK - works with gcc and O2 / O3

@LudwigOrtmann please squash....and merge

I'm going to use this code in my thesis

@Kijewski
Copy link
Contributor

Kijewski commented Apr 5, 2014

Found it to be working.
ACK.

Kijewski added a commit that referenced this pull request Apr 5, 2014
@Kijewski Kijewski merged commit 2749531 into RIOT-OS:master Apr 5, 2014
@LudwigKnuepfer LudwigKnuepfer deleted the native_gprof branch April 7, 2014 12:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: native Platform: This PR/issue effects the native platform Type: bug The issue reports a bug / The PR fixes a bug (including spelling errors) Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

native: add profiling support
4 participants