Mirror of the lttng-dev mailing list
 help / color / mirror / Atom feed
From: mathieu.desnoyers@efficios.com (Mathieu Desnoyers)
Subject: [lttng-dev] [RFC PATCH lttng-ust] Fix: don't generate 0-len array in tracepoint probes
Date: Tue, 31 May 2016 09:36:30 +0000 (UTC)	[thread overview]
Message-ID: <660311745.23694.1464687390139.JavaMail.zimbra@efficios.com> (raw)
In-Reply-To: <574C8196.8020508@gydle.com>

----- On May 30, 2016, at 8:08 PM, Sebastien Boisvert sboisvert at gydle.com wrote:

> Greetings,
> 
> This is a response to the message
> https://lists.lttng.org/pipermail/lttng-dev/2016-May/026066.html
> 
> The builds below were generated with:
> 
> lttng-ust ba5b4491f94109eaca10b2c285f8d1f116a38e5c
> gcc 4.9.3-8ubuntu2~14.04
> 
> First, I compiled lttng-ust with the "-pedantic" option of gcc to verify that
> this causes an array
> of compilation errors.
> 
> sboisvert at Z1:~/lttng-ust$ ./bootstrap
> sboisvert at Z1:~/lttng-ust$ ./configure --prefix=$HOME/lttng-ust.build
> sboisvert at Z1:~/lttng-ust$ make CFLAGS="-pedantic" &> log
> sboisvert at Z1:~/lttng-ust$ grep error log
> //#error UST_COMPONENT is undefined
> ../include/lttng/ust-tracepoint-event.h:291:40: error: zero or negative size
> array '__event_fields___lttng_ust_statedump___start'
> ../include/lttng/ust-tracepoint-event.h:291:40: error: zero or negative size
> array '__event_fields___lttng_ust_statedump___end'
> 
> 
> I applied the patch that Mathieu provided, and built the project and ran the
> tests.
> 
> sboisvert at Z1:~/lttng-ust$ patch -p1 < ~/lttng-ust-empty-array.patch
> patching file include/lttng/ust-tracepoint-event.h
> 
> sboisvert at Z1:~/lttng-ust$ make CFLAGS="-pedantic" &> log
> sboisvert at Z1:~/lttng-ust$ cd tests
> 
> ============================================================================
> Testsuite summary for lttng-ust 2.9.0-pre
> ============================================================================
> # TOTAL: 51
> # PASS:  51
> # SKIP:  0
> # XFAIL: 0
> # FAIL:  0
> # XPASS: 0
> # ERROR: 0
> ============================================================================
> 
> 
> So, this patch improves the user experience when one is using advanced linting
> flags as well as
> tracepoint event probes with no arguments, and it does not break the envelope of
> known behaviour.
> 
> 
> +1

Great! I have run the make check tests from lttng-tools also
with the patch applied, and they also all pass. So I am merging
this into master, 2.8, 2.7 of lttng-ust.

Thanks for helping us improve LTTng!

Mathieu

> _______________________________________________
> lttng-dev mailing list
> lttng-dev at lists.lttng.org
> https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev

-- 
Mathieu Desnoyers
EfficiOS Inc.
http://www.efficios.com


  reply	other threads:[~2016-05-31  9:36 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-30 18:08 Sebastien Boisvert
2016-05-31  9:36 ` Mathieu Desnoyers [this message]
  -- strict thread matches above, loose matches on Subject: below --
2016-05-30 16:56 Mathieu Desnoyers

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=660311745.23694.1464687390139.JavaMail.zimbra@efficios.com \
    --to=mathieu.desnoyers@efficios.com \
    /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