* copy faults from user_string* functions
@ 2013-07-26 6:36 Eric Wong
2013-07-26 17:08 ` Frank Ch. Eigler
0 siblings, 1 reply; 6+ messages in thread
From: Eric Wong @ 2013-07-26 6:36 UTC (permalink / raw)
To: Systemtap List
Hi all, just to clarify, not all of these faults are user errors, right?
I get these sometimes with some strings (constants, I think):
ERROR: user string copy fault -14 at 000000000042f16c near identifier 'user_string_n' at $prefix/share/systemtap/tapset/uconversions.stp:120:10
I'm using systemtap release-2.3-1-g5033017
Things are heavily multi-threaded and there's an occasional fork/exec
happening for iostat.
Without systemtap, valgrind runs the test suite fine, so it's less
likely to be a bug in the code.
This is for cmogstored, if anybody is interested in reproducing this,
I've pushed my work-in-progress to the "st-wip-broken" branch of
git://bogomips.org/cmogstored.git The HACKING doc in the top-level
should document all the build-dependencies if you want to try to
reproduce it.
Once built and all the dev dependencies installed, I just run:
stap -v tapset/all.stp
And in another terminal: make -jXX check
(note: having slow mount points may increase the chance of test suite
failure since it needs to scan mount points for disk usage reports and
iostat device name <-> MogileFS devid mapping)
Thanks for reading!
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: copy faults from user_string* functions
2013-07-26 6:36 copy faults from user_string* functions Eric Wong
@ 2013-07-26 17:08 ` Frank Ch. Eigler
2013-07-26 17:56 ` Eric Wong
0 siblings, 1 reply; 6+ messages in thread
From: Frank Ch. Eigler @ 2013-07-26 17:08 UTC (permalink / raw)
To: Eric Wong; +Cc: Systemtap List
Hi, Eric -
normalperson wrote:
> Hi all, just to clarify, not all of these faults are user errors, right?
> I get these sometimes with some strings (constants, I think):
> ERROR: user string copy fault -14 at 000000000042f16c near identifier 'user_string_n' at $prefix/share/systemtap/tapset/uconversions.stp:120:10
> [...]
It can simply mean having some not-yet-paged-in data, which in the
spirit of non-interference, stap will not trigger a page fault for.
Please try error-catching constructs such as try{}catch{}, or
--skip-badvars to tolerate them.
> This is for cmogstored, if anybody is interested in reproducing this,
> I've pushed my work-in-progress to the "st-wip-broken" branch of
> git://bogomips.org/cmogstored.git The HACKING doc in the top-level
> should document all the build-dependencies if you want to try to
> reproduce it.
Neat.
- FChE
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: copy faults from user_string* functions
2013-07-26 17:08 ` Frank Ch. Eigler
@ 2013-07-26 17:56 ` Eric Wong
2013-07-26 19:42 ` Eric Wong
2013-07-27 0:22 ` Frank Ch. Eigler
0 siblings, 2 replies; 6+ messages in thread
From: Eric Wong @ 2013-07-26 17:56 UTC (permalink / raw)
To: Frank Ch. Eigler; +Cc: Systemtap List
"Frank Ch. Eigler" <fche@redhat.com> wrote:
> normalperson wrote:
> > Hi all, just to clarify, not all of these faults are user errors, right?
> > I get these sometimes with some strings (constants, I think):
> > ERROR: user string copy fault -14 at 000000000042f16c near identifier 'user_string_n' at $prefix/share/systemtap/tapset/uconversions.stp:120:10
> > [...]
>
> It can simply mean having some not-yet-paged-in data, which in the
> spirit of non-interference, stap will not trigger a page fault for.
> Please try error-catching constructs such as try{}catch{}, or
> --skip-badvars to tolerate them.
Hi Frank, thanks for the response. --skip-badvars seems to work for me.
Is there any optional way to get stap to trigger page faults to get
that data?
When tracing, losing a little performance is OK, especially with
cmogstored (which is entirely network/disk bound).
> > This is for cmogstored, if anybody is interested in reproducing this,
> > I've pushed my work-in-progress to the "st-wip-broken" branch of
> > git://bogomips.org/cmogstored.git The HACKING doc in the top-level
> > should document all the build-dependencies if you want to try to
> > reproduce it.
>
> Neat.
>
> - FChE
--
Eric Wong
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: copy faults from user_string* functions
2013-07-26 17:56 ` Eric Wong
@ 2013-07-26 19:42 ` Eric Wong
2013-07-26 19:50 ` Eric Wong
2013-07-27 0:22 ` Frank Ch. Eigler
1 sibling, 1 reply; 6+ messages in thread
From: Eric Wong @ 2013-07-26 19:42 UTC (permalink / raw)
To: Frank Ch. Eigler; +Cc: Systemtap List
Eric Wong <normalperson@yhbt.net> wrote:
> "Frank Ch. Eigler" <fche@redhat.com> wrote:
> > normalperson wrote:
> > > Hi all, just to clarify, not all of these faults are user errors, right?
> > > I get these sometimes with some strings (constants, I think):
> > > ERROR: user string copy fault -14 at 000000000042f16c near identifier 'user_string_n' at $prefix/share/systemtap/tapset/uconversions.stp:120:10
> > > [...]
> >
> > It can simply mean having some not-yet-paged-in data, which in the
> > spirit of non-interference, stap will not trigger a page fault for.
> > Please try error-catching constructs such as try{}catch{}, or
> > --skip-badvars to tolerate them.
>
> --skip-badvars seems to work for me.
Oops, I was on the wrong machine and running an older branch with
--skip-badvars. try{}catch{} was needed for the user_string_n issue
I was having, but that seems to work.
> Is there any optional way to get stap to trigger page faults to get
> that data?
I could restructure my code to pass integers instead of strings as
a workaround, but I'm trying my best to be lazy :>
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: copy faults from user_string* functions
2013-07-26 19:42 ` Eric Wong
@ 2013-07-26 19:50 ` Eric Wong
0 siblings, 0 replies; 6+ messages in thread
From: Eric Wong @ 2013-07-26 19:50 UTC (permalink / raw)
To: Frank Ch. Eigler; +Cc: Systemtap List
Eric Wong <normalperson@yhbt.net> wrote:
> Eric Wong <normalperson@yhbt.net> wrote:
> > Is there any optional way to get stap to trigger page faults to get
> > that data?
>
> I could restructure my code to pass integers instead of strings as
> a workaround, but I'm trying my best to be lazy :>
Actually, simply reordering my code to access the string (via mempcpy)
before the trace point seems to work around the issue. I'll keep the
try{}catch{} just in case, though.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: copy faults from user_string* functions
2013-07-26 17:56 ` Eric Wong
2013-07-26 19:42 ` Eric Wong
@ 2013-07-27 0:22 ` Frank Ch. Eigler
1 sibling, 0 replies; 6+ messages in thread
From: Frank Ch. Eigler @ 2013-07-27 0:22 UTC (permalink / raw)
To: Eric Wong; +Cc: Systemtap List
Hi, Eric -
On Fri, Jul 26, 2013 at 05:56:02PM +0000, Eric Wong wrote:
> [...]
> Is there any optional way to get stap to trigger page faults to get
> that data?
Not easily. Perhaps from the tracing site, the code could load a few
bytes of the strings whose addresses are being passed. Perhaps try an
mlock() or some other explicit data-segment-dereference loop during
program startup?
> When tracing, losing a little performance is OK, especially with
> cmogstored (which is entirely network/disk bound).
Understood.
- FChE
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2013-07-27 0:22 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-07-26 6:36 copy faults from user_string* functions Eric Wong
2013-07-26 17:08 ` Frank Ch. Eigler
2013-07-26 17:56 ` Eric Wong
2013-07-26 19:42 ` Eric Wong
2013-07-26 19:50 ` Eric Wong
2013-07-27 0:22 ` Frank Ch. Eigler
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).