It used to be that a log(string) statement would add a newline (version 1.0/0.142): $ stap -e 'probe begin { log("begin"); log("done"); exit(); }' begin done But with recent git (version 1.0/0.142 commit release-1.0-17-g9e75660) it gives: $ /usr/local/install/systemtap/bin/stap -e 'probe begin { log("begin"); log("done"); exit(); }' begindone This causes some make installcheck failures, like cxxclass.exp.
This was introduced by: commit 450718c9c424bce67e8580183788380431f90434 Author: Frank Ch. Eigler <fche@elastic.org> Date: Wed Sep 23 07:41:47 2009 -0400 PR10390: ftrace() tapset function * tapset/logging.stp (ftrace): New function. (*): Add kerneldoc to other functions. * doc/SystemTap_Tapset_Reference/tapsets.tmpl: Process logging.stp. * stapfuncs.3stap.in: Remove "LOGGING" section, now redundant. * runtime/autoconf-trace-printk.c: New autoconf test. * buildrun.cxx (compile_pass): Build it. * NEWS: Mention it. * testsuite/buildok/logging.stp: Test it.
In particular, reverting this hunk against tapset/logging.stp fixes it: function log (msg:string) %{ /* unprivileged */ - _stp_printf ("%s\n", THIS->msg); + _stp_print (THIS->msg); %}
Committed the reversal of the code in comment #2, since it seems to solve the testsuite failures, as: commit d498530cec1fcf4b71b1b27a068206fda18f3188 Author: Mark Wielaard <mjw@redhat.com> Date: Mon Sep 28 15:34:56 2009 +0200 PR10700 Add newline after log() message. * tapset/logging.stp (log): Use _stp_printf "%s\n". Please revert if this breaks some of the newer ftrace logging.
It doesn't seem needed and the change would be a regression anyway.