Warning: mysqli::__construct(): (HY000/1203): User howardkn already has more than 'max_user_connections' active connections in D:\Inetpub\vhosts\howardknight.net\al.howardknight.net\includes\artfuncs.php on line 21
Failed to connect to MySQL: (1203) User howardkn already has more than 'max_user_connections' active connections
Warning: mysqli::query(): Couldn't fetch mysqli in D:\Inetpub\vhosts\howardknight.net\al.howardknight.net\index.php on line 66
Article <86le129ibu.fsf@linuxsc.com>
Deutsch   English   Français   Italiano  
<86le129ibu.fsf@linuxsc.com>

View for Bookmarking (what is this?)
Look up another Usenet article

Path: ...!news.nobody.at!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: Tim Rentsch <tr.17687@z991.linuxsc.com>
Newsgroups: comp.lang.c
Subject: Re: relearning C: why does an in-place change to a char* segfault?
Date: Mon, 12 Aug 2024 02:55:01 -0700
Organization: A noiseless patient Spider
Lines: 37
Message-ID: <86le129ibu.fsf@linuxsc.com>
References: <IoGcndcJ1Zm83zb7nZ2dnZfqnPWdnZ2d@brightview.co.uk> <20240801114615.906@kylheku.com> <v8gs06$2ceis$1@dont-email.me> <v8jlnk$31hqf$1@dont-email.me> <87bk29duba.fsf@nosuchdomain.example.com> <v8mkao$3n2rq$5@dont-email.me> <8734nldmea.fsf@nosuchdomain.example.com> <6a0172b8fe12171901a97032b8a91641308fdc50@i2pn2.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Injection-Date: Mon, 12 Aug 2024 11:55:02 +0200 (CEST)
Injection-Info: dont-email.me; posting-host="f42e4005105099d89c60a754521770ce";
	logging-data="3404816"; mail-complaints-to="abuse@eternal-september.org";	posting-account="U2FsdGVkX19cCFa4kx9FPAj0QiDTamKeUWROUWQzvoc="
User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.4 (gnu/linux)
Cancel-Lock: sha1:eJ5TtcZoJK9EtTL7TfbwaSiAjwE=
	sha1:lwrv/iHV4ZboFtqZwo13Xw8678A=
Bytes: 2743

Richard Damon <richard@damon-family.org> writes:

> On 8/3/24 10:58 PM, Keith Thompson wrote:
>
>> Lawrence D'Oliveiro <ldo@nz.invalid> writes:
>>
>>> On Sat, 03 Aug 2024 17:07:37 -0700, Keith Thompson wrote:
>>>
>>>> ... general compression isn't something I've seen ...
>>>
>>> I recall Apple had a patent on some aspects of the ?PEF?
>>> executable format that they created for their PowerPC machines
>>> running old MacOS.  This had to do with some clever instruction
>>> encodings for loading stuff into memory.
>>
>> Is that relevant to what I asked about?
>>
>> What I had in mind is something that, given this:
>>
>>      static int buf = { 1, 1, 1, ..., 1 }; // say, 1000 elements
>>
>> would store something less than 1000*sizeof(int) bytes in the
>> executable file.  I wouldn't be hard to do, but I'm not convinced
>> it would be worthwhile.
>
> I vaguely seem to remember an embedded format that did something like
> this.  The .init segement that was "copied" to the .data segement has
> a simple run-length encoding option.  For non-repetitive data, it
> just encoded 1 copy of length n.  But it could also encode repeats
> like your example.  When EPROM was a scarce commodity squeezing out a
> bit of size for the .init segment was useful.
>
> My guess that since it didn't persist, it didn't actually help that
> much.

Or maybe it helped back in the day, but since then technology has
changed and it doesn't help any more.