Re: [PATCH tracing/kprobes v2 1/5] tracing/kprobes: Rename specialvariables syntax
From: Frederic Weisbecker
Date: Mon Oct 05 2009 - 17:57:50 EST
On Mon, Oct 05, 2009 at 05:34:24PM -0400, Masami Hiramatsu wrote:
> Hmm, one idea hits me, how about this? :)
> - %register
> - %%spvars (%%retval, %%arg0)
The problem is that such % or %% symbols have a specific
mean in some other well known areas.
If we borrow the % from the AT&T assembly syntax style
to use register names, that we can retrieve in gcc inline
assembly, then one may expect %% to have a meaning inspired
from the same area. %% has its sense in gcc inline assembly,
but applied there, it looks confusing.
I mean, I'm trying to think like someone reading a perf probe
command line without any documentation. The more this person
can understand this command line without documentation, the better.
We know that % is used for register names, some people know that %%
is used for register names too but when we are in gcc inline assembly
with var to reg resolution and need true registers name.
Then if I try to mirror this sense from gcc to perf probe use,
I feel confused, especially in the case of %%arg1.
In this case, we should rather have %%register and %arg0 :)
Hm, %register is a clear pattern.
Somehow, %retval looks clear too, retval is verbose enough and
% is still logical as return values are most of the time (always?)
put in a register.
But %%arg0 looks confusing.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/