mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paul Mackerras <paulus@samba.org>
To: mingo@redhat.com, hpa@zytor.com, acme@redhat.com,
	linux-kernel@vger.kernel.org, jkacur@redhat.com,
	a.p.zijlstra@chello.nl, efault@gmx.de, rostedt@goodmis.org,
	mtosatti@redhat.com, tglx@linutronix.de,
	cjashfor@linux.vnet.ibm.com, mingo@elte.hu
Cc: linux-tip-commits@vger.kernel.org
Subject: Re: [tip:perfcounters/core] perf_counter tools: Introduce stricter C code checking
Date: Thu, 28 May 2009 13:56:01 +1000	[thread overview]
Message-ID: <18974.2897.822557.905261@drongo.ozlabs.ibm.com> (raw)
In-Reply-To: <tip-16f762a2ac5ecf8a11f6f0332e46cc3459220da5@git.kernel.org>

tip-bot for Ingo Molnar writes:

> perf_counter tools: Introduce stricter C code checking
> 
> Tighten up our C code requirements:
> 
>  - disallow warnings

This causes failures when I compile it as a 64-bit executable on
powerpc:

    CC builtin-record.o
builtin-record.c: In function 'pid_synthesize_mmap_events':
builtin-record.c:241: warning: format '%llx' expects type 'long long unsigned int *', but argument 3 has type '__u64 *'
builtin-record.c:241: warning: format '%llx' expects type 'long long unsigned int *', but argument 4 has type '__u64 *'
builtin-record.c:241: warning: format '%llx' expects type 'long long unsigned int *', but argument 9 has type '__u64 *'

This is because u64 is an unsigned long in userspace for a 64-bit
build, not unsigned long long.  I'm not sure how best to solve this
problem.

If I compile it as a 32-bit executable, it doesn't generate warnings,
but when I try to run "perf top" (this is on a 64-bit kernel, of
course, since 32-bit powerpc kernels don't currently support
perf_counters), I get:

# perf top
 left: 0000000000000000
   ip: 00000000000891a4
right: 00000000ffffffff
KernelTop refresh period: 2 seconds
perf: builtin-top.c:453: record_ip: Assertion `left <= ip && ip <= right' failed.
Aborted

Paul.

  reply	other threads:[~2009-05-28  3:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-26 22:21 [PATCH 2/2 tip] perf: report should only load text symbols from kallsyms Arnaldo Carvalho de Melo
2009-05-27  6:10 ` Ingo Molnar
2009-05-27  7:16 ` [tip:perfcounters/core] perf report: Only " tip-bot for Arnaldo Carvalho de Melo
2009-05-27  7:16 ` [tip:perfcounters/core] perf report: Only load text symbols from kallsyms, fix tip-bot for Ingo Molnar
2009-05-27  7:16 ` [tip:perfcounters/core] perf_counter tools: Introduce stricter C code checking tip-bot for Ingo Molnar
2009-05-28  3:56   ` Paul Mackerras [this message]
2009-05-28  8:35     ` Ingo Molnar

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=18974.2897.822557.905261@drongo.ozlabs.ibm.com \
    --to=paulus@samba.org \
    --cc=a.p.zijlstra@chello.nl \
    --cc=acme@redhat.com \
    --cc=cjashfor@linux.vnet.ibm.com \
    --cc=efault@gmx.de \
    --cc=hpa@zytor.com \
    --cc=jkacur@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tip-commits@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=mingo@redhat.com \
    --cc=mtosatti@redhat.com \
    --cc=rostedt@goodmis.org \
    --cc=tglx@linutronix.de \
    /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®