LKML Archive on
 help / color / Atom feed
From: sebhtml <>
To: Andrew Morton <>,
	Dan Williams <>
Cc: Steven Rostedt <>,,,
	Namhyung Kim <>,,,,
	Linux Kernel Mailing List <>
Subject: Re: [PATCH] pfn_t: force '~' to be parsed as an unary operator
Date: Wed, 24 Oct 2018 19:52:40 -0400
Message-ID: <> (raw)
In-Reply-To: <>

On 2018-10-24 6:43 p.m., Andrew Morton wrote:
> I grabbed it, and added cc:stable.
> But aren't we fixing this in the wrong place?  That's a valid
> expression and if this isn't addressed in perf then we may hit a
> similar issue elsewhere...


Based on:
     git:// 01aa9d518eae8a4d75cd3049defc6ed0b6d0a658

In perf, the warning
       [fs_dax:dax_pmd_insert_mapping] unknown op '~'
comes from tools/lib/traceevent/event-parse.c at line 2045:
                 do_warning_event(event, "unknown op '%s'", token);

This is in this function:

static enum tep_event_type
process_op(struct tep_event_format *event, struct tep_print_arg *arg, char **tok);

The code path to reach the good '~' case needs:
         if (arg->type == TEP_PRINT_OP && !arg->op.left) {

I assume that here arg->op.left is not NULL because of (u64) on the left.

~(((u64) ~(~(((1UL) << 12)-1)))

However, I fail to see where '~' is parsed as a binary operator though.

Any pointer would be welcome.

      parent reply index

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-21 14:59 Sebastien Boisvert
2018-10-22 17:13 ` Dan Williams
2018-10-24 22:43   ` Andrew Morton
     [not found]   ` <>
2018-10-24 23:52     ` sebhtml [this message]

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

LKML Archive on

Archives are clonable:
	git clone --mirror lkml/git/0.git
	git clone --mirror lkml/git/1.git
	git clone --mirror lkml/git/2.git
	git clone --mirror lkml/git/3.git
	git clone --mirror lkml/git/4.git
	git clone --mirror lkml/git/5.git
	git clone --mirror lkml/git/6.git
	git clone --mirror lkml/git/7.git
	git clone --mirror lkml/git/8.git
	git clone --mirror lkml/git/9.git
	git clone --mirror lkml/git/10.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 lkml lkml/ \
	public-inbox-index lkml

Example config snippet for mirrors

Newsgroup available over NNTP:

AGPL code for this site: git clone