Fork me on GitHub
#announcements
<
2023-11-03
>
plexus09:11:32

Overtone 0.11.0 has been released 🎶 Overtone is a (live) music coding environment for Clojure. This is the first release in 4.5 years, many thanks to everyone who contributed!

🎸 3
🎷 8
🙏 3
🎺 10
🎹 15
metal 4
👍 6
🎻 1
13
🎉 17
🎶 6
24
plexus09:11:08

• Official channel: #C053Q1QSG • Mailing list: https://groups.google.com/g/overtone

plexus09:11:24

CHANGELOG • Fix overtone.music.pitch/dec-last (#437) • Return notes in ascending order in overtone.music.pitch/chord • Fix printing of huge map when calling instruments with Cider (#432) • Fix size checks to multichannel buffer writes (#338) • Add clj-kondo support (#493) • Fix broken version comparison in args/SC-ARG-INFO (#449) • OSC: use #getHostScript to fallback on hostname string (#450) • Upgrade dependencies (#456) • Add support for the grain-buf ugen (#470) • use canonical URL for freesound API (#479) • Fix window paths to allow downloading samples (#487) • Removed obsolete JVM option CMSConcurrentMTEnabled (#488) • Read synthdef files correctly (#489) • Fix buffer reading (#490) • Add clj-kondo support (see overtone.linter) (#493) • Qualify the overtone ns in lein example (#495) Contributors: Andréas Kündig, dvc, Hlöðver Sigurðsson, Lee Araneta, Markku Rontu, Matt Kelly, Nada Amin, Paulo Rafael Feodrippe, Perry Fraser, Phillip Mates, Wesley Merkel

plexus10:11:42

Go forth and create beautiful things!

pfeodrippe11:11:22

Wow! Thank you so much, Arne!!! This is so great

Ben Sless13:11:18

Will it work with clojure 1.11?

plexus14:11:44

Yes.

👍 1
richiardiandrea15:11:13

Wow, that's awesome thanks2

avocade13:11:05

Bravo 👏:skin-tone-2:

vlaaad14:11:36

Hey, this is not a project or library update 😛

pez14:11:15

Lots of project and library updates, tho! 😃

Alex Miller (Clojure team)14:11:35

Oops, put it in the wrong place, sorry!

plexus15:11:42

I guess overtone will be in the next one 🙂

Noah Bogart17:11:23

This looks great.

hiredman17:11:13

that is very kind, thank you

seancorfield17:11:46

I love the group ID -- so appropriate 🙂

Noah Bogart17:11:54

using clojure.asm is pretty wild. What made you decide to go that route instead of "normal" clojure? did you see performance benefits?

hiredman17:11:56

the generated bytecode causes exceptions that are thrown by go to jump right to where the label is, which you can't do with clojure

😮 1
Noah Bogart17:11:16

that's very clever

henrik17:11:44

Is this for those who long for the days of BASIC?

henrik17:11:53

I might be in the target audience

hiredman17:11:57

there are ways you could emulate it in clojure, using a try/catch around a loop over a case, similar to what core.async's go macro does, but I wanted to use the capabilities the jvm exposes as directly as possible, without emulating features of the jvm that aren't exposed in clojure using features of clojure

bronsa17:11:31

lmao. nice

Noah Bogart17:11:55

jvm bytecode is very strange. i gotta read up on it to get why/how it all works

hiredman17:11:23

I think the bytecode pattern it uses isn't even representable in java either

seancorfield18:11:29

Have you tried java-decompiling the generated bytecode? I'm curious what it makes of it... 🙂

hiredman18:11:29

I have not, just javap

Joshua Suskalo19:11:48

I highly recommend adding a new throwable type for this so that you can elide stacktrace creation

Joshua Suskalo19:11:00

This looks really cool though!

hiredman19:11:49

It generates a new throwable subtype for every label, I don't have it eliding stacktrace construction, but it creates all the instances once up front and just rethrows the same instances as needed

Joshua Suskalo19:11:19

Oh that's good to know, I hadn't quite realized that it would rethrow the same throwable each time

oyakushev19:11:00

Wait, didn't you flame Joshua for using Errors for flow control in his library? I am confused now.

2
hiredman19:11:26

As I recall I was defending my practice of catching Throwable

oyakushev19:11:24

Yes, you were, I remember now. And that would not be an issue here because these gotos are local to a single stackframe, right?

hiredman19:11:49

Oh, no it totally could be an issue, it throws throwables, and exposes those throwables for throwing in the dynamic extent of tagbody

hiredman19:11:14

Anything using throwables for jumps has potential issues when composed with other code

👍 1
dpsutton22:11:47

reading through this, the limitation for 255 forms comes from using a function for each form right? If that was changed to group all the forms into a single function between labels would the limitation jump to 255 labels?

hiredman22:11:21

the limitation is because each form is wrapped in a function, and then each function is passed as an argument to a static method, and that static method runs each function in turn with the exception handlers and what not set up

hiredman22:11:39

the jvm has a limit of 255 method parameters

hiredman22:11:15

and it becomes 254 because I tack on an extra nil form at the end for reasons

dpsutton22:11:17

right. that’s what i was wondering if all of the bodies between labels were accumulated into a single function then the limit would be the number of labels (ie form groups instead of forms)

hiredman22:11:55

not why that would be the limit?

hiredman22:11:40

I haven't looked into a ton, but I did skim the jvm spec on exception handlers the other day and did not immediately see any limitation to how many exception handlers you can have

hiredman22:11:12

you are saying basically automatically grouping with do

dpsutton22:11:28

yeah. just make the ones between labels into one function instead of N functions

hiredman22:11:58

I could, or just tell anyone who runs into the 254 limit to use do

dpsutton22:11:19

haha yeah. i was checking my understanding. love reading this code and was just wondering

hiredman23:11:44

something I have wondered about a little is if I could mess with internal compiler state enough to have it generate the bytecode for each body inside the runner class, and there by avoid having to wrap things as fns and pass them in

hiredman23:11:30

but that seems very intense (might involve writing a subclass of ObjExpr or something)

dpsutton23:11:59

would make a great keynote

chrisn18:11:18

Released ham-fisted 2.010 which contains an extensible primitive typed let system and helpers to invoke primitive functions - both of which are aimed at removing boxing from tight loops - https://github.com/cnuernber/ham-fisted/. hamf already contains a *-array macros that will inline array creation so - combined with the let statement - you can use arrays as tuples and get the full expected performance and of course eliminate boxing from tight loops. For example of typed let and primitive-invoke pathways see https://github.com/cnuernber/ham-fisted/blob/master/test/ham_fisted/hlet_test.clj.

👍 18