This file is indexed.

/usr/share/doc/sbcl/sbcl-internals/Implementation-of-Funcallable-Instances.html is in sbcl-doc 2:1.4.5-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<!-- This manual is part of the SBCL software system. See the
README file for more information.

This manual is in the public domain and is provided with absolutely no
warranty. See the COPYING and CREDITS files for more
information. -->
<!-- Created by GNU Texinfo 6.5, http://www.gnu.org/software/texinfo/ -->
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Implementation of Funcallable Instances (SBCL Internals)</title>

<meta name="description" content="Implementation of Funcallable Instances (SBCL Internals)">
<meta name="keywords" content="Implementation of Funcallable Instances (SBCL Internals)">
<meta name="resource-type" content="document">
<meta name="distribution" content="global">
<meta name="Generator" content="makeinfo">
<link href="index.html#Top" rel="start" title="Top">
<link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
<link href="Funcallable-Instances.html#Funcallable-Instances" rel="up" title="Funcallable Instances">
<link href="Objects-In-Memory.html#Objects-In-Memory" rel="next" title="Objects In Memory">
<link href="Overview-of-Funcallable-Instances.html#Overview-of-Funcallable-Instances" rel="prev" title="Overview of Funcallable Instances">
<style type="text/css">
<!--
a.summary-letter {text-decoration: none}
blockquote.indentedblock {margin-right: 0em}
blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
blockquote.smallquotation {font-size: smaller}
div.display {margin-left: 3.2em}
div.example {margin-left: 3.2em}
div.lisp {margin-left: 3.2em}
div.smalldisplay {margin-left: 3.2em}
div.smallexample {margin-left: 3.2em}
div.smalllisp {margin-left: 3.2em}
kbd {font-style: oblique}
pre.display {font-family: inherit}
pre.format {font-family: inherit}
pre.menu-comment {font-family: serif}
pre.menu-preformatted {font-family: serif}
pre.smalldisplay {font-family: inherit; font-size: smaller}
pre.smallexample {font-size: smaller}
pre.smallformat {font-family: inherit; font-size: smaller}
pre.smalllisp {font-size: smaller}
span.nolinebreak {white-space: nowrap}
span.roman {font-family: initial; font-weight: normal}
span.sansserif {font-family: sans-serif; font-weight: normal}
ul.no-bullet {list-style: none}
-->
</style>


</head>

<body lang="en">
<a name="Implementation-of-Funcallable-Instances"></a>
<div class="header">
<p>
Previous: <a href="Overview-of-Funcallable-Instances.html#Overview-of-Funcallable-Instances" accesskey="p" rel="prev">Overview of Funcallable Instances</a>, Up: <a href="Funcallable-Instances.html#Funcallable-Instances" accesskey="u" rel="up">Funcallable Instances</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>]</p>
</div>
<hr>
<a name="Implementation-of-Funcallable-Instances-1"></a>
<h3 class="section">5.2 Implementation of Funcallable Instances</h3>

<p>The first word after the header of a funcallable instance points to a
dedicated trampoline function (known as
<code>funcallable_instance_tramp</code> in SBCL 0.9.17) which is responsible
for calling the funcallable instance function, kept in the second word
after the header.  The remaining words of a funcallable instance are
firstly the <code>layout</code>, and then the slots.
</p>
<p>The implementation of funcallable instances inherited from CMUCL
differed in that there were two slots for the function: one for the
underlying <code>simple-fun</code>, and one for the function itself (which is
distinct from the <code>simple-fun</code> in the case of a closure.  This,
coupled with an instruction in the prologue of a closure&rsquo;s function to
fetch the function from the latter slot, allowed a trampolineless
calling sequence for funcallable instances; however, drawbacks included
the loss of object identity for the funcallable instance function (if a
funcallable instance was set as the function of another, updates to the
first would not be reflected in calls to the second) and, more
importantly, a race condition in calling funcallable instances from one
thread while setting its funcallable instance function in another.  The
current implementation, described in the paragraph above, does not
suffer from these problems (the function of a funcallable instance can
be set atomically and retains its identity) at the cost of an additional
layer of indirection.
</p>


</body>
</html>