Article View: comp.lang.c
Article #2029Re: is a wrapper on memory-allocation calls a good idea?
From: Ross Finlayson
Date: Mon, 30 Nov 2026 18:48
Date: Mon, 30 Nov 2026 18:48
40 lines
3514 bytes
3514 bytes
On 11/30/2026 10:31 AM, Lawrence D’Oliveiro wrote: > On Sun, 29 Nov 2026 22:44:26 -0800, Andrey Tarasevich wrote: > >> On Sun 11/29/2026 10:00 PM, Lawrence D’Oliveiro wrote: >>> >>> On Linux systems, you can set the memory-allocation policy to >>> “overcommit”, which basically means that, when a process asks for >>> memory, the kernel never says no >>> <https://manpages.debian.org/proc_sys_vm(5)>. >> >> Well, firstly, overcommit approach simply substitutes "virtual >> address space" in place of "actual memory" as the limited resource. > > No, it is actual memory that is being overcommitted. > If a wrapper is considered a good idea, then here there's that when there are many calls, for example in a loop, for example that need buffers, and to prevent them having fixed-length or variable-length array buffers in their code, when for the hot body or inner routine it's called of the loop where the instructions are to fit in the code-cache and the buffers are to fit in the data-cache, makes for an idea of "rolling" the buffers in a sense, not to be confusing shift & rotate, and "rocking" the buffers in a sense, since "rock & roll" isn't already an idiom within programming itself though it's after the rhythm & blues an account of the often the simple the tempo, is basically for an account of, for example, a loop-body that in the scope of the loop, manages memory with regards to "fixed-length buffers large enough for any of the uses in the loop", this sort of account of the "glo-calls" then the "fixed-length arrays: sized and aligned to cache-line/memory-page/memory-huge-page", then for formatters usually enough (eg, integer to string or string to integer, with making a default representation then a localized representation then an aligned representation as separate concerns, since the cache is hot, makes for a model of a little machine in its own little body of definition, "rock & roll rotating-buffers and formatting-layers".
Technical Details
Message-ID:
<05adnWuOGstvWZD2nZ2dnZfqnPSdnZ2d@giganews.com>Path:
mbox-mo1.pugleaf.net!srv.newsdeef.eu!weretis.net!feeder9.news.weretis.net!border-2.nntp.ord.giganews.com!nntp.giganews.com!local-1.nntp.ord.giganews.com!Xl.tags.giganews.com!local-4.nntp.ord.giganews.com!news.giganews.com.POSTED!not-for-mailReferences:
<11eh538$3fet7$1@dont-email.me> <11ehine$3kr02$1@dont-email.me> <11ej3eh$5ajn$3@dont-email.me> <11ej60c$6bhr$1@dont-email.me> <11ekfeo$mq5n$1@dont-email.me>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!srv.newsdeef.eu!weretis.net!feeder9.news.weretis.net!border-2.nntp.ord.giganews.com!nntp.giganews.com!local-1.nntp.ord.giganews.com!Xl.tags.giganews.com!local-4.nntp.ord.giganews.com!news.giganews.com.POSTED!not-for-mail NNTP-Posting-Date: Mon, 30 Nov 2026 18:48:17 +0000 Subject: Re: is a wrapper on memory-allocation calls a good idea? Newsgroups: comp.lang.c References: <11eh538$3fet7$1@dont-email.me> <11ehine$3kr02$1@dont-email.me> <11ej3eh$5ajn$3@dont-email.me> <11ej60c$6bhr$1@dont-email.me> <11ekfeo$mq5n$1@dont-email.me> From: Ross Finlayson <ross.a.finlayson@gmail.com> Date: Mon, 30 Nov 2026 10:48:13 -0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.6.0 MIME-Version: 1.0 In-Reply-To: <11ekfeo$mq5n$1@dont-email.me> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Message-ID: <05adnWuOGstvWZD2nZ2dnZfqnPSdnZ2d@giganews.com> Lines: 40 X-Usenet-Provider: http://www.giganews.com X-Trace: sv3-OvlmmA/Yg+pCCY9wjI41cZ/hVJU8YC6KR2lRH1NFKluUIN2y1wMZvhwwfr478YgfVgMdapVRFNDDAMU!ajVoXD3qrP7nK8R/d8Db8VcB5f8rK1rBmcHizbylawKCW7sn+pL6jXCxBRmKx4Mdc6Kjkzz0b7R8 X-Complaints-To: abuse@giganews.com X-DMCA-Notifications: http://www.giganews.com/info/dmca.html X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.3.40