2014-10-25 23:30 GMT+03:00 One Thousand Gnomes :
> On Fri, 24 Oct 2014 20:50:46 -0400
> Sasha Levin wrote:
>
>> On 10/24/2014 06:22 PM, H. Peter Anvin wrote:
>> >> By the principle of least surprise, I would expect "__u32 >> N", where
>> >> > N >= 32 to return zero instead of random garbage. For
On Fri, 24 Oct 2014 20:50:46 -0400
Sasha Levin wrote:
> On 10/24/2014 06:22 PM, H. Peter Anvin wrote:
> >> By the principle of least surprise, I would expect "__u32 >> N", where
> >> > N >= 32 to return zero instead of random garbage. For N < 32 it will
> >> > return progressively smaller number
On 10/24/2014 06:22 PM, H. Peter Anvin wrote:
>> By the principle of least surprise, I would expect "__u32 >> N", where
>> > N >= 32 to return zero instead of random garbage. For N < 32 it will
>> > return progressively smaller numbers, until it has shifted away all of
>> > the set bits, at which
On 10/24/2014 03:09 PM, Andreas Dilger wrote:
> On Oct 24, 2014, at 9:10 AM, Dmitry Vyukov wrote:
>> On Fri, Oct 24, 2014 at 7:04 PM, Sasha Levin wrote:
>>> On 10/24/2014 09:42 AM, Peter Zijlstra wrote:
On Fri, Oct 24, 2014 at 09:23:35AM -0400, Sasha Levin wrote:
>
> i >> 32 may happ
On 10/24/2014 02:05 PM, One Thousand Gnomes wrote:
> On Fri, 24 Oct 2014 19:10:49 +0400
> Dmitry Vyukov wrote:
>
>> On Fri, Oct 24, 2014 at 7:04 PM, Sasha Levin wrote:
>>> On 10/24/2014 09:42 AM, Peter Zijlstra wrote:
On Fri, Oct 24, 2014 at 09:23:35AM -0400, Sasha Levin wrote:
>
>
On Oct 24, 2014, at 9:10 AM, Dmitry Vyukov wrote:
> On Fri, Oct 24, 2014 at 7:04 PM, Sasha Levin wrote:
>> On 10/24/2014 09:42 AM, Peter Zijlstra wrote:
>>> On Fri, Oct 24, 2014 at 09:23:35AM -0400, Sasha Levin wrote:
i >> 32 may happen to be "i", but is there anything that prevents th
On Fri, 24 Oct 2014 19:10:49 +0400
Dmitry Vyukov wrote:
> On Fri, Oct 24, 2014 at 7:04 PM, Sasha Levin wrote:
> > On 10/24/2014 09:42 AM, Peter Zijlstra wrote:
> >> On Fri, Oct 24, 2014 at 09:23:35AM -0400, Sasha Levin wrote:
> >>>
> >>> i >> 32 may happen to be "i", but is there anything that p
On Fri, Oct 24, 2014 at 7:04 PM, Sasha Levin wrote:
> On 10/24/2014 09:42 AM, Peter Zijlstra wrote:
>> On Fri, Oct 24, 2014 at 09:23:35AM -0400, Sasha Levin wrote:
>>>
>>> i >> 32 may happen to be "i", but is there anything that prevents the
>>> compiler
>>> from returning, let's say, 42?
>>
>> N
On 10/24/2014 09:42 AM, Peter Zijlstra wrote:
> On Fri, Oct 24, 2014 at 09:23:35AM -0400, Sasha Levin wrote:
>>
>> i >> 32 may happen to be "i", but is there anything that prevents the
>> compiler
>> from returning, let's say, 42?
>
> Not really, although gcc seems to opt for the 'sane' option an
On Fri, Oct 24, 2014 at 09:23:35AM -0400, Sasha Levin wrote:
>
> i >> 32 may happen to be "i", but is there anything that prevents the compiler
> from returning, let's say, 42?
Not really, although gcc seems to opt for the 'sane' option and emit the
instruction and let the arch figure out how to
On 10/24/2014 06:01 AM, Peter Zijlstra wrote:
> On Mon, Oct 20, 2014 at 10:16:35AM -0400, Theodore Ts'o wrote:
>> > On Mon, Oct 20, 2014 at 04:09:30PM +0200, Daniel Borkmann wrote:
> > >
> > >It's triggering when input_rotate == 0, so UBSan complains about
> > >right shift in rol32(
On 10/24/2014 02:01 PM, Peter Zijlstra wrote:
> On Mon, Oct 20, 2014 at 10:16:35AM -0400, Theodore Ts'o wrote:
>> On Mon, Oct 20, 2014 at 04:09:30PM +0200, Daniel Borkmann wrote:
It's triggering when input_rotate == 0, so UBSan complains about right
shift in rol32()
static
On Mon, Oct 20, 2014 at 10:16:35AM -0400, Theodore Ts'o wrote:
> On Mon, Oct 20, 2014 at 04:09:30PM +0200, Daniel Borkmann wrote:
> > >
> > >It's triggering when input_rotate == 0, so UBSan complains about right
> > >shift in rol32()
> > >
> > >static inline __u32 rol32(__u32 word, unsigned int sh
On 10/20/2014 06:16 PM, Theodore Ts'o wrote:
> On Mon, Oct 20, 2014 at 04:09:30PM +0200, Daniel Borkmann wrote:
>>>
>>> It's triggering when input_rotate == 0, so UBSan complains about right
>>> shift in rol32()
>>>
>>> static inline __u32 rol32(__u32 word, unsigned int shift)
>>> {
>>> return
On Mon, Oct 20, 2014 at 04:09:30PM +0200, Daniel Borkmann wrote:
> >
> >It's triggering when input_rotate == 0, so UBSan complains about right shift
> >in rol32()
> >
> >static inline __u32 rol32(__u32 word, unsigned int shift)
> >{
> > return (word << shift) | (word >> (32 - shift));
> >}
>
On 10/20/2014 10:09 AM, Daniel Borkmann wrote:
> On 10/20/2014 03:58 PM, Andrey Ryabinin wrote:
>> On 10/20/2014 04:49 PM, Theodore Ts'o wrote:
>>> On Mon, Oct 20, 2014 at 03:03:22PM +0400, Andrey Ryabinin wrote:
Hi, Theodore.
I've got this while booting kernel with ubsan:
On Mon, Oct 20, 2014 at 05:58:25PM +0400, Andrey Ryabinin wrote:
> It's triggering when input_rotate == 0, so UBSan complains about right shift
> in rol32()
>
> static inline __u32 rol32(__u32 word, unsigned int shift)
> {
> return (word << shift) | (word >> (32 - shift));
> }
Ah, thanks;
On 10/20/2014 03:58 PM, Andrey Ryabinin wrote:
On 10/20/2014 04:49 PM, Theodore Ts'o wrote:
On Mon, Oct 20, 2014 at 03:03:22PM +0400, Andrey Ryabinin wrote:
Hi, Theodore.
I've got this while booting kernel with ubsan:
[0.00]
==
On 10/20/2014 04:49 PM, Theodore Ts'o wrote:
> On Mon, Oct 20, 2014 at 03:03:22PM +0400, Andrey Ryabinin wrote:
>> Hi, Theodore.
>>
>> I've got this while booting kernel with ubsan:
>>
>> [0.00]
>>
>>
On Mon, Oct 20, 2014 at 03:03:22PM +0400, Andrey Ryabinin wrote:
> Hi, Theodore.
>
> I've got this while booting kernel with ubsan:
>
> [0.00]
>
> [0.00] UBSan: Undefined behaviour in
> ../i
Hi, Theodore.
I've got this while booting kernel with ubsan:
[0.00]
[0.00] UBSan: Undefined behaviour in
../include/linux/bitops.h:107:33
[0.00] shift exponent 32 is to large for
21 matches
Mail list logo