public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
From: Mark Wielaard <mjw@redhat.com>
To: Anton Vorontsov <avorontsov@ru.mvista.com>
Cc: systemtap@sourceware.org, linuxppc-dev@ozlabs.org
Subject: Re: [PATCH 6/8] Use proper types for do_div
Date: Wed, 09 Dec 2009 15:56:00 -0000	[thread overview]
Message-ID: <1260374194.31018.11.camel@springer.wildebeest.org> (raw)
In-Reply-To: <20091127223347.GF21805@oksana.dev.rtsoft.ru>

Hi Anton,

On Sat, 2009-11-28 at 01:33 +0300, Anton Vorontsov wrote: 
> do_div accepts unsigned 64-bit integer type for dividend, signed types
> would cause do_div's typecheck fail:
> 
> stat-common.c: In function 'needed_space':
> stat-common.c:50: error: comparison of distinct pointer types lacks a cast
> ...same errors in time.c and tapset-timers.cxx's generated code...
> 
> A fix for time.c is special, on ppc32 cycles_t is 32-bit, so technically
> we don't need do_div, but since the whole _stp_gettimeofday_ns() operates
> on 64-bit types we'd better be safe and use uint64_t for the math.
> 
> Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com>
> ---
>  runtime/stat-common.c |    8 ++++----
>  runtime/time.c        |    3 ++-
>  tapset-timers.cxx     |    2 +-
>  3 files changed, 7 insertions(+), 6 deletions(-)

I don't immediately see anything wrong with the code. But on x86_64 this
does cause some regression test failures in testsuite/systemtap.maps. In
particular the following tests now fail (they all pass with this one
patch reverted):

Running /home/mark/src/systemtap/testsuite/systemtap.maps/elision.exp ...
FAIL: elision-1
FAIL: elision0
FAIL: elision1
FAIL: elision2
FAIL: elision3
Running /home/mark/src/systemtap/testsuite/systemtap.maps/ix.exp ...
FAIL: systemtap.maps/ix.stp
Running /home/mark/src/systemtap/testsuite/systemtap.maps/linear_large_neg.exp ...
FAIL: systemtap.maps/linear_large_neg.stp
Running /home/mark/src/systemtap/testsuite/systemtap.maps/linear_overunder.exp ...
FAIL: systemtap.maps/linear_overunder.stp
Running /home/mark/src/systemtap/testsuite/systemtap.maps/linear_under.exp ...
FAIL: systemtap.maps/linear_under.stp
Running /home/mark/src/systemtap/testsuite/systemtap.maps/log.exp ...
FAIL: systemtap.maps/log.stp
Running /home/mark/src/systemtap/testsuite/systemtap.maps/log_edge.exp ...
FAIL: systemtap.maps/log_edge.stp

Could you have a look?

Thanks,

Mark

  reply	other threads:[~2009-12-09 15:56 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-27 22:32 [PATCH 0/8 userland!] systemtap: Add initial support for ppc32 Anton Vorontsov
2009-11-27 22:33 ` [PATCH 4/8] Implement ppc32 variant of __is_user_regs Anton Vorontsov
2009-11-27 22:33 ` [PATCH 3/8] stack-ppc: Adjust for ppc32 Anton Vorontsov
2009-11-27 22:33 ` [PATCH 1/8] Rename uprobes_ppc64.c to uprobes_ppc.c, use it " Anton Vorontsov
2009-11-27 22:33 ` [PATCH 7/8] Implement _div64 and _mod64 " Anton Vorontsov
2009-11-27 22:33 ` [PATCH 8/8] Change KERNEL_RELOC_SYMBOL to "_stext" on ppc32 Anton Vorontsov
2009-11-27 22:33 ` [PATCH 2/8] Rename stack-ppc64.c to stack-ppc.c Anton Vorontsov
2009-11-27 22:33 ` [PATCH 5/8] Share ppc64 and ppc32 code where possible Anton Vorontsov
2009-11-27 22:57 ` [PATCH 6/8] Use proper types for do_div Anton Vorontsov
2009-12-09 15:56   ` Mark Wielaard [this message]
2009-12-09 16:09     ` Anton Vorontsov
2009-12-09 22:48       ` Mark Wielaard
2009-12-01 17:55 ` [PATCH 0/8 userland!] systemtap: Add initial support for ppc32 Frank Ch. Eigler
2009-12-01 19:14 ` Jim Keniston

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=1260374194.31018.11.camel@springer.wildebeest.org \
    --to=mjw@redhat.com \
    --cc=avorontsov@ru.mvista.com \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=systemtap@sourceware.org \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).