[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] memory: use signed arithmetic
From: |
Richard Henderson |
Subject: |
Re: [Qemu-devel] [PATCH] memory: use signed arithmetic |
Date: |
Tue, 02 Aug 2011 14:59:47 -0700 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20110707 Thunderbird/5.0 |
On 08/02/2011 01:50 PM, Avi Kivity wrote:
> struct AddrRange {
> - uint64_t start;
> - uint64_t size;
> + int64_t start;
> + int64_t size;
I'm must say I'm not keen on this. My primary objection is that
a "range" can no longer properly represent the entire address space.
Or, indeed, anything in the second half of it.
It sounds like your problem would be better solved by re-arranging
things such that you perform X < Y comparisons rather than DELTA < 0.
r~