qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] bcm2835_property: use cached values when queryi


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH] bcm2835_property: use cached values when querying framebuffer
Date: Mon, 9 May 2016 12:27:50 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.1


On 22/04/2016 13:30, Andrew Baumann wrote:
>> From: Sylvain Garrigues [mailto:address@hidden
>> Sent: Friday, 22 April 2016 13:27
>>
>> Le 22 avr. 2016 à 13:22, Andrew Baumann
>> <address@hidden> a écrit :
>>>> +            stl_le_phys(&s->dma_as, value + 16, tmp_xres * tmp_yres
>>>> + * (tmp_bpp >> 3));
>>>
>>> Personal style nit: I prefer * 8 rather than >> 3, because it's more 
>>> immediately
>> obvious what you're computing, a trivial optimisation for the compiler

Note that it's only trivial for unsigned dividend.  A signed dividend
has >> rounding towards -infinity and / rounding towards zero.

Paolo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]