81 lines
4.6 KiB
HTML
81 lines
4.6 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="reference" />
|
|
<meta name="DC.Title" content="Thread attributes" />
|
|
<meta name="abstract" content="Thread attributes are thread characteristics that affect the behavior of the thread. Different attributes are available depending on the programming language and API set that you are using." />
|
|
<meta name="description" content="Thread attributes are thread characteristics that affect the behavior of the thread. Different attributes are available depending on the programming language and API set that you are using." />
|
|
<meta name="DC.Relation" scheme="URI" content="rzahwtwoco.htm" />
|
|
<meta name="DC.Relation" scheme="URI" content="rzahwe11rx.htm" />
|
|
<meta name="DC.Relation" scheme="URI" content="rzahwex7rx.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="rzahwatt-attco" />
|
|
<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 attributes</title>
|
|
</head>
|
|
<body id="rzahwatt-attco"><a name="rzahwatt-attco"><!-- --></a>
|
|
<!-- Java sync-link --><script language="Javascript" src="../rzahg/synch.js" type="text/javascript"></script>
|
|
<h1 class="topictitle1">Thread attributes</h1>
|
|
<div><p>Thread attributes are thread characteristics that affect the behavior
|
|
of the thread. Different attributes are available depending on the programming
|
|
language and API set that you are using.</p>
|
|
<div class="section"><p>Methods for using an attribute and its effect on the thread depend
|
|
on how the programming language and API set externalize the thread attribute
|
|
to your application. You can set the thread attributes at the time you start
|
|
a thread or change them after the thread is actively running.</p>
|
|
</div>
|
|
<div class="section"><div class="p">Some common thread attributes and their effects are as follows: <ul><li>Priority:<p>The priority attribute affects the amount of processing time
|
|
that the system gives the thread before letting another thread or process
|
|
interrupt it.</p>
|
|
</li>
|
|
<li>Stack size:<p>The stack size attribute affects the number of functions
|
|
that a thread can call before the thread fails due to insufficient stack space.</p>
|
|
</li>
|
|
<li>Name:<p>The name attribute affects the ability to debug or track the actions
|
|
of a thread through your application.</p>
|
|
</li>
|
|
<li>Thread group:<p>The thread group attribute affects the ability to easily
|
|
manage more than one thread at a time.</p>
|
|
</li>
|
|
<li>Detach state:<p>The detach state attribute affects how you reclaim or
|
|
leave active resources associated with a thread when a thread ends.</p>
|
|
</li>
|
|
<li>Scheduling policy:<p>The scheduling policy attribute affects how the threads
|
|
are scheduled within the system or within the application. This relates to
|
|
thread priority.</p>
|
|
</li>
|
|
<li>Inherit scheduling:<p>The inherit scheduling attribute affects how the
|
|
priority of the thread is determined by the system.</p>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<ul class="ullinks">
|
|
<li class="ulchildlink"><strong><a href="rzahwe11rx.htm">Example: Set a thread attribute in a Pthread program</a></strong><br />
|
|
This example shows how to set the "detach state" thread attribute in a Pthread program.</li>
|
|
<li class="ulchildlink"><strong><a href="rzahwex7rx.htm">Example: Set a thread attribute in Java</a></strong><br />
|
|
This example shows how to set the "name" thread attribute in a Java™ program.</li>
|
|
</ul>
|
|
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="rzahwtwoco.htm" title="The concepts described here pertain to all programming languages.">i5/OS thread management</a></div>
|
|
</div>
|
|
</div>
|
|
</body>
|
|
</html> |