-
Notifications
You must be signed in to change notification settings - Fork 253
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix locking errors in streaming code (#214)
* report number of process_delete calls in consolidation_report * correct locking comments * convert _delete_set member in index class to a unique_ptr * Add shared delete_lock to process_delete; move adj list lock inside process_delete * insert acqires exclusive delete_lock before calling reserve_location(); change comments on locking requirements for calling reserve_location() * In search_for_points_and_add_links(), remove unnecessary checks of pool against delete_set. The function already checks the final results against _location_to_tag * Copy by reference when scratch spaces are returned * use reference to iterate over vector when modifying it's contents * minor changes to help compiler optimize * acquire shared delete lock to check delete set size * change locking in process_delete to avoid deadlock * remove _lazy_done member from Index class. It can be inferred from _delete_set.size() * Add locks to compact_data; remove _delete_set->clear since it's supposed to be empty here; use iterators to renumber edges * In process_delete, clear _final_graph[loc] before passing as output buffer to occlude_list * Use a set to collect unique nodes for candidate pool to pass to occlude_list * throw an exception if conslidate_delete or compact_data finds that the _start node has been deleted * add shared locks to print_status in Index class * fix to check on deleted start point * acquire tag and delete lock in enable delete * In process_delete, renamed iterator variable and conditioned the call to occlude_list on the candidate pool being larger than R * In process_delete, acquire lock on adj list before clearing it * Refactor protected member search_for_points_and_add_links so that tag_lock is moved to public functions * acquire _locks[loc] later in process_delete control flow * pre-allocating scratch space needed in process_delete
- Loading branch information
1 parent
032cab4
commit 351bf79
Showing
4 changed files
with
307 additions
and
213 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.