Add signature for atomic fetch/store uintptr_t.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Add signature for atomic fetch/store void *.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Weakref.  Use atomic fetch/store for cached lookups.

The caller holds only a non-exclusive lock, which isn't
sufficient to update the cache.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Dont need atomic update when XLOCK.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
No more Mr. BadHash.

Introduce a new intrusive, AVL-based file handle to cache
entry lookups.

The new dictionary remains a tree keyed on 64-bit hash of
file handle, with fallback to bitwise handle comparison, the
following details are changed:

* AVL linkage is intrusive, no consing of opaque buffers
* all hashing is by the 64-bit CityHash, no exceptions

Signed-off-by: Matt Benjamin <matt@linuxbox.com>

Conflicts:
	src/Cache_inode/cache_inode_hash.c
	src/Cache_inode/cache_inode_misc.c
	src/include/cache_inode_hash.h

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Suppress unused result warning in print_debug_info_fd.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Force entries in LRU CQ or KILLED also !LRU (and !PINNED)

The correct change appears to be simply to call lru_remove_entry
on entries being scheduled for cleanup (having already prevented
further pins or references.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Use safe iterator (rather than restart) in lru per-lane processing.

This is the natural model, since we need to avoid
reprocessing entries (altogether).  For extra safety, count
the entries we do ignore as work performed.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Reduce default lru_run_interval to 60s.

Signed-off-by: Matt Benjamin <matt@linuxbox.com>
Make cache_inode_lru_unref handle entries not in queue

Signed-off-by: Adam C. Emerson <aemerson@linuxbox.com>