1
<?xml version="1.0" encoding="UTF-8"?>
2
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook MathML Module V1.1b1//EN"
3
"http://www.oasis-open.org/docbook/xml/mathml/1.1CR1/dbmathml.dtd" [
4
<!ENTITY mathFunctionsInc SYSTEM "mathFunctionsInc.xml">
9
<keyword>lgamma, lgamma_r</keyword>
14
<refentrytitle>lgamma, lgamma_r</refentrytitle>
18
<year>2007-2011</year>
19
<holder>The Khronos Group Inc.
20
Permission is hereby granted, free of charge, to any person obtaining a
21
copy of this software and/or associated documentation files (the
22
"Materials"), to deal in the Materials without restriction, including
23
without limitation the rights to use, copy, modify, merge, publish,
24
distribute, sublicense, and/or sell copies of the Materials, and to
25
permit persons to whom the Materials are furnished to do so, subject to
26
the condition that this copyright notice and permission notice shall be included
27
in all copies or substantial portions of the Materials.</holder>
30
<manvolnum>3</manvolnum>
33
<!-- ================================ SYNOPSIS -->
35
<refnamediv id="lgamma">
36
<refname>lgamma, lgamma_r</refname>
43
<!-- floatn VARIATIONS=============================== -->
45
<refsynopsisdiv xmlns:xlink="http://www.w3.org/1999/xlink"><title></title>
54
<paramdef>gentype<parameter>x</parameter></paramdef>
61
<link xlink:href="vectorDataTypes.html">float<replaceable>n</replaceable></link>
67
<link xlink:href="vectorDataTypes.html">float<replaceable>n</replaceable></link>
68
<parameter>x</parameter></paramdef>
69
<paramdef><link xlink:href="global.html">__global</link>
70
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
71
<parameter>*signp</parameter>
79
<link xlink:href="vectorDataTypes.html">float<replaceable>n</replaceable></link>
85
<link xlink:href="vectorDataTypes.html">float<replaceable>n</replaceable></link>
86
<parameter>x</parameter></paramdef>
87
<paramdef><link xlink:href="local.html">__local</link>
88
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
89
<parameter>*signp</parameter>
97
<link xlink:href="vectorDataTypes.html">float<replaceable>n</replaceable></link>
103
<link xlink:href="vectorDataTypes.html">float<replaceable>n</replaceable></link>
104
<parameter>x</parameter></paramdef>
105
<paramdef><link xlink:href="private.html">__private</link>
106
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
107
<parameter>*signp</parameter>
112
<!-- float VARIATIONS=============================== -->
117
<link xlink:href="vectorDataTypes.html">float</link>
123
<link xlink:href="vectorDataTypes.html">float</link>
124
<parameter>x</parameter></paramdef>
125
<paramdef><link xlink:href="global.html">__global</link>
126
<link xlink:href="vectorDataTypes.html">int</link>
127
<parameter>*signp</parameter>
135
<link xlink:href="vectorDataTypes.html">float</link>
141
<link xlink:href="vectorDataTypes.html">float</link>
142
<parameter>x</parameter></paramdef>
143
<paramdef><link xlink:href="local.html">__local</link>
144
<link xlink:href="vectorDataTypes.html">int</link>
145
<parameter>*signp</parameter>
153
<link xlink:href="vectorDataTypes.html">float</link>
159
<link xlink:href="vectorDataTypes.html">float</link>
160
<parameter>x</parameter></paramdef>
161
<paramdef><link xlink:href="private.html">__private</link>
162
<link xlink:href="vectorDataTypes.html">int</link>
163
<parameter>*signp</parameter>
168
<!-- doublen VARIATIONS=============================== -->
173
<link xlink:href="vectorDataTypes.html">double<replaceable>n</replaceable></link>
179
<link xlink:href="vectorDataTypes.html">double<replaceable>n</replaceable></link>
180
<parameter>x</parameter></paramdef>
181
<paramdef><link xlink:href="global.html">__global</link>
182
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
183
<parameter>*signp</parameter>
191
<link xlink:href="vectorDataTypes.html">double<replaceable>n</replaceable></link>
197
<link xlink:href="vectorDataTypes.html">double<replaceable>n</replaceable></link>
198
<parameter>x</parameter></paramdef>
199
<paramdef><link xlink:href="local.html">__local</link>
200
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
201
<parameter>*signp</parameter>
209
<link xlink:href="vectorDataTypes.html">double<replaceable>n</replaceable></link>
215
<link xlink:href="vectorDataTypes.html">double<replaceable>n</replaceable></link>
216
<parameter>x</parameter></paramdef>
217
<paramdef><link xlink:href="private.html">__private</link>
218
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
219
<parameter>*signp</parameter>
224
<!-- double VARIATIONS=============================== -->
229
<link xlink:href="vectorDataTypes.html">double</link>
235
<link xlink:href="vectorDataTypes.html">double</link>
236
<parameter>x</parameter></paramdef>
237
<paramdef><link xlink:href="global.html">__global</link>
238
<link xlink:href="vectorDataTypes.html">int</link>
239
<parameter>*signp</parameter>
247
<link xlink:href="vectorDataTypes.html">double</link>
253
<link xlink:href="vectorDataTypes.html">double</link>
254
<parameter>x</parameter></paramdef>
255
<paramdef><link xlink:href="local.html">__local</link>
256
<link xlink:href="vectorDataTypes.html">int</link>
257
<parameter>*signp</parameter>
265
<link xlink:href="vectorDataTypes.html">double</link>
271
<link xlink:href="vectorDataTypes.html">double</link>
272
<parameter>x</parameter></paramdef>
273
<paramdef><link xlink:href="private.html">__private</link>
274
<link xlink:href="vectorDataTypes.html">int</link>
275
<parameter>*signp</parameter>
280
<!-- halfn VARIATIONS=============================== -->
285
<link xlink:href="vectorDataTypes.html">half<replaceable>n</replaceable></link>
291
<link xlink:href="vectorDataTypes.html">half<replaceable>n</replaceable></link>
292
<parameter>x</parameter></paramdef>
293
<paramdef><link xlink:href="global.html">__global</link>
294
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
295
<parameter>*signp</parameter>
303
<link xlink:href="vectorDataTypes.html">half<replaceable>n</replaceable></link>
309
<link xlink:href="vectorDataTypes.html">half<replaceable>n</replaceable></link>
310
<parameter>x</parameter></paramdef>
311
<paramdef><link xlink:href="local.html">__local</link>
312
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
313
<parameter>*signp</parameter>
321
<link xlink:href="vectorDataTypes.html">half<replaceable>n</replaceable></link>
327
<link xlink:href="vectorDataTypes.html">half<replaceable>n</replaceable></link>
328
<parameter>x</parameter></paramdef>
329
<paramdef><link xlink:href="private.html">__private</link>
330
<link xlink:href="vectorDataTypes.html">int<replaceable>n</replaceable></link>
331
<parameter>*signp</parameter>
336
<!-- half VARIATIONS=============================== -->
341
<link xlink:href="vectorDataTypes.html">half</link>
347
<link xlink:href="vectorDataTypes.html">half</link>
348
<parameter>x</parameter></paramdef>
349
<paramdef><link xlink:href="global.html">__global</link>
350
<link xlink:href="vectorDataTypes.html">int</link>
351
<parameter>*signp</parameter>
359
<link xlink:href="vectorDataTypes.html">half</link>
365
<link xlink:href="vectorDataTypes.html">half</link>
366
<parameter>x</parameter></paramdef>
367
<paramdef><link xlink:href="local.html">__local</link>
368
<link xlink:href="vectorDataTypes.html">int</link>
369
<parameter>*signp</parameter>
377
<link xlink:href="vectorDataTypes.html">half</link>
383
<link xlink:href="vectorDataTypes.html">half</link>
384
<parameter>x</parameter></paramdef>
385
<paramdef><link xlink:href="private.html">__private</link>
386
<link xlink:href="vectorDataTypes.html">int</link>
387
<parameter>*signp</parameter>
393
<!-- ================================ DESCRIPTION -->
395
<refsect1 id="description"><title>Description</title>
397
Returns the natural logarithm of the absolute value of the gamma function. The sign
398
of the gamma function is returned in the <varname>signp</varname> argument of the
399
<function>lgamma_r</function>.
403
An application that wants to use <type>half</type>
404
and <type>half<replaceable>n</replaceable></type> types
405
will need to include the <code>#pragma OPENCL EXTENSION
406
<citerefentry><refentrytitle>cl_khr_fp16</refentrytitle></citerefentry>
407
: enable</code> directive. If extended with
408
<citerefentry><refentrytitle>cl_khr_fp16</refentrytitle></citerefentry>,
409
generic type name <type>gentype</type> also includes <type>half</type> and
410
<type>half{2|3|4|8|16}</type>.
414
<!-- ================================ NOTES -->
416
<refsect1 id="notes"><title>Notes</title>
422
<!-- ================================ EXAMPLE -->
423
<!-- DO NOT DELETE IN CASE AN EXAMPLE IS ADDED IN THE FUTURE -->
425
<refsect2 id="example1">
430
<informaltable frame="none">
431
<tgroup cols="1" align="left" colsep="0" rowsep="0">
432
<colspec colname="col1" colnum="1" />
436
Example goes here - it will be set in "code" type with white space preserved.
445
<!-- ================================ SPECIFICATION -->
446
<!-- Set the "uri" attribute in the <olink /> element to the "named destination" for the PDF page
448
<refsect1 id="specification"><title>Specification</title>
451
<imagedata fileref="pdficon_small1.gif" format="gif" />
454
<olink uri="mathFunctions">OpenCL Specification</olink>
458
<!-- ================================ ALSO SEE -->
460
<refsect1 id="seealso"><title>Also see</title>
462
<citerefentry href="mathFunctions"><refentrytitle>Math Functions</refentrytitle></citerefentry>
466
<!-- ============================== COPYRIGHT -->
467
<!-- Content included from copyright.inc.xsl -->
469
<refsect3 id="Copyright"><title></title>
471
<imagedata fileref="KhronosLogo.jpg" format="jpg" />