From: kbuild test robot <lkp@intel.com>
To: Mark Rutland <mark.rutland@arm.com>
Cc: kbuild-all@01.org, linux-kernel@vger.kernel.org,
Mark Rutland <mark.rutland@arm.com>,
Ingo Molnar <mingo@redhat.com>,
Peter Zijlstra <peterz@infradead.org>,
Will Deacon <will.deacon@arm.com>
Subject: Re: [PATCH] perf/ring_buffer: ensure atomicity and order of updates
Date: Fri, 11 May 2018 09:19:52 +0800 [thread overview]
Message-ID: <201805110720.idFXdx2h%fengguang.wu@intel.com> (raw)
In-Reply-To: <20180510130632.34497-1-mark.rutland@arm.com>
[-- Attachment #1: Type: text/plain, Size: 10924 bytes --]
Hi Mark,
I love your patch! Perhaps something to improve:
[auto build test WARNING on tip/perf/core]
[also build test WARNING on v4.17-rc4 next-20180510]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Mark-Rutland/perf-ring_buffer-ensure-atomicity-and-order-of-updates/20180511-070205
config: i386-randconfig-s0-201818 (attached as .config)
compiler: gcc-6 (Debian 6.4.0-9) 6.4.0 20171026
reproduce:
# save the attached .config to linux build tree
make ARCH=i386
All warnings (new ones prefixed by >>):
In file included from include/uapi/linux/swab.h:6:0,
from include/linux/swab.h:5,
from include/uapi/linux/byteorder/little_endian.h:13,
from include/linux/byteorder/little_endian.h:5,
from arch/x86/include/uapi/asm/byteorder.h:5,
from include/uapi/linux/perf_event.h:20,
from include/linux/perf_event.h:17,
from kernel/events/ring_buffer.c:12:
kernel/events/ring_buffer.c: In function 'perf_output_put_handle':
include/linux/compiler.h:339:38: error: call to '__compiletime_assert_86' declared with attribute error: Need native word sized stores/loads for atomicity.
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^
include/linux/compiler.h:319:4: note: in definition of macro '__compiletime_assert'
prefix ## suffix(); \
^~~~~~
include/linux/compiler.h:339:2: note: in expansion of macro '_compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:342:2: note: in expansion of macro 'compiletime_assert'
compiletime_assert(__native_word(t), \
^~~~~~~~~~~~~~~~~~
>> arch/x86/include/asm/barrier.h:69:2: note: in expansion of macro 'compiletime_assert_atomic_type'
compiletime_assert_atomic_type(*p); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/barrier.h:157:33: note: in expansion of macro '__smp_store_release'
#define smp_store_release(p, v) __smp_store_release(p, v)
^~~~~~~~~~~~~~~~~~~
kernel/events/ring_buffer.c:86:2: note: in expansion of macro 'smp_store_release'
smp_store_release(&rb->user_page->data_head, head); /* B, matches C */
^~~~~~~~~~~~~~~~~
kernel/events/ring_buffer.c: In function 'perf_aux_output_skip':
include/linux/compiler.h:339:38: error: call to '__compiletime_assert_498' declared with attribute error: Need native word sized stores/loads for atomicity.
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^
include/linux/compiler.h:319:4: note: in definition of macro '__compiletime_assert'
prefix ## suffix(); \
^~~~~~
include/linux/compiler.h:339:2: note: in expansion of macro '_compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:342:2: note: in expansion of macro 'compiletime_assert'
compiletime_assert(__native_word(t), \
^~~~~~~~~~~~~~~~~~
>> arch/x86/include/asm/barrier.h:69:2: note: in expansion of macro 'compiletime_assert_atomic_type'
compiletime_assert_atomic_type(*p); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/barrier.h:157:33: note: in expansion of macro '__smp_store_release'
#define smp_store_release(p, v) __smp_store_release(p, v)
^~~~~~~~~~~~~~~~~~~
kernel/events/ring_buffer.c:498:2: note: in expansion of macro 'smp_store_release'
smp_store_release(&rb->user_page->aux_head, rb->aux_head);
^~~~~~~~~~~~~~~~~
kernel/events/ring_buffer.c: In function 'perf_aux_output_end':
include/linux/compiler.h:339:38: error: call to '__compiletime_assert_466' declared with attribute error: Need native word sized stores/loads for atomicity.
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^
include/linux/compiler.h:319:4: note: in definition of macro '__compiletime_assert'
prefix ## suffix(); \
^~~~~~
include/linux/compiler.h:339:2: note: in expansion of macro '_compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:342:2: note: in expansion of macro 'compiletime_assert'
compiletime_assert(__native_word(t), \
^~~~~~~~~~~~~~~~~~
>> arch/x86/include/asm/barrier.h:69:2: note: in expansion of macro 'compiletime_assert_atomic_type'
compiletime_assert_atomic_type(*p); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/barrier.h:157:33: note: in expansion of macro '__smp_store_release'
#define smp_store_release(p, v) __smp_store_release(p, v)
^~~~~~~~~~~~~~~~~~~
kernel/events/ring_buffer.c:466:2: note: in expansion of macro 'smp_store_release'
smp_store_release(&rb->user_page->aux_head, rb->aux_head);
^~~~~~~~~~~~~~~~~
--
In file included from include/uapi/linux/swab.h:6:0,
from include/linux/swab.h:5,
from include/uapi/linux/byteorder/little_endian.h:13,
from include/linux/byteorder/little_endian.h:5,
from arch/x86/include/uapi/asm/byteorder.h:5,
from include/uapi/linux/perf_event.h:20,
from include/linux/perf_event.h:17,
from kernel//events/ring_buffer.c:12:
kernel//events/ring_buffer.c: In function 'perf_output_put_handle':
include/linux/compiler.h:339:38: error: call to '__compiletime_assert_86' declared with attribute error: Need native word sized stores/loads for atomicity.
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^
include/linux/compiler.h:319:4: note: in definition of macro '__compiletime_assert'
prefix ## suffix(); \
^~~~~~
include/linux/compiler.h:339:2: note: in expansion of macro '_compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:342:2: note: in expansion of macro 'compiletime_assert'
compiletime_assert(__native_word(t), \
^~~~~~~~~~~~~~~~~~
>> arch/x86/include/asm/barrier.h:69:2: note: in expansion of macro 'compiletime_assert_atomic_type'
compiletime_assert_atomic_type(*p); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/barrier.h:157:33: note: in expansion of macro '__smp_store_release'
#define smp_store_release(p, v) __smp_store_release(p, v)
^~~~~~~~~~~~~~~~~~~
kernel//events/ring_buffer.c:86:2: note: in expansion of macro 'smp_store_release'
smp_store_release(&rb->user_page->data_head, head); /* B, matches C */
^~~~~~~~~~~~~~~~~
kernel//events/ring_buffer.c: In function 'perf_aux_output_skip':
include/linux/compiler.h:339:38: error: call to '__compiletime_assert_498' declared with attribute error: Need native word sized stores/loads for atomicity.
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^
include/linux/compiler.h:319:4: note: in definition of macro '__compiletime_assert'
prefix ## suffix(); \
^~~~~~
include/linux/compiler.h:339:2: note: in expansion of macro '_compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:342:2: note: in expansion of macro 'compiletime_assert'
compiletime_assert(__native_word(t), \
^~~~~~~~~~~~~~~~~~
>> arch/x86/include/asm/barrier.h:69:2: note: in expansion of macro 'compiletime_assert_atomic_type'
compiletime_assert_atomic_type(*p); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/barrier.h:157:33: note: in expansion of macro '__smp_store_release'
#define smp_store_release(p, v) __smp_store_release(p, v)
^~~~~~~~~~~~~~~~~~~
kernel//events/ring_buffer.c:498:2: note: in expansion of macro 'smp_store_release'
smp_store_release(&rb->user_page->aux_head, rb->aux_head);
^~~~~~~~~~~~~~~~~
kernel//events/ring_buffer.c: In function 'perf_aux_output_end':
include/linux/compiler.h:339:38: error: call to '__compiletime_assert_466' declared with attribute error: Need native word sized stores/loads for atomicity.
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^
include/linux/compiler.h:319:4: note: in definition of macro '__compiletime_assert'
prefix ## suffix(); \
^~~~~~
include/linux/compiler.h:339:2: note: in expansion of macro '_compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __LINE__)
^~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:342:2: note: in expansion of macro 'compiletime_assert'
compiletime_assert(__native_word(t), \
^~~~~~~~~~~~~~~~~~
>> arch/x86/include/asm/barrier.h:69:2: note: in expansion of macro 'compiletime_assert_atomic_type'
compiletime_assert_atomic_type(*p); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> include/asm-generic/barrier.h:157:33: note: in expansion of macro '__smp_store_release'
#define smp_store_release(p, v) __smp_store_release(p, v)
^~~~~~~~~~~~~~~~~~~
kernel//events/ring_buffer.c:466:2: note: in expansion of macro 'smp_store_release'
smp_store_release(&rb->user_page->aux_head, rb->aux_head);
^~~~~~~~~~~~~~~~~
vim +/compiletime_assert_atomic_type +69 arch/x86/include/asm/barrier.h
47933ad4 Peter Zijlstra 2013-11-06 66
1638fb72 Michael S. Tsirkin 2015-12-27 67 #define __smp_store_release(p, v) \
47933ad4 Peter Zijlstra 2013-11-06 68 do { \
47933ad4 Peter Zijlstra 2013-11-06 @69 compiletime_assert_atomic_type(*p); \
47933ad4 Peter Zijlstra 2013-11-06 70 barrier(); \
76695af2 Andrey Konovalov 2015-08-02 71 WRITE_ONCE(*p, v); \
47933ad4 Peter Zijlstra 2013-11-06 72 } while (0)
47933ad4 Peter Zijlstra 2013-11-06 73
:::::: The code at line 69 was first introduced by commit
:::::: 47933ad41a86a4a9b50bed7c9b9bd2ba242aac63 arch: Introduce smp_load_acquire(), smp_store_release()
:::::: TO: Peter Zijlstra <peterz@infradead.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: 35777 bytes --]
next prev parent reply other threads:[~2018-05-11 1:20 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-10 13:06 [PATCH] perf/ring_buffer: ensure atomicity and order of updates Mark Rutland
2018-05-11 1:19 ` kbuild test robot
2018-05-11 1:19 ` kbuild test robot [this message]
2018-05-11 10:59 ` Mark Rutland
2018-05-11 16:22 ` Peter Zijlstra
2018-05-14 11:05 ` Mark Rutland
2018-05-14 11:28 ` Peter Zijlstra
2018-05-14 15:02 ` Peter Zijlstra
2018-05-14 15:20 ` Mark Rutland
2018-05-14 15:24 ` Peter Zijlstra
2018-05-23 16:42 ` 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=201805110720.idFXdx2h%fengguang.wu@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--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).