<div dir="ltr">The time() output would probably not be as accurate as the sched_trace output. I dont know the details of time()s implementation, though, so I could not say with certainty.</div><div class="gmail_extra"><br>
<br><div class="gmail_quote">On Mon, Apr 1, 2013 at 1:31 PM, Youcef Amine Benabbas <span dir="ltr"><<a href="mailto:s9yobena@stud.uni-saarland.de" target="_blank">s9yobena@stud.uni-saarland.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Jonathan,<br>
<br>
Thank you for your reply. I am already doing what you described in your<br>
reply for my work.<br>
<br>
The point is, suppose the /usr/bin/time is executed as a real-time task<br>
under litmus; would the results it provides be suitable for evaluation<br>
purposes, from a real-time point of view?<br>
<br>
Regards,<br>
Youcef<br>
<br>
On Sun, 2013-03-31 at 11:56 -0400, Jonathan Herman wrote:<br>
> Hi Youcef,<br>
><br>
><br>
> The best way to do this would be to use the sched_trace<br>
> infrastructure. The process of capturing this data while a task is<br>
> running is described here:<br>
> <a href="https://wiki.litmus-rt.org/litmus/Tracing" target="_blank">https://wiki.litmus-rt.org/litmus/Tracing</a><br>
><br>
><br>
> You would have you write your own code to parse this data and output<br>
> task utilization. The unit-trace repository contains python code which<br>
> you can use as a guide:<br>
> <a href="http://cs.unc.edu/~mollison/unit-trace/" target="_blank">http://cs.unc.edu/~mollison/unit-trace/</a><br>
><br>
><br>
> The file which parses the sched_trace data is<br>
> unit-trace/unit_trace/trace_reader.py. Sorry for not noticing your<br>
> email sooner.<br>
><br>
> On Sun, Mar 24, 2013 at 11:55 AM, Youcef Amine Benabbas<br>
> <<a href="mailto:s9yobena@stud.uni-saarland.de">s9yobena@stud.uni-saarland.de</a>> wrote:<br>
> Hi everyone,<br>
><br>
> Is there a way to precisely know the cpu usage of a real-time<br>
> task. For<br>
> instance, rtspin (from liblitmus) receives as arguments a wcet<br>
> and<br>
> period; however the utilization of an rtspin task measured by<br>
> the "time"<br>
> command is different from wcet/period.<br>
><br>
> Since the time command will not run in the presence of<br>
> real-time tasks,<br>
> I would like to know if there exists an alternative to<br>
> precisely know<br>
> the cpu utilization of a real-time task (this may be needed if<br>
> the<br>
> performance of a real-time scheduling algorithm has to be<br>
> conducted<br>
> based on the total utilization of a given task-set).<br>
><br>
> Kind regards,<br>
> Youcef<br>
><br>
><br>
> _______________________________________________<br>
> litmus-dev mailing list<br>
> <a href="mailto:litmus-dev@lists.litmus-rt.org">litmus-dev@lists.litmus-rt.org</a><br>
> <a href="https://lists.litmus-rt.org/listinfo/litmus-dev" target="_blank">https://lists.litmus-rt.org/listinfo/litmus-dev</a><br>
><br>
><br>
><br>
><br>
> --<br>
> Jonathan Herman<br>
> Department of Computer Science at UNC Chapel Hill<br>
> _______________________________________________<br>
> litmus-dev mailing list<br>
> <a href="mailto:litmus-dev@lists.litmus-rt.org">litmus-dev@lists.litmus-rt.org</a><br>
> <a href="https://lists.litmus-rt.org/listinfo/litmus-dev" target="_blank">https://lists.litmus-rt.org/listinfo/litmus-dev</a><br>
<br>
<br>
<br>
_______________________________________________<br>
litmus-dev mailing list<br>
<a href="mailto:litmus-dev@lists.litmus-rt.org">litmus-dev@lists.litmus-rt.org</a><br>
<a href="https://lists.litmus-rt.org/listinfo/litmus-dev" target="_blank">https://lists.litmus-rt.org/listinfo/litmus-dev</a><br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>Jonathan Herman<br>Department of Computer Science at UNC Chapel Hill
</div>