linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: kbuild-all@01.org, linux-kernel@vger.kernel.org,
	tipbuild@zytor.com, Ingo Molnar <mingo@kernel.org>,
	Will Deacon <will.deacon@arm.com>
Subject: [tip:locking/core 6/10] arch/x86/include/asm/rmwcc.h:23:17: error: jump into statement expression
Date: Sat, 20 Oct 2018 11:05:11 +0800	[thread overview]
Message-ID: <201810201105.YsnXEXTU%fengguang.wu@intel.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 14636 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git locking/core
head:   01a14bda11add9dcd4a59200f13834d634559935
commit: 7aa54be2976550f17c11a1c3e3630002dea39303 [6/10] locking/qspinlock, x86: Provide liveness guarantee
config: x86_64-randconfig-u0-10201040 (attached as .config)
compiler: gcc-5 (Debian 5.5.0-3) 5.4.1 20171010
reproduce:
        git checkout 7aa54be2976550f17c11a1c3e3630002dea39303
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All errors (new ones prefixed by >>):

   In file included from arch/x86/include/asm/atomic.h:5:0,
                    from include/linux/atomic.h:7,
                    from include/linux/crypto.h:20,
                    from arch/x86/kernel/asm-offsets.c:9:
   arch/x86/include/asm/qspinlock.h: In function 'queued_fetch_set_pending_acquire':
>> arch/x86/include/asm/rmwcc.h:23:17: error: jump into statement expression
       : clobbers : cc_label);    \
                    ^
   include/linux/compiler.h:58:42: note: in definition of macro '__trace_if'
     if (__builtin_constant_p(!!(cond)) ? !!(cond) :   \
                                             ^
   arch/x86/include/asm/qspinlock.h:18:2: note: in expansion of macro 'if'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
     ^
   arch/x86/include/asm/rmwcc.h:21:2: note: in expansion of macro 'asm_volatile_goto'
     asm_volatile_goto (fullop "; j" #cc " %l[cc_label]"  \
     ^
   arch/x86/include/asm/rmwcc.h:54:2: note: in expansion of macro '__GEN_RMWcc'
     __GEN_RMWcc(op " %[val], " arg0, var, cc,   \
     ^
   arch/x86/include/asm/rmwcc.h:58:2: note: in expansion of macro 'GEN_BINARY_RMWcc_6'
     GEN_BINARY_RMWcc_6(op, var, cc, vcon, val, "%[var]")
     ^
   arch/x86/include/asm/rmwcc.h:9:30: note: in expansion of macro 'GEN_BINARY_RMWcc_5'
    #define __RMWcc_CONCAT(a, b) a ## b
                                 ^
   arch/x86/include/asm/rmwcc.h:10:28: note: in expansion of macro '__RMWcc_CONCAT'
    #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
                               ^
   arch/x86/include/asm/rmwcc.h:60:32: note: in expansion of macro 'RMWcc_CONCAT'
    #define GEN_BINARY_RMWcc(X...) RMWcc_CONCAT(GEN_BINARY_RMWcc_, RMWcc_ARGS(X))(X)
                                   ^
   arch/x86/include/asm/qspinlock.h:18:6: note: in expansion of macro 'GEN_BINARY_RMWcc'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
         ^
   arch/x86/include/asm/rmwcc.h:25:1: note: label 'cc_label' defined here
    cc_label: c = true;      \
    ^
   include/linux/compiler.h:58:30: note: in definition of macro '__trace_if'
     if (__builtin_constant_p(!!(cond)) ? !!(cond) :   \
                                 ^
   arch/x86/include/asm/qspinlock.h:18:2: note: in expansion of macro 'if'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
     ^
   arch/x86/include/asm/rmwcc.h:54:2: note: in expansion of macro '__GEN_RMWcc'
     __GEN_RMWcc(op " %[val], " arg0, var, cc,   \
     ^
   arch/x86/include/asm/rmwcc.h:58:2: note: in expansion of macro 'GEN_BINARY_RMWcc_6'
     GEN_BINARY_RMWcc_6(op, var, cc, vcon, val, "%[var]")
     ^
   arch/x86/include/asm/rmwcc.h:9:30: note: in expansion of macro 'GEN_BINARY_RMWcc_5'
    #define __RMWcc_CONCAT(a, b) a ## b
                                 ^
   arch/x86/include/asm/rmwcc.h:10:28: note: in expansion of macro '__RMWcc_CONCAT'
    #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
                               ^
   arch/x86/include/asm/rmwcc.h:60:32: note: in expansion of macro 'RMWcc_CONCAT'
    #define GEN_BINARY_RMWcc(X...) RMWcc_CONCAT(GEN_BINARY_RMWcc_, RMWcc_ARGS(X))(X)
                                   ^
   arch/x86/include/asm/qspinlock.h:18:6: note: in expansion of macro 'GEN_BINARY_RMWcc'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
         ^
>> arch/x86/include/asm/rmwcc.h:25:1: error: duplicate label 'cc_label'
    cc_label: c = true;      \
    ^
   include/linux/compiler.h:58:42: note: in definition of macro '__trace_if'
     if (__builtin_constant_p(!!(cond)) ? !!(cond) :   \
                                             ^
   arch/x86/include/asm/qspinlock.h:18:2: note: in expansion of macro 'if'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
     ^
   arch/x86/include/asm/rmwcc.h:54:2: note: in expansion of macro '__GEN_RMWcc'
     __GEN_RMWcc(op " %[val], " arg0, var, cc,   \
     ^
   arch/x86/include/asm/rmwcc.h:58:2: note: in expansion of macro 'GEN_BINARY_RMWcc_6'
     GEN_BINARY_RMWcc_6(op, var, cc, vcon, val, "%[var]")
     ^
   arch/x86/include/asm/rmwcc.h:9:30: note: in expansion of macro 'GEN_BINARY_RMWcc_5'
    #define __RMWcc_CONCAT(a, b) a ## b
                                 ^
   arch/x86/include/asm/rmwcc.h:10:28: note: in expansion of macro '__RMWcc_CONCAT'
    #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
                               ^
   arch/x86/include/asm/rmwcc.h:60:32: note: in expansion of macro 'RMWcc_CONCAT'
    #define GEN_BINARY_RMWcc(X...) RMWcc_CONCAT(GEN_BINARY_RMWcc_, RMWcc_ARGS(X))(X)
                                   ^
   arch/x86/include/asm/qspinlock.h:18:6: note: in expansion of macro 'GEN_BINARY_RMWcc'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
         ^
   arch/x86/include/asm/rmwcc.h:25:1: note: previous definition of 'cc_label' was here
    cc_label: c = true;      \
    ^
   include/linux/compiler.h:58:30: note: in definition of macro '__trace_if'
     if (__builtin_constant_p(!!(cond)) ? !!(cond) :   \
                                 ^
   arch/x86/include/asm/qspinlock.h:18:2: note: in expansion of macro 'if'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
     ^
   arch/x86/include/asm/rmwcc.h:54:2: note: in expansion of macro '__GEN_RMWcc'
     __GEN_RMWcc(op " %[val], " arg0, var, cc,   \
     ^
   arch/x86/include/asm/rmwcc.h:58:2: note: in expansion of macro 'GEN_BINARY_RMWcc_6'
     GEN_BINARY_RMWcc_6(op, var, cc, vcon, val, "%[var]")
     ^
   arch/x86/include/asm/rmwcc.h:9:30: note: in expansion of macro 'GEN_BINARY_RMWcc_5'
    #define __RMWcc_CONCAT(a, b) a ## b
                                 ^
   arch/x86/include/asm/rmwcc.h:10:28: note: in expansion of macro '__RMWcc_CONCAT'
    #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
                               ^
   arch/x86/include/asm/rmwcc.h:60:32: note: in expansion of macro 'RMWcc_CONCAT'
    #define GEN_BINARY_RMWcc(X...) RMWcc_CONCAT(GEN_BINARY_RMWcc_, RMWcc_ARGS(X))(X)
                                   ^
   arch/x86/include/asm/qspinlock.h:18:6: note: in expansion of macro 'GEN_BINARY_RMWcc'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
         ^
>> arch/x86/include/asm/rmwcc.h:23:17: error: jump into statement expression
       : clobbers : cc_label);    \
                    ^
   include/linux/compiler.h:69:16: note: in definition of macro '__trace_if'
      ______r = !!(cond);     \
                   ^
   arch/x86/include/asm/qspinlock.h:18:2: note: in expansion of macro 'if'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
     ^
   arch/x86/include/asm/rmwcc.h:21:2: note: in expansion of macro 'asm_volatile_goto'
     asm_volatile_goto (fullop "; j" #cc " %l[cc_label]"  \
     ^
   arch/x86/include/asm/rmwcc.h:54:2: note: in expansion of macro '__GEN_RMWcc'
     __GEN_RMWcc(op " %[val], " arg0, var, cc,   \
     ^
   arch/x86/include/asm/rmwcc.h:58:2: note: in expansion of macro 'GEN_BINARY_RMWcc_6'
     GEN_BINARY_RMWcc_6(op, var, cc, vcon, val, "%[var]")
     ^
   arch/x86/include/asm/rmwcc.h:9:30: note: in expansion of macro 'GEN_BINARY_RMWcc_5'
    #define __RMWcc_CONCAT(a, b) a ## b
                                 ^
   arch/x86/include/asm/rmwcc.h:10:28: note: in expansion of macro '__RMWcc_CONCAT'
    #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
                               ^
   arch/x86/include/asm/rmwcc.h:60:32: note: in expansion of macro 'RMWcc_CONCAT'
    #define GEN_BINARY_RMWcc(X...) RMWcc_CONCAT(GEN_BINARY_RMWcc_, RMWcc_ARGS(X))(X)
                                   ^
   arch/x86/include/asm/qspinlock.h:18:6: note: in expansion of macro 'GEN_BINARY_RMWcc'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
         ^
   arch/x86/include/asm/rmwcc.h:25:1: note: label 'cc_label' defined here
    cc_label: c = true;      \
    ^
   include/linux/compiler.h:58:30: note: in definition of macro '__trace_if'
     if (__builtin_constant_p(!!(cond)) ? !!(cond) :   \
                                 ^
   arch/x86/include/asm/qspinlock.h:18:2: note: in expansion of macro 'if'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
     ^
   arch/x86/include/asm/rmwcc.h:54:2: note: in expansion of macro '__GEN_RMWcc'
     __GEN_RMWcc(op " %[val], " arg0, var, cc,   \
     ^
   arch/x86/include/asm/rmwcc.h:58:2: note: in expansion of macro 'GEN_BINARY_RMWcc_6'
     GEN_BINARY_RMWcc_6(op, var, cc, vcon, val, "%[var]")
     ^
   arch/x86/include/asm/rmwcc.h:9:30: note: in expansion of macro 'GEN_BINARY_RMWcc_5'
    #define __RMWcc_CONCAT(a, b) a ## b
                                 ^
   arch/x86/include/asm/rmwcc.h:10:28: note: in expansion of macro '__RMWcc_CONCAT'
    #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
                               ^
   arch/x86/include/asm/rmwcc.h:60:32: note: in expansion of macro 'RMWcc_CONCAT'
    #define GEN_BINARY_RMWcc(X...) RMWcc_CONCAT(GEN_BINARY_RMWcc_, RMWcc_ARGS(X))(X)
                                   ^
   arch/x86/include/asm/qspinlock.h:18:6: note: in expansion of macro 'GEN_BINARY_RMWcc'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
         ^
>> arch/x86/include/asm/rmwcc.h:25:1: error: duplicate label 'cc_label'
    cc_label: c = true;      \
    ^
   include/linux/compiler.h:69:16: note: in definition of macro '__trace_if'
      ______r = !!(cond);     \
                   ^
   arch/x86/include/asm/qspinlock.h:18:2: note: in expansion of macro 'if'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
     ^
   arch/x86/include/asm/rmwcc.h:54:2: note: in expansion of macro '__GEN_RMWcc'
     __GEN_RMWcc(op " %[val], " arg0, var, cc,   \
     ^
   arch/x86/include/asm/rmwcc.h:58:2: note: in expansion of macro 'GEN_BINARY_RMWcc_6'
     GEN_BINARY_RMWcc_6(op, var, cc, vcon, val, "%[var]")
     ^
   arch/x86/include/asm/rmwcc.h:9:30: note: in expansion of macro 'GEN_BINARY_RMWcc_5'
    #define __RMWcc_CONCAT(a, b) a ## b
                                 ^
   arch/x86/include/asm/rmwcc.h:10:28: note: in expansion of macro '__RMWcc_CONCAT'
    #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
                               ^
   arch/x86/include/asm/rmwcc.h:60:32: note: in expansion of macro 'RMWcc_CONCAT'
    #define GEN_BINARY_RMWcc(X...) RMWcc_CONCAT(GEN_BINARY_RMWcc_, RMWcc_ARGS(X))(X)
                                   ^
   arch/x86/include/asm/qspinlock.h:18:6: note: in expansion of macro 'GEN_BINARY_RMWcc'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
         ^
   arch/x86/include/asm/rmwcc.h:25:1: note: previous definition of 'cc_label' was here
    cc_label: c = true;      \
    ^
   include/linux/compiler.h:58:30: note: in definition of macro '__trace_if'
     if (__builtin_constant_p(!!(cond)) ? !!(cond) :   \
                                 ^
   arch/x86/include/asm/qspinlock.h:18:2: note: in expansion of macro 'if'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
     ^
   arch/x86/include/asm/rmwcc.h:54:2: note: in expansion of macro '__GEN_RMWcc'
     __GEN_RMWcc(op " %[val], " arg0, var, cc,   \
     ^
   arch/x86/include/asm/rmwcc.h:58:2: note: in expansion of macro 'GEN_BINARY_RMWcc_6'
     GEN_BINARY_RMWcc_6(op, var, cc, vcon, val, "%[var]")
     ^
   arch/x86/include/asm/rmwcc.h:9:30: note: in expansion of macro 'GEN_BINARY_RMWcc_5'
    #define __RMWcc_CONCAT(a, b) a ## b
                                 ^
   arch/x86/include/asm/rmwcc.h:10:28: note: in expansion of macro '__RMWcc_CONCAT'
    #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
                               ^
   arch/x86/include/asm/rmwcc.h:60:32: note: in expansion of macro 'RMWcc_CONCAT'
    #define GEN_BINARY_RMWcc(X...) RMWcc_CONCAT(GEN_BINARY_RMWcc_, RMWcc_ARGS(X))(X)
                                   ^
   arch/x86/include/asm/qspinlock.h:18:6: note: in expansion of macro 'GEN_BINARY_RMWcc'
     if (GEN_BINARY_RMWcc(LOCK_PREFIX "btsl", lock->val.counter, c,
         ^
   make[2]: *** [arch/x86/kernel/asm-offsets.s] Error 1
   make[2]: Target '__build' not remade because of errors.
   make[1]: *** [prepare0] Error 2
   make[1]: Target 'prepare' not remade because of errors.
   make: *** [sub-make] Error 2

vim +23 arch/x86/include/asm/rmwcc.h

288e4521 Peter Zijlstra 2018-10-03   8  
288e4521 Peter Zijlstra 2018-10-03   9  #define __RMWcc_CONCAT(a, b) a ## b
288e4521 Peter Zijlstra 2018-10-03 @10  #define RMWcc_CONCAT(a, b) __RMWcc_CONCAT(a, b)
288e4521 Peter Zijlstra 2018-10-03  11  
700b7c54 Jan Beulich    2018-02-19  12  #define __CLOBBERS_MEM(clb...)	"memory", ## clb
df340524 Kees Cook      2017-07-24  13  
ba741e35 H. Peter Anvin 2016-06-08  14  #if !defined(__GCC_ASM_FLAG_OUTPUTS__) && defined(CC_HAVE_ASM_GOTO)
ba741e35 H. Peter Anvin 2016-06-08  15  
ba741e35 H. Peter Anvin 2016-06-08  16  /* Use asm goto */
0c44c2d0 Peter Zijlstra 2013-09-11  17  
288e4521 Peter Zijlstra 2018-10-03  18  #define __GEN_RMWcc(fullop, _var, cc, clobbers, ...)			\
288e4521 Peter Zijlstra 2018-10-03  19  ({									\
288e4521 Peter Zijlstra 2018-10-03  20  	bool c = false;							\
18fe5822 H. Peter Anvin 2016-06-08  21  	asm_volatile_goto (fullop "; j" #cc " %l[cc_label]"		\
288e4521 Peter Zijlstra 2018-10-03  22  			: : [var] "m" (_var), ## __VA_ARGS__		\
df340524 Kees Cook      2017-07-24 @23  			: clobbers : cc_label);				\
288e4521 Peter Zijlstra 2018-10-03  24  	if (0) {							\
288e4521 Peter Zijlstra 2018-10-03 @25  cc_label:	c = true;						\
288e4521 Peter Zijlstra 2018-10-03  26  	}								\
288e4521 Peter Zijlstra 2018-10-03  27  	c;								\
288e4521 Peter Zijlstra 2018-10-03  28  })
0c44c2d0 Peter Zijlstra 2013-09-11  29  

:::::: The code at line 23 was first introduced by commit
:::::: df3405245a8535d2f20bcbdbb615385671cd0792 x86/asm: Add suffix macro for GEN_*_RMWcc()

:::::: TO: Kees Cook <keescook@chromium.org>
:::::: CC: Ingo Molnar <mingo@kernel.org>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 24934 bytes --]

             reply	other threads:[~2018-10-20  3:08 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-20  3:05 kbuild test robot [this message]
2018-10-22 10:08 ` [tip:locking/core 6/10] arch/x86/include/asm/rmwcc.h:23:17: error: jump into statement expression Peter Zijlstra
2018-10-22 10:22   ` Will Deacon

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=201810201105.YsnXEXTU%fengguang.wu@intel.com \
    --to=lkp@intel.com \
    --cc=kbuild-all@01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@kernel.org \
    --cc=peterz@infradead.org \
    --cc=tipbuild@zytor.com \
    --cc=will.deacon@arm.com \
    /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 NNTP newsgroup(s).