All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro>
To: Mathieu Desnoyers <mathieu.desnoyers@polymtl.ca>
Cc: Pekka Enberg <penberg@cs.helsinki.fi>,
	Dipankar Sarma <dipankar@in.ibm.com>,
	Alexey Dobriyan <adobriyan@gmail.com>,
	Ingo Molnar <mingo@elte.hu>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] kmemtrace: Use tracepoints instead of markers.
Date: Mon, 5 Jan 2009 19:57:50 +0200	[thread overview]
Message-ID: <20090105175750.GB5196@localhost> (raw)
In-Reply-To: <20090105160534.GA7708@Krystal>

On Mon, Jan 05, 2009 at 11:05:34AM -0500, Mathieu Desnoyers wrote:
> Hopefully it does, especially when there are no side-effects. Can you
> also try with -Os ?
> 
> Mathieu

Here's the disassembled code when using -Os. It seems it's optimised, as
with -O2. My GCC's version is 4.3.2 (Gentoo Linux).

If you want to test yourself, the output was generated with 'objdump -d
-S -a'.

What do you think?

static void print_that(unsigned long num)
{
	printf("input << 5 == %lu\n", num);
  40062d:	48 c1 e6 05          	shl    $0x5,%rsi
  400631:	bf 5e 07 40 00       	mov    $0x40075e,%edi
  400636:	31 c0                	xor    %eax,%eax
  400638:	e8 6b fe ff ff       	callq  4004a8 <printf@plt>
	sscanf(argv[2], "%lu", &in);

	call_do_something(in);

	return 0;
}
  40063d:	5a                   	pop    %rdx
  40063e:	59                   	pop    %rcx
  40063f:	31 c0                	xor    %eax,%eax
  400641:	5b                   	pop    %rbx
  400642:	c3                   	retq   


	Eduard


  reply	other threads:[~2009-01-05 17:57 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-29  1:40 [PATCH 0/3] kmemtrace over tracepoints Eduard - Gabriel Munteanu
2008-12-29  1:40 ` [PATCH 1/3] RCU: Move some definitions to minimal headers Eduard - Gabriel Munteanu
2008-12-29  9:42   ` Pekka Enberg
2008-12-29 12:32     ` Ingo Molnar
2008-12-30  6:31     ` Paul E. McKenney
2008-12-29 14:56   ` Ingo Molnar
2008-12-29  1:40 ` [PATCH 2/3] tracepoints: Include only minimal RCU headers in linux/tracepoint.h Eduard - Gabriel Munteanu
2008-12-29  1:40 ` [PATCH 3/3] kmemtrace: Use tracepoints instead of markers Eduard - Gabriel Munteanu
2008-12-29  9:44   ` Pekka Enberg
2009-01-02 20:54     ` Mathieu Desnoyers
2009-01-02 23:03       ` Eduard - Gabriel Munteanu
2008-12-29 13:43   ` Pekka Enberg
2008-12-29 20:11     ` Eduard - Gabriel Munteanu
2009-01-02 20:53   ` Mathieu Desnoyers
2009-01-02 23:01     ` Eduard - Gabriel Munteanu
2009-01-02 23:42       ` Mathieu Desnoyers
2009-01-04  1:53         ` Eduard - Gabriel Munteanu
2009-01-04  4:10         ` Eduard - Gabriel Munteanu
2009-01-05 16:05           ` Mathieu Desnoyers
2009-01-05 17:57             ` Eduard - Gabriel Munteanu [this message]
2009-01-05 18:09               ` Mathieu Desnoyers
2008-12-29  9:41 ` [PATCH 0/3] kmemtrace over tracepoints Pekka Enberg

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=20090105175750.GB5196@localhost \
    --to=eduard.munteanu@linux360.ro \
    --cc=adobriyan@gmail.com \
    --cc=dipankar@in.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mathieu.desnoyers@polymtl.ca \
    --cc=mingo@elte.hu \
    --cc=penberg@cs.helsinki.fi \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.