[389e37]: impnotes / environment-enq.html Maximize Restore History

Download this file

environment-enq.html    45 lines (44 with data), 14.7 kB

 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
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>25.3. Environment Inquiry</title><link rel="stylesheet" type="text/css" href="impnotes.css" /><link rev="made" href="mailto:clisp-list@lists.sourceforge.net" /><meta name="generator" content="DocBook XSL Stylesheets Vsnapshot_8706" /><link rel="home" href="index.html" title="Implementation Notes for GNU CLISP" /><link rel="up" href="environment.html" title="Chapter 25. Environment" /><link rel="prev" href="debugger.html" title="25.2. Debugging Utilities" /><link rel="next" href="clock.html" title="25.4. Time" /><link rel="copyright" href="legalese.html" title="Legal Status of the CLISP Implementation Notes" /><meta name="date" content="'generated: 2010-07-07 11:48:49-04:00'" /><link rel="author" title="Authors" href="index.html#authors" /><link rel="contents" title="Table of Contents" href="index.html" /><link rel="glossary" href="glossary.html" /><link rel="help" href="faq.html#faq-help" title="How do I ask for help?" /><link rel="home" title="Home" href="http://clisp.cons.org" /><link rel="index" href="idx.html" /></head><body><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">25.3. Environment Inquiry </th></tr><tr><td width="20%" align="left"><a accesskey="p" href="debugger.html">Prev</a> </td><th width="60%" align="center">Chapter 25. Environment </th><td width="20%" align="right"> <a accesskey="n" href="clock.html">Next</a></td></tr></table><hr /></div><div class="section" title="25.3. Environment Inquiry"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a id="environment-enq"></a>25.3. Environment Inquiry
<a class="clhs" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/sec_25-1-3.html">[sec_25-1-3]</a></h2></div></div></div><div class="toc"><dl><dt><span class="section"><a href="environment-enq.html#room">25.3.1. Function <code class="function">ROOM</code></a></span></dt><dt><span class="section"><a href="environment-enq.html#gc-sect">25.3.2. Function <code class="function">EXT:GC</code>
</a></span></dt><dt><span class="section"><a href="environment-enq.html#machine">25.3.3. Machine</a></span></dt><dt><span class="section"><a href="environment-enq.html#version">25.3.4. Function <code class="function">LISP-IMPLEMENTATION-VERSION</code></a></span></dt><dt><span class="section"><a href="environment-enq.html#argv">25.3.5. Function <code class="function">EXT:ARGV</code></a></span></dt></dl></div><div class="section" title="25.3.1. Function ROOM"><div class="titlepage"><div><div><h3 class="title"><a id="room"></a>25.3.1. Function <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_room.html" target="_top"><code class="function">ROOM</code></a></h3></div></div></div><p>The function <strong class="first"><em class="firstterm"><a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_room.html" target="_top"><code class="function">ROOM</code></a>
<a id="room-func" class="indexterm"></a></em></strong>
returns five values:</p><div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem">space occupied by Lisp objects (in
bytes)</li><li class="listitem">space available for allocating Lisp objects until
the next <a href="gc.html" class="olink">garbage-collect</a>ion is triggered (in bytes)</li><li class="listitem">space permanently allocated (in
bytes)</li><li class="listitem">the number of times <a href="gc.html" class="olink">garbage-collect</a>ion was done in this
<a class="ulink" href="http://clisp.cons.org" target="_top"><span class="command"><strong>CLISP</strong></span></a> session</li><li class="listitem">the cumulative space freed by all the <a href="gc.html" class="olink">garbage-collect</a>ions in
this <a class="ulink" href="http://clisp.cons.org" target="_top"><span class="command"><strong>CLISP</strong></span></a> session (in bytes)</li><li class="listitem">the total time (in <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/convar_intern_s-per-second.html" target="_top"><code class="constant">INTERNAL-TIME-UNITS-PER-SECOND</code></a>)
spent collecting garbage</li></ol></div></div><div class="section" title="25.3.2. Function EXT:GC"><div class="titlepage"><div><div><h3 class="title"><a id="gc-sect"></a>25.3.2. Function <strong class="first"><em class="firstterm"><code class="function">EXT:GC</code>
<a id="gc-func" class="indexterm"></a></em></strong></h3></div></div></div><p>This function starts a global <a href="gc.html" class="olink">garbage-collect</a>ion and returns the same values
as <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_room.html" target="_top"><code class="function">ROOM</code></a>.</p><p>When the optional parameter is non-<a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/convar_nil.html" target="_top"><code class="constant">NIL</code></a> also invalidates
just-in-time compiled objects.</p></div><div class="section" title="25.3.3. Machine"><div class="titlepage"><div><div><h3 class="title"><a id="machine"></a>25.3.3. Machine</h3></div></div></div><div class="variablelist">
<!--#ifdef MACHINE_KNOWN-->
<dl><dt><span class="term"><span class="plat-dep">Platform Dependent: <span class="plat-dep"><a class="ulink" href="http://www.unix.org/online.html" target="_top"><span class="strong"><strong>UNIX</strong></span></a> platform only.</span></span></span></dt><dd>The functions <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_short-sit_ng-site-name.html" target="_top"><code class="function">SHORT-SITE-NAME</code></a>, <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_short-sit_ng-site-name.html" target="_top"><code class="function">LONG-SITE-NAME</code></a>
should be defined in a site-specific <a class="link" href="src-files.html#config-lisp"><code class="filename">config.lisp</code></a> file.
The default implementations try to read the value of the <a class="unix" href="http://www.opengroup.org/susv3/basedefs/xbd_chap08.html">environment variable</a>
<code class="envar">ORGANIZATION</code>, and, failing that,
call <a class="unix" href="http://www.opengroup.org/susv3/functions/uname.html"><code class="function">uname</code></a>.
</dd><dt><span class="term"><span class="plat-dep">Platform Dependent: <span class="plat-dep"><a class="ulink" href="http://winehq.org/" target="_top"><span class="platform">Win32</span></a> platform only.</span></span></span></dt><dd>The functions <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_short-sit_ng-site-name.html" target="_top"><code class="function">SHORT-SITE-NAME</code></a>, <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_short-sit_ng-site-name.html" target="_top"><code class="function">LONG-SITE-NAME</code></a>
should be defined in a site-specific <a class="link" href="src-files.html#config-lisp"><code class="filename">config.lisp</code></a> file.
The default implementations try to read the registry.
</dd>
<!--#else-->
<dt><span class="term"><span class="plat-dep">Platform Dependent: <span class="plat-dep">No platform supports this currently</span></span></span></dt><dd>The functions <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_machine-type.html" target="_top"><code class="function">MACHINE-TYPE</code></a>, <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_machine-version.html" target="_top"><code class="function">MACHINE-VERSION</code></a>,
<a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_machine-instance.html" target="_top"><code class="function">MACHINE-INSTANCE</code></a> and <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_short-sit_ng-site-name.html" target="_top"><code class="function">SHORT-SITE-NAME</code></a>, <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_short-sit_ng-site-name.html" target="_top"><code class="function">LONG-SITE-NAME</code></a> should be
defined by every user in his user-specific <a class="link" href="src-files.html#config-lisp"><code class="filename">config.lisp</code></a> file.
</dd>
<!--#endif-->
</dl></div></div><div class="section" title="25.3.4. Function LISP-IMPLEMENTATION-VERSION"><div class="titlepage"><div><div><h3 class="title"><a id="version"></a>25.3.4. Function <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_lisp-impl_tion-version.html" target="_top"><code class="function">LISP-IMPLEMENTATION-VERSION</code></a></h3></div></div></div><p><a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_lisp-impl_tion-version.html" target="_top"><code class="function">LISP-IMPLEMENTATION-VERSION</code></a> returns
the numeric version (like <code class="literal">3.14</code>), and
the release date (like <code class="literal">"1999-07-21"</code>).
When running on the same machine on which <a class="ulink" href="http://clisp.cons.org" target="_top"><span class="command"><strong>CLISP</strong></span></a> was built, it appends
the binary build and <a href="image.html" class="olink">memory image</a> dump date in <a class="clhs" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/sec_25-1-4-2.html">universal time</a>
(like <code class="literal">3141592654</code>).
When running on a different machine, it appends the <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/fun_machine-instance.html" target="_top"><code class="function">MACHINE-INSTANCE</code></a>
of the machine on which it was built.</p></div><div class="section" title="25.3.5. Function EXT:ARGV"><div class="titlepage"><div><div><h3 class="title"><a id="argv"></a>25.3.5. Function <a class="link" href="environment-enq.html#argv" title="25.3.5. Function EXT:ARGV"><code class="function">EXT:ARGV</code></a></h3></div></div></div><p>This function will return a <a class="" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/glo_f.html#fresh">fresh</a> <a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/typ_simple-vector.html" target="_top"><code class="classname">SIMPLE-VECTOR</code></a> of
<a class="ulink" href="http://www.ai.mit.edu/projects/iiip/doc/CommonLISP/HyperSpec/Body/syscla_string.html" target="_top"><code class="classname">STRING</code></a> command line arguments passed to the runtime, including
those already processed by <a class="ulink" href="http://clisp.cons.org" target="_top"><span class="command"><strong>CLISP</strong></span></a>.
Use <a href="quickstart.html#script-exec" class="olink"><code class="varname">EXT:*ARGS*</code></a> instead of this function to get the arguments for your program.
</p></div></div><div class="bookinfo"><hr /><table width="100%" summary="impnotes meta info"><th><td align="left">These notes document <a class="ulink" href="http://clisp.cons.org" target="_top"><span class="command"><strong>CLISP</strong></span></a> version 2.49</td><td align="right">Last modified: 2010-07-07</td></th></table></div><div class="custom-footer"><hr /><table width="100%"><tr><td align="left"><a href="http://clisp.cons.org"><img src="clisp.png" width="48" height="48" alt="[CLISP home]" /></a></td><td align="center"><a href="https://sourceforge.net/donate/index.php?group_id=1355"><img src="http://images.sourceforge.net/images/project-support.jpg" width="88" height="32" alt="[Support CLISP]" /></a></td><td align="right"><a href="https://sourceforge.net/projects/clisp"><img width="120" height="30" alt="[SourceForge]" src="http://sflogo.sourceforge.net/sflogo.php?group_id=1355&amp;type=12&amp;page=environment-enq" /></a></td></tr></table></div><hr /><form method="get" action="http://www.google.com/custom" target="_top"><table width="100%" border="0"><tr><td nowrap="nowrap" align="center"><input type="hidden" name="domains" value="clisp.cons.org;clisp.podval.org;www.lisp.org" /><label for="sbi" style="display: none">Enter your search terms</label><input type="text" name="q" size="50" maxlength="255" id="sbi" value="25.3. Environment Inquiry" /><label for="sbb" style="display: none">Submit search form</label><input type="submit" name="sa" value="Google Search" id="sbb" /></td></tr><tr><td nowrap="nowrap" align="center"><input type="radio" name="sitesearch" value="" checked="1" id="ss0" /><label for="ss0" title="Search the Web"><small>Web</small></label><input type="radio" name="sitesearch" value="clisp.cons.org" id="ss1" /><label for="ss1" title="Search clisp.cons.org"><small>clisp.cons.org</small></label><input type="radio" name="sitesearch" value="clisp.podval.org" id="ss2" /><label for="ss2" title="Search clisp.podval.org"><small>clisp.podval.org</small></label><input type="radio" name="sitesearch" value="www.lisp.org" id="ss3" /><label for="ss3" title="Search www.lisp.org"><small>www.lisp.org</small></label><input type="hidden" name="client" value="pub-4445255502750357" /><input type="hidden" name="forid" value="1" /><input type="hidden" name="ie" value="UTF-8" /><input type="hidden" name="oe" value="UTF-8" /><input type="hidden" name="cof" value="GALT:#008000;GL:1;DIV:#336699;VLC:663399;AH:center;BGC:FFFFFF;LBGC:000000;ALC:0000FF;LC:0000FF;T:000000;GFNT:0000FF;GIMP:0000FF;LH:48;LW:48;L:http://clisp.cons.org/clisp.png;S:http://clisp.cons.org;FORID:1" /><input type="hidden" name="hl" value="en" /></td></tr></table></form><hr /><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="debugger.html">Prev</a> </td><td width="20%" align="center"><a accesskey="u" href="environment.html">Up</a></td><td width="40%" align="right"> <a accesskey="n" href="clock.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">25.2. Debugging Utilities  </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> 25.4. Time </td></tr></table></div></body></html>