view docs/ccguide/sbrk.refentry @ 3285:345ff5806dd7

Correct coco.d filename in shipped Defsfile files It seems that 8 years ago in commit 2624:b8c7b7fbf3c9 the coco defs were put into a new "coco.d" (from "systype"), and the various level*/<port>/defsfile were updated. However, the level*/<port>/defs/Defsfile (that are copied to the disk images under DEFS) were apparently wrongly updated.
author hpmachining <aur@hpminc.com>
date Thu, 18 Jun 2020 20:29:32 +0200
parents 1d37d3a84a7c
children
line wrap: on
line source

<refentry id="sbrk">
<refnamediv>
<refname>Sbrk</refname>
<refname>Ibrk</refname>
<refpurpose>request additional working memory</refpurpose>
</refnamediv>

<refsynopsisdiv>
<funcsynopsis>
<funcprototype>
  <funcdef>char *<function>sbrk</function></funcdef>
  <paramdef>int <parameter>increase</parameter></paramdef>
</funcprototype>
<funcprototype>
  <funcdef>char *<function>ibrk</function></funcdef>
  <paramdef>int <parameter>increase</parameter></paramdef>
</funcprototype>
</funcsynopsis>

</refsynopsisdiv>

<refsect1><title>Description</title>
<para>
Sbrk requests an allocation from free memory and returns a
pointer to its base.
</para>
<para>
"Sbrk()" requests the system to allocate "new" memory from
outside the initial allocation.
</para>
<para>
Users should read the Memory Management section of this manual
for a fuller explanation of the arrangement.
</para>
<para>
Ibrk requests memory from inside the initial memory allocation.
</para>
</refsect1>

<refsect1><title>Diagnostics</title>
<para>
Sbrk and ibrk return -1 if the requested amount of contiguous
memory is unavailable.
</para>
</refsect1>

</refentry>