Define the global vs. local variables, Operating System

Assignment Help:

Define the Global vs. local variables

It is also important to discuss the scope of resources being granted to the application program.  Variable scoping is defined as the accessibility of variables by application components.For instance variables may have local or global scope in single-threaded programs. Local variables can only be accessed within the boundaries of the procedure that defines them. Global variables, however, can be seen by the entire application. Variables are accessible over program components for which they are defined.

With the introduction of multithreaded programs, however, the scoping of variables changes. Some programs may want to share access to global information between separately executing processes. Mechanisms must be provided by the operating systems for such accessibility. It may also be necessary to have some data items globally accessible but on a per-thread basis. The following section on per-thread scoping deals with specific thread-level scoping issues.


Related Discussions:- Define the global vs. local variables

Define seek time and latency time, Define seek time and latency time. T...

Define seek time and latency time. The time taken by the head to move to the appropriate cylinder or track is known as seek time. Once the head is at right track, it must wait

What are the issues in designing a network, Normal 0 false fa...

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

Define the scheduling in multitasking, Define the Scheduling in Multitaskin...

Define the Scheduling in Multitasking Earlier we learned the concepts and advantages of multitasking. In a system in which one or more tasks( threads or processes) attempt to s

What is meant by the phrase thread-safe, The term thread-safe in computer p...

The term thread-safe in computer programming describes that routine or portion of the program that may be called from multiple programming threads without uncalled for interactions

What is scheduler, What is scheduler? A process migrates among the vari...

What is scheduler? A process migrates among the various scheduling queues throughout its life time. The OS must choose processes from these queues in some fashion. This selecti

Explain lru additional reference bits algorithm, Additional Reference bits...

Additional Reference bits algorithm Here we keep an 8-bit byte for every page in memory. At standard intervals the reference bit is shifted by the OS. If a shift register conta

Define deadlock prevention, Define deadlock prevention. Deadlock preve...

Define deadlock prevention. Deadlock prevention is a set of process for ensuring that at least one of the four essential conditions like mutual exclusion, hold and wait, no pr

Memory hierarchy, Difference between cache and associate memory

Difference between cache and associate memory

Explain disadvantages of the two-level directory, How do we overcome the di...

How do we overcome the disadvantages of the two-level directory? Give links from one user directory to another, creating path names; system files become available by letting th

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