Go to Post I suggest that you don't discuss...sensitive issues about your team on this public forum. - Andy Baker [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 20-02-2015, 08:38
wireties's Avatar
wireties wireties is offline
Principal Engineer
AKA: Keith Buchanan
FRC #1296 (Full Metal Jackets)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Rockwall, TX
Posts: 1,170
wireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond repute
Send a message via AIM to wireties
profiling roborio apps

Does anyone know if kernel and/or user space support exists for profiling our FRC applications? Is oprofile in the kernel? Are the opcontrol apps in the file system?

It is my understanding that gprof is not supported by uclibc. Does the robot use uclibc and busybox?

I'll investigate all this but was hoping my reverse engineering might be helped with input from beta users, WPI contributors and NI folks.

TIA
__________________
Fast, cheap or working - pick any two!

Last edited by wireties : 20-02-2015 at 08:41.
  #2   Spotlight this post!  
Unread 20-02-2015, 10:15
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,753
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: profiling roborio apps

I have always used the profiler built into the LV scheduler, or the tracing that RT has in its schedulers. I checked with someone, and in the 2015 build, oprofile is in the kernel. I suspect it is in 2014 too.

Greg McKaskle
  #3   Spotlight this post!  
Unread 20-02-2015, 14:02
wireties's Avatar
wireties wireties is offline
Principal Engineer
AKA: Keith Buchanan
FRC #1296 (Full Metal Jackets)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Rockwall, TX
Posts: 1,170
wireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond reputewireties has a reputation beyond repute
Send a message via AIM to wireties
Re: profiling roborio apps

Thanks for the feedback Greg! We are using C++ so i reckon the LV profiling tools are not accessible or useful, correct?

Can you ask about the Task class? It appears to use pthreads but the priority stuff is not used. Are RT or non-zero static priorities supported in the kernel? Of course we'd have to run as root, not lvuser, to set the priorities.

These probably seem like goofy questions but our C++ code is based on standard practices using threads and messages rather than the WPI models. We routinely alter the relative priorities of our tasks in the cRio - it would be nice to do so again.

TIA
__________________
Fast, cheap or working - pick any two!
  #4   Spotlight this post!  
Unread 21-02-2015, 07:45
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,753
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: profiling roborio apps

The LV profiling relies on instrumentation put in place by the LV compiler and hooks in the LV scheduler, so no, it won't help. I believe the trace tool would show some minimal thread activity, but not routines.

I'll ask on Monday. I would expect Task to be a simplified wrapper over pthreads. I would assume that you can change your own process's thread priorities as lvuser within RLIMIT_RTPRIO values. The LV timed loop and time-critical priorities are after-all run as lvuser.

In case you haven't seen it http://www.ni.com/white-paper/14626/en/#toc5 and especially the links in section five will give you some background on the linux configuration of the roboRIO. I expect that if you install the operf and other tools that you are set for profiling C++.

Greg McKaskle
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 21:17.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi