GPIB system and method which allows multiple thread access to global variables
AssigneeNational Instruments Corporation
InventorsClay Bean, Mike Hall
Life of this patent
Estimating the term…
Loading patent…
AssigneeNational Instruments Corporation
InventorsClay Bean, Mike Hall
Estimating the term…
A system and method which enables a plurality of threads in a multithreaded application to each access per-thread copies of GPIB global variables in a GPIB system. According to the present invention, the plurality of threads use a special set of thread-local GPIB calls to perform the per-thread accesses. Whenever a thread first makes a GPIB call, the GPIB driver software begins maintaining a private copy of all of the GPIB global variables for the respective thread. The driver preferably maintains a separate private copy for each thread. Later, when the thread desires to access a per-thread copy of one or more global variables, the thread uses a thread-local GPIB call to perform the per-thread access. The thread-local functions used to access these per-thread GPIB global variables are ThreadIbsta, ThreadIberr, ThreadIbcnt, and ThreadIbcntl. When the GPIB driver level software receives a call to a thread-local function to access a per-thread global variable, the software determines the appropriate value for the respective thread and returns the per-thread value to the respective requesting thread. In one embodiment, the thread can specify a memory area where the per-thread global variables are maintained. In this manner, the thread can access the per-thread global variables directly from the specified memory area, without having to make thread-local function calls.
A method of accessing global variables from multiple threads in a GPIB system, wherein the system comprises a GPIB application which interfaces through GPIB driver software to a GPIB device, wherein the GPIB application and the GPIB driver software execute on a computer system, wherein the GPIB application includes a plurality of threads, the method comprising:
A method of accessing global variables from multiple threads in a GPIB system, wherein the system comprises a GPIB application which interfaces through GPIB driver software to a GPIB device, wherein the GPIB application and the GPIB driver software execute on a computer system, wherein the GPIB application includes a plurality of threads, the method comprising:
A GPIB system which enables multiple threads in a GPIB application to safely access global variables, the GPIB system comprising:
A memory media which stores program instructions for accessing global variables from multiple threads in a GPIB system, wherein the system comprises a GPIB application which interfaces through GPIB driver software to a GPIB device, wherein the GPIB application and the GPIB driver software execute on a computer system, wherein the GPIB application includes a plurality of threads, wherein the program instructions are executable to implement the steps of:
Dependencies are inferred from the claim text.