Explain the thread local storage (tls), Operating System

Assignment Help:

Explain the Thread Local Storage (TLS)   

Windows NT provides unique functions for per-thread data management. Thread local storage (TLS) is a concept defined in NT so developers can manage global data independently for each thread. Generally, a mechanism is provided for setting and getting the thread local storage for each thread. Upon process or DLL initialization thread local storage must be initializes via the TlsAllocFunction. This process allocates a TLS table and returns a TLS index that is used with all other TLS functions.

Once initialized, each subsequently created thread would typically allocate memory and save the memory pointer on a per-thread basis. TlsSetValue( ) is used to associate a data pointer with the calling thread. Subsequent access to that thread data would be available via the TlsGetValue( ) function call. When all threads are done with per-thread data management, TlsFree( ) should be issued to release the TLS index.

 


Related Discussions:- Explain the thread local storage (tls)

Write a short note on the linux file systems, Question: (a) Red Hat Li...

Question: (a) Red Hat Linux is distributed under the Open Source agreement. Explain what you understand by Open Source distribution system. (b) Write a short note on the L

Explain gui based operating system, GUI - Short for Graphical User Interfa...

GUI - Short for Graphical User Interface a GUI Operating System contains icons and graphics and is commonly navigated by using a computer mouse. Below are some instances of GUI Op

Linux, how to find ncr value in shell script

how to find ncr value in shell script

How is a process chosen for being swapped either in or out?, How is a proce...

How is a process chosen for being swapped either in or out? Swap out: a.         If the process is idle. b.         If process has been in main memory for a long time.

What are the three main activities of an operating system, What are the thr...

What are the three main activities of an operating system in regard to memory management? Keep track of which parts of memory are now being used and by whom. Decide which pr

Process, what common event leads to the creation of a process?

what common event leads to the creation of a process?

Explain the resource ownership by platform, Explain the Resource Ownership ...

Explain the Resource Ownership by Platform Ownership of data items may further be complicated by concepts defined in certain operating systems. Each operating system defines "p

Malloc, I need help implementing malloc

I need help implementing malloc

Explain the thread contextual data, Explain the Thread Contextual Data  ...

Explain the Thread Contextual Data  Threads in Net Ware carry additional context as well. Per-thread, stacks, errno, Net Ware Errno, t_errno and others are available to the ap

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd