mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Serge Noiraud <serge.noiraud@bull.net>
Cc: Lee Revell <rlrevell@joe-job.com>,
	linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: RT : 2.6.12rc5 + realtime-preempt-2.6.12-rc5-V0.7.47-15
Date: Wed, 1 Jun 2005 15:09:49 +0200	[thread overview]
Message-ID: <20050601130949.GB32232@elte.hu> (raw)
In-Reply-To: <1117627375.5580.283.camel@ibiza.btsn.frna.bull.fr>


* Serge Noiraud <serge.noiraud@bull.net> wrote:

> > and start a new search for a maximum latency via:
> > 
> >  echo 0 > /proc/sys/kernel/preempt_max_latency
> > 
> > and then do the X test - what is the largest latency reported in 
> > 'dmesg'? Also, please send me a (bzip2 -9 compressed, if too large) 
> > /proc/latency_trace trace output of the largest incident.
> The max latency reported are normal.

yeah. (btw., enable CONFIG_KALLSYMS to get a much more readable trace 
output)

> I have the problem with another program which mesure latencies about 
> semaphore only in X environment too.
>         
> I tried to ssh this machine from another X environment and the problem 
> does not exist. It's only on the console.

does your measurement program do any tty IO during the measurement? That 
could delay the measurement code artificially. Generally, latency 
measurement must be done very carefully (userspace and kernelspace 
alike).

E.g. rtc_wakeup uses a FIFO between two threads to isolate the 
measurement thread as much as possible. rtc_wakeup can be found at:

   http://www.affenbande.org/~tapas/wiki/index.php?rtc_wakeup

and should be run like:

  chrt -f 95 -p `pidof 'IRQ 8'`
  ./rtc_wakeup -f 1024 -t 100000

if you only trust your own measurement code then you can use a hybrid 
tracing method as well: switch the kernel's trace into 'user triggered':

  echo 1 > /proc/sys/kernel/trace_user_triggered

then you can turn tracing on in your code via a syscall hack:

	gettimeofday(0,1);

(yes - gettimeofday. Has nothing to do with tracing.) You can turn 
tracing off via:

	gettimeofday(0,0);

and the kernel will do a maximum search for you, and you should have the 
highest-latency trace available in /proc/latency_trace.

	Ingo


  reply	other threads:[~2005-06-01 13:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-31 14:53 Serge Noiraud
2005-05-31 19:47 ` Lee Revell
2005-06-01  8:07   ` Serge Noiraud
2005-06-01  8:23     ` Ingo Molnar
2005-06-01 12:02       ` Serge Noiraud
2005-06-01 13:09         ` Ingo Molnar [this message]
2005-06-06 12:12 Serge Noiraud

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=20050601130949.GB32232@elte.hu \
    --to=mingo@elte.hu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rlrevell@joe-job.com \
    --cc=serge.noiraud@bull.net \
    /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

all inboxes | Powered by JetHome®