Live data from Hacker News

Celebrating Tony Hoare's mark on computer science

bertrandmeyer.com

31–39 of 39 posts

Re: Celebrating Tony Hoare's mark on computer science

#32
post #6

In the early eighties, for example, he brought to Oxford the creators of two major formal specification languages: Cliff Jones with VDM, Jean-Raymond Abrial with Z. At Oxford, Z actually underwent a systematic rework, reminiscent of the Goethe quip reproduced above, with Frenchmen and mathematicians replaced by English mathematicians (or computer scientists). The new version enjoyed immense success in Britain, won a…

I can only imagine what it must've been like throughout the 90s and teens seeing people whack their heads against concurrency.

It was not a fun time. In Java, for example, the concurrency & threading primitives were so low level it was almost impossible for anyone to use them and get it right. The concurrency package introduced in 2004 brought higher level concepts and mostly eliminated the need to risk the footguns present in the thread/runnable/synchronized constructs.

As far back at 1995 people were warning against using threads. See for example John Ousterhout's "Why Threads are a Bad Idea (for most purposes)" https://blog.acolyer.org/2014/12/09/why-threads-are-a-bad-id...>

Re: Celebrating Tony Hoare's mark on computer science

#33

Earlier quoted context omitted.

I can only imagine what it must've been like throughout the 90s and teens seeing people whack their heads against concurrency.

It was not a fun time. In Java, for example, the concurrency & threading primitives were so low level it was almost impossible for anyone to use them and get it right. The concurrency package introduced in 2004 brought higher level concepts and mostly eliminated the need to risk the footguns present in the thread/runnable/synchronized constructs. As far back at 1995 people were warning against using threads. See for…

Now I see it written down I realize how lucky I've been to have spent time at the Programming Research Group at Oxford when Tony Hoare was running it and then to have worked for and founded a company with John Ousterhout. And, yeah, when I worked with him he wasn't a fan of threads.

Re: Celebrating Tony Hoare's mark on computer science

#34

Earlier quoted context omitted.

I can only imagine what it must've been like throughout the 90s and teens seeing people whack their heads against concurrency.

It was not a fun time. In Java, for example, the concurrency & threading primitives were so low level it was almost impossible for anyone to use them and get it right. The concurrency package introduced in 2004 brought higher level concepts and mostly eliminated the need to risk the footguns present in the thread/runnable/synchronized constructs. As far back at 1995 people were warning against using threads. See for…

> In Java, for example, the concurrency & threading primitives were so low level it was almost impossible for anyone to use them and get it right.

I disagree with this. As long as you had an understanding of critical sections and notify & wait, typical use cases were reasonably straightforward. The issues were largely when you ventured outside of critical sections, or when you didn’t understand the extent of your shared mutable state that needed to be protected by critical sections (which would still be a problem today, for example when you move references to mutable objects between threads — the concurrent package doesn’t really help you there).

The problem with Java pre-1.5 was that the memory model wasn’t very well-defined outside of locks, and that the guarantees that were specified weren’t actually assured by most implementations [0]. That changed with the new memory model in Java 1.5, which also enabled important parts of the new concurrency package.

[0] https://www.cs.tufts.edu/~nr/cs257/archive/bill-pugh/jmm2.pd...

Re: Celebrating Tony Hoare's mark on computer science

#35
post #16

Earlier quoted context omitted.

Making it explicit wouldn’t be particularly problematic no? Option in Rust terms. Or for this specific case, a GADT (Single | Married )? It could even use a special “NULL” address. Just don’t pollute every type with it.

Polluting every type with it is just a very bad implementation which has nothing in common with the concept of NULL as proposed by Tony Hoare in the paper "Record Handling". The concept as proposed by Hoare is strictly necessary for things like partial relations, which are encountered very frequently in practice. It is true however that a large number of programming languages have misused the concept of a NULL refere…

> The concept as proposed by Hoare is strictly necessary for things like partial relations

I read the 'Partial Functional Relationships' section. There's nothing special there. It's just structs with nulls.

> Polluting every type with it I think you're reacting to the pollution of the syntax. Hoare already polluted the semantics: Every type can be null. You can't even model a NonNull because NonNull itself can be null.

Re: Celebrating Tony Hoare's mark on computer science

#36
post #34

Earlier quoted context omitted.

It was not a fun time. In Java, for example, the concurrency & threading primitives were so low level it was almost impossible for anyone to use them and get it right. The concurrency package introduced in 2004 brought higher level concepts and mostly eliminated the need to risk the footguns present in the thread/runnable/synchronized constructs. As far back at 1995 people were warning against using threads. See for…

> In Java, for example, the concurrency & threading primitives were so low level it was almost impossible for anyone to use them and get it right. I disagree with this. As long as you had an understanding of critical sections and notify & wait, typical use cases were reasonably straightforward. The issues were largely when you ventured outside of critical sections, or when you didn’t understand the extent of your sha…

So you're saying that as long as you knew what you were doing, you'd be OK? My point is that at that time, and still to a large degree today, most programmers don't know what they are doing.

Re: Celebrating Tony Hoare's mark on computer science

#37

Meyer makes an important point that often gets lost: the null pointer predates Hoare. NIL existed in McCarthy's Lisp in 1959, six years before Hoare added null references to ALGOL W. The "mistake," if it was one, was already widespread. What made Hoare's 2009 confession so impactful wasn't that he was solely responsible — it's that he was the first person with that level of authority to publicly say "this was wrong."…

LISP was special because it had only 2 data types: atoms and lists. Both lists and atoms could appear in any place in any function or special form. NIL was a special atom, which was used to stand for an empty list. Because it could appear in any place in a LISP program, it could be used anywhere where one had to write that something does not exist. In a programming language with a more complicated and also extensible…

[dead]

Re: Celebrating Tony Hoare's mark on computer science

#38
post #2

One of CS's heroes lauding another. I feel I know both author and subject better for reading this. We are all very lucky to have lived through the foundation of a new science and new engineering over the last 50 years.

A bit more than 50 years. Grace Hopper retired in 1966. It's true that Grace kept un-retiring, but the most crucial stuff is all before she retired. Invention of what we'd think of as a linker-loader (which Grace called a compiler) and of the broad concept of high level programming languages all happens in the 1950s.

I rounded down to the nearest half-century :)

I hope to live through to 2050, just to see what's going to happen.

Re: Celebrating Tony Hoare's mark on computer science

#39
post #7

> First, the null pointer is essentially inevitable if you want to model the world, which has references (things containing denotations of other things). I took major exception to this. The real world doesn't have non-things, and references do not demand to refer to non-things. If your domain does actually have the concept of null, just make a type for it. Then you won't accidentally use a 6 or a "foo" where a null w…

You're clearly wrong.
Post reply on HN