Method and tool for determining ownership of a multiple owner lock in multithreading environments
First Claim
1. A computer-based method for determining an owner of a lock on a shared resource in a computer system, comprising:
- receiving a core file generated in the computer system providing state information for memory in the computer system including stack information for threads in the computer system; and
processing the core file for the computer system to generate a list of potential owners of the lock, wherein the lock is configured for multiple ownership with a kernel for the computer system not storing lock ownership information for the lock and wherein the potential owners are the threads in the computer system and the processing includes locating in the stack information for each owner a pointer to the lock.
2 Assignments
0 Petitions
Accused Products
Abstract
A method for determining an ownership of for a multiple owner lock. The method includes determining potential owners of the lock by inspecting a core file of a computer system or memory of a live system to determine which threads have pointers to the lock. The method includes identifying a stack for the threads with a stack pointer pointing to the current active frame and dividing the stack into active and inactive portions. The stack information is examined for each potential owner of the lock for pointers to the lock. If the thread has a pointer to the lock in the inactive portion of the stack, the thread is removed from the set of potential owners. The method includes retrieving a waiting list for the lock, and any threads on the waiting list are removed from the set of potential owners.
50 Citations
20 Claims
-
1. A computer-based method for determining an owner of a lock on a shared resource in a computer system, comprising:
-
receiving a core file generated in the computer system providing state information for memory in the computer system including stack information for threads in the computer system; and
processing the core file for the computer system to generate a list of potential owners of the lock, wherein the lock is configured for multiple ownership with a kernel for the computer system not storing lock ownership information for the lock and wherein the potential owners are the threads in the computer system and the processing includes locating in the stack information for each owner a pointer to the lock. - View Dependent Claims (2, 3, 4, 5, 6, 7)
-
-
8. A method of determining prior ownership in a computer system of a lock to a resource shared by threads of execution, comprising:
-
retrieving a set of the threads identified as potential prior owners of the lock;
identifying a stack for the each of the identified threads that is maintained by a processor in the computer system;
determining an active and an inactive portion of each of the thread stacks based on a stack pointer; and
for each of the threads, identifying a location in the thread stack of a pointer to the lock;
determining for each of the threads whether the location of the pointer to the lock is in the active or the inactive portion of the thread stack; and
removing the threads in the set that have the pointer to the lock in the inactive portion of the thread stack. - View Dependent Claims (9, 10, 11)
-
-
12. A computer-based method for determining lock ownership in a multithreading operating system, comprising:
-
retrieving a core file for a computer system;
processing the core file to create a set of threads of execution determined to be potential owners of a lock to a resource shared by the threads;
locating a waiting list for ownership to the lock including threads waiting to own the lock; and
removing all of the waiting threads from the set of potential owner threads. - View Dependent Claims (13, 14, 15, 16)
-
-
17. A computer readable medium, comprising:
-
computer readable program code devices configured to cause a computer to effect generating a set of potential owners of a lock to a system resource including threads of execution determined to have a pointer to the lock, wherein the lock is configured for multiple ownership and a kernel associated with the lock does not store lock ownership information for the lock;
computer readable program code devices configured to cause a computer to effect retrieving a set of threads waiting for ownership of the lock; and
computer readable program code devices configured to cause a computer to effect removing any of the waiting threads from the set of potential owner threads. - View Dependent Claims (18, 19, 20)
-
Specification