November 19, 2021
On Friday, 19 November 2021 at 02:54:08 UTC, Adam D Ruppe wrote:
> On Friday, 19 November 2021 at 02:36:31 UTC, forkit wrote:
>> Each byte in memory has a unique address.
>
> This is not true and has never been true, at least in the x86 world.

you're conflating memory addressing in hardware, and memory addressing in software. I'm only interested in the software abstraction (and even a description of the hardware addressing is itself likely to be an abstraction).

The software abstraction is the lowest level I want to go. Which is an array of addressable memory. I build on that. I don't need to go any lower.

Ultimately, everything in the universe is an abstraction, at some level or another.

November 19, 2021
On Friday, 19 November 2021 at 02:46:58 UTC, Timon Gehr wrote:
>
> ...
> Those are not useful statements. They are not true.

That is not a useful statement. It is not true.

November 19, 2021
On 19.11.21 04:42, forkit wrote:
> On Friday, 19 November 2021 at 02:46:58 UTC, Timon Gehr wrote:
>>
>> ...
>> Those are not useful statements. They are not true.
> 
> That is not a useful statement. It is not true.
> 

https://en.wikipedia.org/wiki/Hitchens%27s_razor
November 19, 2021
On Friday, 19 November 2021 at 03:40:59 UTC, forkit wrote:
> On Friday, 19 November 2021 at 02:54:08 UTC, Adam D Ruppe wrote:
>> On Friday, 19 November 2021 at 02:36:31 UTC, forkit wrote:
>>> Each byte in memory has a unique address.
>>
>> This is not true and has never been true, at least in the x86 world.
>
> you're conflating memory addressing in hardware, and memory addressing in software. I'm only interested in the software abstraction (and even a description of the hardware addressing is itself likely to be an abstraction).
>
> The software abstraction is the lowest level I want to go. Which is an array of addressable memory. I build on that. I don't need to go any lower.
>
> Ultimately, everything in the universe is an abstraction, at some level or another.

C represents the hardware, except when it does not, got it.
November 19, 2021
On Friday, 19 November 2021 at 00:35:49 UTC, SealabJaster wrote:
> On Friday, 19 November 2021 at 00:09:20 UTC, H. S. Teoh wrote:
>> ...
>
> I wonder if we should rename the language to "swiss cheese" considering the amount of holes we have.

D - the quantum cheese!

No, I finally got it:
"It might look like a pile of shit, but it's actually cool"

The holes are obviously a feature:
https://www.asme.org/topics-resources/content/what-termites-can-teach-engineers


November 19, 2021
On Friday, 19 November 2021 at 02:36:31 UTC, forkit wrote:
> On Friday, 19 November 2021 at 00:38:15 UTC, Timon Gehr wrote:
>>
>> I think that statement itself is deceptive. C is not all that close to how modern hardware actually operates.
>
> I mean the abstraction of the C memory model...
>
> i.e. " ..one or more contiguous sequences of bytes. Each byte in memory has a unique address." This is still an appropriate abstraction, even in modern times.

Funny that x86 real mode contradicts that definition. Each byte had 4096 different possible addresses.

>
> When working at a low-level, this is still, even today, an appropriate and suitable abstraction, on which to build your ideas.
>
> No language can model 'actual hardware', and even if it could, the human brain could never use such a language.


November 19, 2021
On Friday, 19 November 2021 at 08:13:48 UTC, Patrick Schluter wrote:
>
> Funny that x86 real mode contradicts that definition. Each byte had 4096 different possible addresses.

That may be true. But C was designed around the concept of memory being a linear array of cells. And to this day, that remains a sound and relevant abstraction.

That array is my play ground ;-)

And, I still think C is the best language, when that is the level of abstraction you're working with.

November 19, 2021
On Friday, 19 November 2021 at 06:26:09 UTC, Paulo Pinto wrote:
> On Friday, 19 November 2021 at 03:40:59 UTC, forkit wrote:
>> On Friday, 19 November 2021 at 02:54:08 UTC, Adam D Ruppe wrote:
>>> On Friday, 19 November 2021 at 02:36:31 UTC, forkit wrote:
>>>> Each byte in memory has a unique address.
>>>
>>> This is not true and has never been true, at least in the x86 world.
>>
>> you're conflating memory addressing in hardware, and memory addressing in software. I'm only interested in the software abstraction (and even a description of the hardware addressing is itself likely to be an abstraction).
>>
>> The software abstraction is the lowest level I want to go. Which is an array of addressable memory. I build on that. I don't need to go any lower.
>>
>> Ultimately, everything in the universe is an abstraction, at some level or another.
>
> C represents the hardware, except when it does not, got it.

C represents a workable (and portable) abstraction of hardware.

Would you rather be programming in a language that requires you to send a command to trigger 5 volts along a specific wire, so you can read or store ... one bit? (and even that is an abstraction).

November 19, 2021

On Friday, 19 November 2021 at 09:26:26 UTC, forkit wrote:

>

C represents a workable (and portable) abstraction of hardware.

Would you rather be programming in a language that requires you to send a command to trigger 5 volts along a specific wire, so you can read or store ... one bit? (and even that is an abstraction).

Motorola 68000 assembly is nice, much more flexible than C.

November 19, 2021
On Friday, 19 November 2021 at 09:26:26 UTC, forkit wrote:
> On Friday, 19 November 2021 at 06:26:09 UTC, Paulo Pinto wrote:
>> On Friday, 19 November 2021 at 03:40:59 UTC, forkit wrote:
>>> On Friday, 19 November 2021 at 02:54:08 UTC, Adam D Ruppe wrote:
>>>> On Friday, 19 November 2021 at 02:36:31 UTC, forkit wrote:
>>>>> Each byte in memory has a unique address.
>>>>
>>>> This is not true and has never been true, at least in the x86 world.
>>>
>>> you're conflating memory addressing in hardware, and memory addressing in software. I'm only interested in the software abstraction (and even a description of the hardware addressing is itself likely to be an abstraction).
>>>
>>> The software abstraction is the lowest level I want to go. Which is an array of addressable memory. I build on that. I don't need to go any lower.
>>>
>>> Ultimately, everything in the universe is an abstraction, at some level or another.
>>
>> C represents the hardware, except when it does not, got it.
>
> C represents a workable (and portable) abstraction of hardware.
>
> Would you rather be programming in a language that requires you to send a command to trigger 5 volts along a specific wire, so you can read or store ... one bit? (and even that is an abstraction).

I would rather be programming in languages like Modula-2, Ada, or heck D, without the minefield that C brought into the world.

Sad historical facts, the set of languages created for system programing 10 years before C came to the world, starting with JOVIAL, do provide bounds checking by default and proper strings.

The DoD security assessent to Multics, which contrary to UNIX folkore went on and had a life, even with AT&T bailing out, was much higher than UNIX thanks to PL/I.

> Although the first edition of K&R described most of the rules that brought C's type structure to its present form, many programs written in the older, more relaxed style persisted, and so did compilers that tolerated it. To encourage people to pay more attention to the official language rules, to detect legal but suspicious constructions, and to help find interface mismatches undetectable with simple mechanisms for separate compilation, Steve Johnson adapted his pcc compiler to produce lint [Johnson 79b], which scanned a set of files and remarked on dubious constructions.

-- Dennis M. Ritchie on https://www.bell-labs.com/usr/dmr/www/chist.html

Dennis knew what he created, C advocates to this day apparently not.