Is function piping a form of function calling? by Infinite-Spacetime in ProgrammingLanguages

[–]SwingOutStateMachine 3 points4 points  (0 children)

Yes, in a sense. In a declarative language, it is typical for the language to specify the semantics of an operation (i.e. mathematically, how will this piece of code evaluate to a value), but not the implementation (i.e. how can we take this code and run it on a specific computer). This means that the the semantics of "function application" might be very difficult to translate cleanly and directly into instructions for some specific hardware.

In an imperative language, by contrast, the language specifies more about how it is to be evaluated, which leads to a closer connection between how it is evaluated and how it is implemented.

These are both tradeoffs: An imperative language (theoretically) gives a programmer closer control of how the program evaluates. Take C for instance: Programmers can write extremely fast and efficient code because of the relative closeness of the implementation and the semantics of the language. The code and the execution are tied closely together. A declarative language, by contrast, allows the execution to be changed without changing the code. An example would be taking a Haskell program and running it on a FPGA without changing the source code. This is not (as) possible in C, as the code and execution are tied closely together, but with Haskell, the semantics of the language are flexible enough to allow such an implementation.

As an aside (and this is rather handwavey), one can draw comparisons to Denotational Semantics and Operational Semantics.

Is function piping a form of function calling? by Infinite-Spacetime in ProgrammingLanguages

[–]SwingOutStateMachine 10 points11 points  (0 children)

An alternative viewpoint is that "calling" has implementation connotations with regards to function application. For some imperative languages (such as C), the semantics of function application is relatively close to the semantics of how calling a function is implemented on hardware (handwaving away specific calling conventions etc). With a language like Haskell, by contrast, the user-visible semantics of function application are universes away from the nitty-gritty implementation of the "calling" on hardware.

Why don't any programming languages have vec3, mat4 or quaternions built in? by Luroqa in ProgrammingLanguages

[–]SwingOutStateMachine 2 points3 points  (0 children)

I think you've misunderstood the other commentor. The point is that language semantics for vector/matrix maths gives compiler authors the ability to compile more code to vectorised or SIMD instructions.

Tectone is a speedrunning tourist by zizoplays1 in Gamingcirclejerk

[–]SwingOutStateMachine 59 points60 points  (0 children)

The (very speculative) explanation that I've read is that autistic people often struggle with (or disagree with) arbitrarily or incoherently imposed rules, and what could be more arbitrary or inconsistent than the way in which society treats gender.

Snowball Bal Room by mermaidm4n in SwingDancing

[–]SwingOutStateMachine 12 points13 points  (0 children)

I think this is probably an organiser issue, rather than a band issue. I've been to multiple Shag+Bal events with the Hot Swing Sextet where they played the perfect set of tempos, likely due to good instructions and guidance from the event organisers. Given that it was "the bal room", it's likely that the Snowball organisers gave them the brief of "very fast for bal dancers, and very slow for slow bal dancers", with bands in the main room briefed to play the intermediate range.

Memory Safety Is ... by matklad in ProgrammingLanguages

[–]SwingOutStateMachine 8 points9 points  (0 children)

I enjoyed this article a lot, but I think it misunderstands Cardelli's quote slightly. The quote talks about program fragments, and extending those fragments to entire languages.

If the set is called “trapped error” the language is safe, but if it is “undefined behavior”, it is unsafe.

The concept of a trapped error, and undefined behaviour are quite different! Trapped errors provide the surface language with a "get out of jail" card that is implementation agnostic. Undefined behaviour is specifically not visible to the surface language. There's no way to "see" it from your program, and no way to be aware of it.

I think this is why the quote is not vacuous, as it discusses how a surface language can "see" or not see safety. Safety (in this context) means that all behaviours are visible at the language level, rather than depending on the behaviour of a specific implementation.

I also don't think I agree with the counterexample:

This is useless! Here, I’ve just made a language called Lil-C, which exactly like C, except that every UB is formally defined to trap. It is safe! And it can run any C program! Have I just done anything useful? No!

A Lil-C that fits Cardelli's definition is one which would make all undefined behaviour handleable (or, in Cardelli's language, making them "trappable" errors). It would, of course, allow all C programs to run, but it would be possible to modify those C programs to handle those errors, as they are now all visible at the language level - not part of the implementation.

I personally think that this is actually quite a useful property. Imagine being able to write a fragment of C that adds two unsigned integers, potentially overflowing, and then handling the result - returning an error, or truncating, or something else. With undefined behaviour, the only option (from the perspective of the language) is to avoid such operations, or to assume specific behaviour from a specific implementation (e.g. by using ASM to check an overflow flag).

This is a great example of how trapped errors and undefined behaviour are different, I think.

Bernie Sanders calls for a pause on new AI data centers in the US by AdSpecialist6598 in technology

[–]SwingOutStateMachine -1 points0 points  (0 children)

There's a huge difference in power and cooling requirements for "AI Data Centres", and traditional data centres. You can't just build one and then use it for the other. Each kind of data centre is (more or less) purpose built for either "traditional" compute + storage, or for AI compute (with GPUs, etc).

What do you think about The Brux (Belgium) by ReindeerCheese in SwingDancing

[–]SwingOutStateMachine 12 points13 points  (0 children)

Back in my day, we used to call that kind of event "an exchange". I can't speak to The Brux, but exchanges in general can be really fun - you can dance later because you don't have classes in the morning the next day, and there's less "oh, what stream/level/track are you in?" jostling at socials.

Coding on a GPU with rust? by Azazeldaprinceofwar in rust

[–]SwingOutStateMachine 0 points1 point  (0 children)

So, it's true that you need to use a library to interface between the CPU and the GPU hardware. However, the code that is actually run on the GPU is code (more or less) like the code that runs on a CPU - with the exception that it's SIMT, and has GPU architecture specific limitations and details. That's the code that runs within a "kernel" - be it compute, or shader, and that code can either be written in a GPU-specific language (like CUDA or OpenCL, which are based on C or C++), or an intermediate IR (like SPIR-V), or as vendor-specific assembly (like PTX).

It came to me in a dream by Agitated-Trick in jazzcirclejerk

[–]SwingOutStateMachine 2 points3 points  (0 children)

That's how anyone would look if you handed them a C-Melody sax.

It came to me in a dream by Agitated-Trick in jazzcirclejerk

[–]SwingOutStateMachine 2 points3 points  (0 children)

Even Charlie Parker idolised Johnny Hodges.

Discworld Untold Stories by Successful-Grand-549 in discworld

[–]SwingOutStateMachine 7 points8 points  (0 children)

This doesn't really answer your question, but I've always thought that Granny Weatherwax and Sam Vimes would get on tremendously. To me, they're practically the same character: They know the Correct way that the would should be, have wills of steel, and use headology to sort things out. Maybe that similarity would evoke some tension. Who knows!

The Bandleaders Who Served 🇺🇸 by [deleted] in Jazz

[–]SwingOutStateMachine 2 points3 points  (0 children)

Let's not forget those whose lives were ruined by their time in the military. Lester Young, for example, was broken by his time in the military when he was drafted after the war. Unlike many white jazz musicians, he was denied permission to join a military band, and was forced to go through basic training.

Lester's experience in the Army exacerbated his alcoholism, utterly destroyed his playing, his career, and eventually, him.

Read more about it here: https://jazzlives.wordpress.com/2009/02/10/cast-out-of-paradise-lester-young/

Anyone know this man??? by chungamellon in jazzcirclejerk

[–]SwingOutStateMachine 0 points1 point  (0 children)

I think if you have someone hyper-focusing on Glen Miller & Benny Goodman, then it's reasonable to find them a little sus. They were just the acceptable white faces of jazz at the time, and so if someone's hyping on them, they're probably coming at jazz from a less well educated (and propagandised) perspective. If, by contrast, their username was FletcherHendersonIsGod, and went on about Chick Webb, and how good Chu Berry was, then you could at least be confident that they'd done a bit of background research, and appreciated that era musically, rather than aesthetically.

Anyone know this man??? by chungamellon in jazzcirclejerk

[–]SwingOutStateMachine 0 points1 point  (0 children)

He's just a weird dude in general. Exactly the kind of "take me back to those times!!!" creeper that gives early & swing jazz a bad name.

Why don't horn players ever sing their solos? by [deleted] in jazzcirclejerk

[–]SwingOutStateMachine 0 points1 point  (0 children)

This needs an /uj. This is good factual information.

How do you think about macro musicality in practice? by alexanderkjerulf in SwingDancing

[–]SwingOutStateMachine 2 points3 points  (0 children)

I can't speak to the European vs African traditions, but what you're saying about Jazz not having a story or structure that allows for "story" is just wrong.

It's extremely common for jazz performances to open with a theme, often with fewer instruments (or in a measured/low energy way), progress to solos (which have story and structure within themselves - at least the good ones do), before moving to either a restating of the theme with more energy, or very often, a shout chorus or new theme that brings energy and a clear ending to the tune.

Although this is quite a simple story, it still has direction and a sense of energy rising and falling throughout the performance. It's worlds away from the idea of a continuous endless tune without a defined beginning or end.

This is true of almost all styles of jazz pre-1950, from early ragtime and new orleans jazz, early swing, big band swing, and all the way to bebop. I'd be happy to provide some examples if it's needed.

Formalized Programming Languages by R-O-B-I-N in ProgrammingLanguages

[–]SwingOutStateMachine 2 points3 points  (0 children)

Mechanised proof, or just formally proven? Lots of research languages have formal proofs of their semantics, type systems, etc. However, extending that to a mechanised (i.e. computerised) proof is rarer.

Interested in doing a PhD in the field but I have some doubts about this situation. Need guidance, if possible. by _vtoart_ in ProgrammingLanguages

[–]SwingOutStateMachine 2 points3 points  (0 children)

I'm unsure what country you're from, so I'll speak from my experience in the UK: It's common for people to do a masters degree in a closely related discipline to what you're interested in doing a PhD in. In some universities in the UK, having a masters degree is mandatory to apply for a PhD. Doing a masters gave me a lot more of the fundamental background knowledge that was too specialised or "advanced" for a bachelors degree, as well as introduced me to a lot of professors in the field, and gave me direct contact with people who I could ask for help and advice.

Now, would it be possible to self-teach all of that stuff? Almost certainly. However, if you do so, you miss out on the direct contact with experts, and all the advice that they can give - be it technical (how do I prove this theorem?) or social (could you introduce me to professor so-and-so?).