Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-05-02 Thread Yonghong Song
Hi, Peter, Ping again. Did you get chances to think about this issue again? Thanks! Yonghong On 4/27/18 9:34 AM, Yonghong Song wrote: Hi, Peter, Just wanted to ping again so that you did not miss the email below. Please let me know your opinion. Thanks! Yonghong On 4/23/18 9:50 AM,

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-05-02 Thread Yonghong Song
Hi, Peter, Ping again. Did you get chances to think about this issue again? Thanks! Yonghong On 4/27/18 9:34 AM, Yonghong Song wrote: Hi, Peter, Just wanted to ping again so that you did not miss the email below. Please let me know your opinion. Thanks! Yonghong On 4/23/18 9:50 AM,

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-27 Thread Yonghong Song
Hi, Peter, Just wanted to ping again so that you did not miss the email below. Please let me know your opinion. Thanks! Yonghong On 4/23/18 9:50 AM, Yonghong Song wrote: Hi, Peter, Please see comments below. On 4/23/18 3:52 AM, Peter Zijlstra wrote: On Fri, Apr 20, 2018 at 11:06:03AM

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-27 Thread Yonghong Song
Hi, Peter, Just wanted to ping again so that you did not miss the email below. Please let me know your opinion. Thanks! Yonghong On 4/23/18 9:50 AM, Yonghong Song wrote: Hi, Peter, Please see comments below. On 4/23/18 3:52 AM, Peter Zijlstra wrote: On Fri, Apr 20, 2018 at 11:06:03AM

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-23 Thread Yonghong Song
Hi, Peter, Please see comments below. On 4/23/18 3:52 AM, Peter Zijlstra wrote: On Fri, Apr 20, 2018 at 11:06:03AM -0700, Yonghong Song wrote: On 4/20/18 1:19 AM, Peter Zijlstra wrote: Hurm, so adding __BPF__ for BPF compiles isn't an option? It seems to me having a CPP flag to identify

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-23 Thread Yonghong Song
Hi, Peter, Please see comments below. On 4/23/18 3:52 AM, Peter Zijlstra wrote: On Fri, Apr 20, 2018 at 11:06:03AM -0700, Yonghong Song wrote: On 4/20/18 1:19 AM, Peter Zijlstra wrote: Hurm, so adding __BPF__ for BPF compiles isn't an option? It seems to me having a CPP flag to identify

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-23 Thread Peter Zijlstra
On Fri, Apr 20, 2018 at 11:06:03AM -0700, Yonghong Song wrote: > On 4/20/18 1:19 AM, Peter Zijlstra wrote: > > Hurm, so adding __BPF__ for BPF compiles isn't an option? It seems to me > > having a CPP flag to identify BPF compile context might be useful in > > general. > > With "clang -target

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-23 Thread Peter Zijlstra
On Fri, Apr 20, 2018 at 11:06:03AM -0700, Yonghong Song wrote: > On 4/20/18 1:19 AM, Peter Zijlstra wrote: > > Hurm, so adding __BPF__ for BPF compiles isn't an option? It seems to me > > having a CPP flag to identify BPF compile context might be useful in > > general. > > With "clang -target

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-20 Thread Yonghong Song
On 4/20/18 1:19 AM, Peter Zijlstra wrote: On Sat, Apr 14, 2018 at 09:27:38PM -0700, Yonghong Song wrote: This patch adds a preprocessor guard NO_BPF_WORKAROUND around the asm_volatile_goto based static_cpu_has(). NO_BPF_WORKAROUND is set at toplevel Makefile when compiler supports asm-goto.

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-20 Thread Yonghong Song
On 4/20/18 1:19 AM, Peter Zijlstra wrote: On Sat, Apr 14, 2018 at 09:27:38PM -0700, Yonghong Song wrote: This patch adds a preprocessor guard NO_BPF_WORKAROUND around the asm_volatile_goto based static_cpu_has(). NO_BPF_WORKAROUND is set at toplevel Makefile when compiler supports asm-goto.

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-20 Thread Peter Zijlstra
On Sat, Apr 14, 2018 at 09:27:38PM -0700, Yonghong Song wrote: > This patch adds a preprocessor guard NO_BPF_WORKAROUND around the > asm_volatile_goto based static_cpu_has(). NO_BPF_WORKAROUND is set > at toplevel Makefile when compiler supports asm-goto. That is, > if the compiler supports

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-20 Thread Peter Zijlstra
On Sat, Apr 14, 2018 at 09:27:38PM -0700, Yonghong Song wrote: > This patch adds a preprocessor guard NO_BPF_WORKAROUND around the > asm_volatile_goto based static_cpu_has(). NO_BPF_WORKAROUND is set > at toplevel Makefile when compiler supports asm-goto. That is, > if the compiler supports

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-19 Thread Yonghong Song
Hi, Peter, Just pinging. Did you get chances to look at this? [ cc netdev as well so folks are aware of the issue. ] Thanks! Yonghong On 4/14/18 9:27 PM, Yonghong Song wrote: Commit d0266046ad54 ("x86: Remove FAST_FEATURE_TESTS") removed X86_FAST_FEATURE_TESTS and make macro

Re: [PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-19 Thread Yonghong Song
Hi, Peter, Just pinging. Did you get chances to look at this? [ cc netdev as well so folks are aware of the issue. ] Thanks! Yonghong On 4/14/18 9:27 PM, Yonghong Song wrote: Commit d0266046ad54 ("x86: Remove FAST_FEATURE_TESTS") removed X86_FAST_FEATURE_TESTS and make macro

[PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-14 Thread Yonghong Song
Commit d0266046ad54 ("x86: Remove FAST_FEATURE_TESTS") removed X86_FAST_FEATURE_TESTS and make macro static_cpu_has() always use __always_inline function _static_cpu_has() funciton. The static_cpu_has() uses gcc feature asm_volatile_goto construct, which is not supported by clang. Currently, for

[PATCH v2] x86/cpufeature: guard asm_volatile_goto usage with NO_BPF_WORKAROUND

2018-04-14 Thread Yonghong Song
Commit d0266046ad54 ("x86: Remove FAST_FEATURE_TESTS") removed X86_FAST_FEATURE_TESTS and make macro static_cpu_has() always use __always_inline function _static_cpu_has() funciton. The static_cpu_has() uses gcc feature asm_volatile_goto construct, which is not supported by clang. Currently, for