wget-dev
[Top][All Lists]
Advanced

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

Re: wget2 | Draft: CIDR support added for No Proxy. Testing Code Added (


From: @rockdaboot
Subject: Re: wget2 | Draft: CIDR support added for No Proxy. Testing Code Added (!521)
Date: Mon, 10 Apr 2023 09:15:05 +0000



Tim Rühsen commented:


Accessing a not cached piece of memory can easily take 50x longer than doing 
shift+not, so a hand-crafted map is normally inferior. Whenever you have a 
choice between two implementations where one has a big variance in latency and 
the other is constant time, chose the latter (well, given that both are roughly 
equally in average).
The implicit conversion is easily fixed with an explicit conversion:
```
        uint32_t mask = (uint32_t) ~(0xFFFFFFFFLU >> prefix_len);
```
The test error is on 32bit systems where `long unsigned` is 32bit. Sorry, that 
was me not having thought about it.
The fix is to use `0xFFFFFFFFLLU`, which is always 64bit.

I pushed these changes to your branch to see how the CI behaves. Do a `git 
pull` to fetch the commit.

-- 
Reply to this email directly or view it on GitLab: 
https://gitlab.com/gnuwget/wget2/-/merge_requests/521#note_1346519028
You're receiving this email because of your account on gitlab.com.




reply via email to

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