mirror of
https://github.com/ziglang/zig.git
synced 2024-11-15 16:45:27 +00:00
509639717a
The current implementation of `equalRange` just calls `lowerRange` and `upperRange`, but a lot of
the work done by these two functions can be shared. Specifically, each iteration gives information about whether the lower bound or the upper bound can be tightened. This leads to fewer iterations and, since there is one comparison per iteration, fewer comparisons.
Implementation adapted from [GCC](
|
||
---|---|---|
.. | ||
Build | ||
c | ||
compress | ||
crypto | ||
debug | ||
dwarf | ||
fmt | ||
fs | ||
hash | ||
heap | ||
http | ||
io | ||
json | ||
math | ||
mem | ||
meta | ||
net | ||
os | ||
posix | ||
process | ||
Random | ||
sort | ||
tar | ||
Target | ||
testing | ||
Thread | ||
time | ||
tz | ||
unicode | ||
valgrind | ||
zig | ||
zip | ||
array_hash_map.zig | ||
array_list.zig | ||
ascii.zig | ||
atomic.zig | ||
base64.zig | ||
bit_set.zig | ||
BitStack.zig | ||
bounded_array.zig | ||
buf_map.zig | ||
buf_set.zig | ||
Build.zig | ||
builtin.zig | ||
c.zig | ||
coff.zig | ||
compress.zig | ||
crypto.zig | ||
debug.zig | ||
dwarf.zig | ||
dynamic_library.zig | ||
elf.zig | ||
enums.zig | ||
fifo.zig | ||
fmt.zig | ||
fs.zig | ||
gpu.zig | ||
hash_map.zig | ||
hash.zig | ||
heap.zig | ||
http.zig | ||
io.zig | ||
json.zig | ||
leb128.zig | ||
linked_list.zig | ||
log.zig | ||
macho.zig | ||
math.zig | ||
mem.zig | ||
meta.zig | ||
multi_array_list.zig | ||
net.zig | ||
once.zig | ||
os.zig | ||
packed_int_array.zig | ||
pdb.zig | ||
posix.zig | ||
priority_dequeue.zig | ||
priority_queue.zig | ||
process.zig | ||
Progress.zig | ||
Random.zig | ||
RingBuffer.zig | ||
segmented_list.zig | ||
SemanticVersion.zig | ||
simd.zig | ||
sort.zig | ||
start.zig | ||
static_string_map.zig | ||
std.zig | ||
tar.zig | ||
Target.zig | ||
testing.zig | ||
Thread.zig | ||
time.zig | ||
treap.zig | ||
tz.zig | ||
unicode.zig | ||
Uri.zig | ||
valgrind.zig | ||
wasm.zig | ||
zig.zig | ||
zip.zig |