|
|
static void | usage (void) |
| | print program usage help
|
| |
| static int | read_header (FILE *in) |
| | read header entry. More...
|
| |
|
static int | readup_str (char **str, FILE *in) |
| | read a string from file, false on error
|
| |
|
static void | read_create (rbtree_type *all, FILE *in) |
| | read creation entry
|
| |
|
static struct order_lock * | insert_lock (rbtree_type *all, struct order_id *id) |
| | insert lock entry (empty) into list
|
| |
|
static void | read_lock (rbtree_type *all, FILE *in, int val) |
| | read lock entry
|
| |
|
static void | readinput (rbtree_type *all, char *file) |
| | read input file
|
| |
|
static void | found_cycle (struct lock_ref *visit, int level) |
| | print cycle message
|
| |
|
static int | detect_cycle (struct lock_ref *visit, struct lock_ref *from) |
| | Detect cycle by comparing visited now with all (unvisited) bigger nodes.
|
| |
| static void | search_cycle (struct lock_ref *visit, int level, struct lock_ref *from) |
| | recursive function to depth first search for cycles. More...
|
| |
|
static void | check_order_lock (struct order_lock *lock) |
| | Check ordering of one lock.
|
| |
|
static void | check_order (rbtree_type *all_locks) |
| | Check ordering of locks.
|
| |
|
int | main (int argc, char *argv[]) |
| | main program to verify all traces passed
|
| |
This file checks the lock traces generated by checklock.c. Checks if locks are consistently locked in the same order. If not, this can lead to deadlock if threads execute the different ordering at the same time.