|
Michał Muskała
@
michalmuskala
London, England
|
|
Software engineer, speaker, trainer, open source. Erlang, Elixir, Ruby. he/him 🏳️🌈
|
|
|
1.763
Tweetovi
|
504
Pratim
|
2.984
Osobe koje vas prate
|
| Tweetovi |
|
Michał Muskała
@michalmuskala
|
21 min |
|
Yes, but it needs to be done manually, by default every function - native or not - is equal.
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
42 min |
|
Just to complicate things more, this is not what BEAM is actually executing 😉 when a module is loaded, instructions are specialised and transformed to fit better into the VM. The bytecode in files is more of an interchange format between compiler & runtime
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
44 min |
|
To make it more complex not all operations take the same amount of time either. Reductions are less a measure of anything, more a mechanism to ensure that process is evantually made at some point
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
45 min |
|
By operation I mean bytecode/opcode - names differ. For example an operation can be extracting an element from a tuple, another would be comparing the element to something, another could be checking if a value is a list, and many, many more.
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
6 h |
|
They are generally treated as any other function call, so one reduction on call & one on return. There are extra APIs to consume more if your function is doing more work
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
18 h |
|
A reduction is counted on every function call and return. It's only a approximate measure of performance - you can in theory do arbitrarily many operations inside the function, though in practice that's limited by the fact that erlang doesn't have loops.
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
1. velj |
|
We definitely should! At least something good comes out of it 😉
|
||
|
|
||
| Michał Muskała proslijedio/la je tweet | ||
|
Code BEAM
@CodeBEAMio
|
31. sij |
|
👉 #Erlang
👉 Tooling
👉 Developer experience
How much time did you spend today reading code? Learn how Erlang tooling can make reading and understanding code easier from @michalmuskala at #CodeBEAMSF! 🙌
Book tickets now!
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
31. sij |
|
I might or might not be a bit drunk right now, but it's the first time for me outside of EU since 2004, when Poland joined, and it's so sad. It feels to me like prejudice, and xenophobia, and homophobia, and all the worst in humanity winning and there's nothing anybody can do...
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
31. sij |
|
You can insert whitespace or even comments (😱) between almost any two tokens in Erlang
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
31. sij |
|
I definitely agree. We're also working on solving some of those issues. Are you coming to Code BEAM SF? If so, it would be great to talk a bit more about this in person
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
31. sij |
|
Not really, that's why were thinking about alternatives codesync.global/speaker/ilya-k…
|
||
|
|
||
| Michał Muskała proslijedio/la je tweet | ||
|
Erlang Ecosystem Foundation
@TheErlef
|
30. sij |
|
A diverse community is not only a strong community but a thriving community! We are happy to announce our joint initiative w/ #CodeBEAMSF to offer 10 training scholarships! Apply today #WeBEAMTogether
codesync.global/conferences/co…
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
30. sij |
|
First house you build for your enemy,
second house you build for your friend,
third house you build for yourself 😉
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
30. sij |
|
Dialyzer takes 30 minutes on my 24-core dev server, not to mention tests or other things in this hook. Running it all on commit is not an option, on every push probably not either.
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
30. sij |
|
I'm less concerned about CI resources - it's much more powerful than my local machine 😛 but yeah, I admit I didn't notice initially it was a pre-push hook and not pre-commit
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
30. sij |
|
Nooooo... pre commit hooks are the evilest thing ever invented 😛 I fully agree those checks should be running on CI and generally should block you from merging code, but not locally, it's so annoying and disruptive
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
26. sij |
|
That’s fair, yeah.
DCO is a good option, but even in Erlang it's error prone due to dynamic calls
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
26. sij |
|
Well... I think such core would need to include Enum (for for & stuff) and String (for interpolation), which means the two biggest part of the stdlib. I don't think you'd gain much by such split in reality
|
||
|
|
||
|
Michał Muskała
@michalmuskala
|
26. sij |
|
It's not that simple. Many syntactical constructs in elixir expand to some stdlib calls - for is Enum.reduce, [] is Access.get, and probably more. It's hard to distinguish what needs runtime support from what doesn't
|
||
|
|
||