ibm-information-center/dist/eclipse/plugins/i5OS.ic.rzahw_5.4.0.1/rzahwsafco.htm

78 lines
5.9 KiB
HTML

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html lang="en-us" xml:lang="en-us">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="security" content="public" />
<meta name="Robots" content="index,follow" />
<meta http-equiv="PICS-Label" content='(PICS-1.1 "http://www.icra.org/ratingsv02.html" l gen true r (cz 1 lz 1 nz 1 oz 1 vz 1) "http://www.rsac.org/ratingsv01.html" l gen true r (n 0 s 0 v 0 l 0) "http://www.classify.org/safesurf/" l gen true r (SS~~000 1))' />
<meta name="DC.Type" content="concept" />
<meta name="DC.Title" content="Thread safety" />
<meta name="abstract" content="A function is threadsafe if you can start it simultaneously in multiple threads within the same process. A function is threadsafe if and only if all the functions it calls are also threadsafe." />
<meta name="description" content="A function is threadsafe if you can start it simultaneously in multiple threads within the same process. A function is threadsafe if and only if all the functions it calls are also threadsafe." />
<meta name="DC.Relation" scheme="URI" content="rzahwovepo.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwstoco.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwjreco.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwapico.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwclcco.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwdafco.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwexico.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwgrxco.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwnonco.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwevaco.htm" />
<meta name="DC.Relation" scheme="URI" content="rzahwgrxco.htm" />
<meta name="copyright" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Rights.Owner" content="(C) Copyright IBM Corporation 1998, 2006" />
<meta name="DC.Format" content="XHTML" />
<meta name="DC.Identifier" content="rzahwsaf-safco" />
<meta name="DC.Language" content="en-us" />
<!-- All rights reserved. Licensed Materials Property of IBM -->
<!-- US Government Users Restricted Rights -->
<!-- Use, duplication or disclosure restricted by -->
<!-- GSA ADP Schedule Contract with IBM Corp. -->
<link rel="stylesheet" type="text/css" href="./ibmdita.css" />
<link rel="stylesheet" type="text/css" href="./ic.css" />
<title>Thread safety</title>
</head>
<body id="rzahwsaf-safco"><a name="rzahwsaf-safco"><!-- --></a>
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
<h1 class="topictitle1">Thread safety</h1>
<div><p>A function is threadsafe if you can start it simultaneously in
multiple threads within the same process. A function is threadsafe if and
only if all the functions it calls are also threadsafe.</p>
</div>
<div>
<ul class="ullinks">
<li class="ulchildlink"><strong><a href="rzahwstoco.htm">Storage usage and threaded applications</a></strong><br />
When writing a threaded application, it is important to understand the visibility and scope of various classes of storage.</li>
<li class="ulchildlink"><strong><a href="rzahwjreco.htm">Job-scoped resources and thread safety</a></strong><br />
Many system and application resources are available only within a defined job. When writing a multithreaded application or service, you must evaluate your use of job-scoped resources. The use of these resources must not conflict with or negatively affect other threads in the process.</li>
<li class="ulchildlink"><strong><a href="rzahwapico.htm">API thread safety classifications</a></strong><br />
<span>Before using an API, you should determine if
it is safe to call that API in your multithreaded program.</span></li>
<li class="ulchildlink"><strong><a href="rzahwclcco.htm">CL commands and thread safety</a></strong><br />
The Integrated
Language Environment<sup>®</sup> (ILE) CL run time and compiler-generated code are
threadsafe. Original program model (OPM) CL programs are not threadsafe.</li>
<li class="ulchildlink"><strong><a href="rzahwdafco.htm">Denied access functions and thread safety</a></strong><br />
To prevent problems in system integrity and data damages, certain APIs and commands are either conditionally threadsafe or not threadsafe. These APIs and commands deny all or partial access.</li>
<li class="ulchildlink"><strong><a href="rzahwexico.htm">Exit points</a></strong><br />
The <span class="keyword">i5/OS™</span> registration
facility allows you to define exit points for functions in an application
and to register programs that run at those exit points.</li>
</ul>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="rzahwovepo.htm" title="A thread is the path taken by a program while running, the steps performed, and the order in which the steps are performed.">Multithreaded applications</a></div>
</div>
<div class="relconcepts"><strong>Related concepts</strong><br />
<div><a href="rzahwnonco.htm" title="Your multithreaded application at times requires access to functions or system services that are not thread safe. There are few completely safe alternatives for calling these functions.">Function calls that are not thread safe</a></div>
</div>
<div class="relref"><strong>Related reference</strong><br />
<div><a href="rzahwgrxco.htm" title="All programs and service programs are activated within a substructure of a job that is called an activation group. This substructure contains the resources necessary to run the programs, including static and heap storage, and temporary data management resources.">Activation groups and threads</a></div>
<div><a href="rzahwevaco.htm" title="When writing a multithreaded application, you should evaluate all the parts of the application and all the services that it uses for thread safety.">Existing application evaluation</a></div>
</div>
</div>
</body>
</html>