Richard Biener writes:
> On August 21, 2017 5:43:08 PM GMT+02:00, Aldy Hernandez
> wrote:
>>The attached patch fixes the problem by sign extending before
>>constructing the wide int. It does so while constructing the
>>hwi_with_prec object, since the int_traits
>>container has is_sign_extended
On August 21, 2017 5:43:08 PM GMT+02:00, Aldy Hernandez
wrote:
>The attached patch fixes the problem by sign extending before
>constructing the wide int. It does so while constructing the
>hwi_with_prec object, since the int_traits
>container has is_sign_extended=true, so I assume the underlyi
The attached patch fixes the problem by sign extending before
constructing the wide int. It does so while constructing the
hwi_with_prec object, since the int_traits
container has is_sign_extended=true, so I assume the underlying
hwi_with_prec must be stored with sign extension.
Is this what yo
On August 20, 2017 10:46:54 AM GMT+02:00, Aldy Hernandez
wrote:
>Hi folks.
>
>Calling wi::max_value() of a boolean_type creates a wide_int with all
>bits set, not just the least significant bit.
>
>tree type = boolean_type_node;
>wide_int x = wi::max_value (TYPE_PRECISION (type), TYPE_SIGN (type
Hi folks.
Calling wi::max_value() of a boolean_type creates a wide_int with all
bits set, not just the least significant bit.
tree type = boolean_type_node;
wide_int x = wi::max_value (TYPE_PRECISION (type), TYPE_SIGN (type));
(gdb) print x.dump()
[0x], precision = 1
However,