I made a New Programming Language

  Рет қаралды 53,974

Tsoding Daily

Tsoding Daily

Күн бұрын

Previous Episodes: • Bada
References:
- The BEAM Book - blog.stenmans.org/theBeamBook/
- Tsoding - Bada - github.com/tsoding/bada
Support:
- BTC: bc1qj820dmeazpeq5pjn89mlh9lhws7ghs9v34x9v9
- Servers: zap-hosting.com/en/shop/donat...
Chapters:
- 0:00:00 - Announcements
- 0:01:02 - Recap
- 0:02:17 - Important Chunks
- 0:03:36 - Compact Term Encoding
- 0:09:00 - Plans for Today
- 0:11:00 - Hello, Bada
- 0:11:48 - Just Vector and Write Function
- 0:16:04 - code:load_file/1
- 0:17:26 - C code
- 0:19:05 - Beam Header
- 0:20:16 - Extend Vector
- 0:22:13 - Size of Header
- 0:23:53 - Knocking Off Goalposts
- 0:25:42 - code_chunk()
- 0:27:07 - Chunk Size
- 0:31:31 - Code Info
- 0:34:20 - Parsing Code Info
- 0:37:44 - Backward Compatibility
- 0:40:09 - Disassembler
- 0:42:30 - BEAM is not a Stack Machine
- 0:44:49 - Generating the Code Section
- 0:46:53 - Padding
- 0:53:45 - Loading the Code
- 0:55:37 - Atoms Table
- 1:01:02 - Troubleshooting with Disassembler
- 1:07:12 - Atom 0
- 1:08:03 - The BEAM Book
- 1:08:53 - Import Table
- 1:09:58 - Erlang Function Signatures
- 1:10:53 - What is Arity?
- 1:11:26 - Empty Import Table
- 1:13:20 - Future Plans
- 1:14:58 - Getting Ahead of Myself
- 1:16:19 - Export Table
- 1:17:00 - Label
- 1:19:01 - Erlang Debugger
- 1:20:31 - Empty Export Table
- 1:21:38 - Troubleshooting with Disassembler
- 1:22:24 - Strings Chunk
- 1:23:59 - Empty Code Segment
- 1:24:48 - Instruction Format
- 1:27:46 - Argument Encoding
- 1:32:36 - enum Tag
- 1:33:24 - fn encode()
- 1:35:11 - Pushing Label
- 1:36:15 - Label Indices and Error Handling
- 1:38:12 - enum OpCode
- 1:38:45 - repr(u8)
- 1:39:57 - Compilation Errors
- 1:40:27 - func_info
- 1:43:27 - return
- 1:43:55 - unsigned argument
- 1:45:27 - Almost a Valid Module
- 1:46:31 - label_count and function_count
- 1:47:41 - int_code_end
- 1:49:04 - First Valid Module
- 1:49:40 - module_info()
- 1:52:37 - export bada:bada/0
- 1:55:23 - Erlang and TCO
- 1:55:42 - Purely Functional Spaghetti
- 1:57:31 - Reloading bada module
- 1:58:03 - Troubleshooting
- 1:59:28 - Returning Value from Function
- 2:02:36 - code:purge/1
- 2:04:04 - Continue Troubleshooting
- 2:04:52 - Jumping to the Second Label
- 2:06:26 - State of the Erlang VM Documentation
- 2:07:02 - Is Erlang a Good Career Choice?
- 2:07:46 - Is Erlang an Exotic Language?
- 2:08:40 - I don't need Elixir
- 2:09:07 - Encoding Bigger Arguments
- 2:12:43 - Do you really need Negative Numbers?
- 2:14:19 - Argument Encoding is not That Scary
- 2:15:22 - You only need Vector and write() function
- 2:16:23 - Inventing the Syntax
- 2:18:07 - Nuclear Situation in Novosibirsk
- 2:19:06 - Hash Table of Functions
- 2:20:19 - Generating Atom List
- 2:22:46 - struct Atoms
- 2:25:16 - Lazy Atom Collection
- 2:28:07 - Generating the Code of Functions
- 2:35:07 - Generating Atoms Chunk
- 2:36:02 - Atoms as a Vector instead of HashMap
- 2:39:54 - This is Already a Mini Programming Language
- 2:41:13 - Exporting Functions
- 2:42:23 - Collecting Function Labels
- 2:46:10 - program and labels are the same entities.
- 2:49:23 - Wrong order of atoms
- 2:52:22 - Wrong amount of labels
- 2:52:48 - Successfully Compiled Module
- 2:54:15 - Parser
- 2:59:35 - Legit Programming Language
- 3:00:22 - Compiler Inside Out
- 3:01:42 - Unhardcode input/output paths
- 3:07:00 - Final Demo
- 3:09:08 - BEAM is an EZ compilation target
- 3:09:35 - Getting disappointed with gleam
- 3:10:00 - Publishing the Source Code
- 3:12:30 - Outro

Пікірлер: 100
@L33tRose
@L33tRose 5 ай бұрын
Just vector and write function Just vector and write functiom Just vector and write function
@MCorange9
@MCorange9 5 ай бұрын
You are the only reason i got into actual programming, before i was just messing around in js. I started following your porth series and it was the most fun i ever had extending the language after porting it to rust
@fishsayhelo9872
@fishsayhelo9872 5 ай бұрын
holesum
@alfiegordon9013
@alfiegordon9013 5 ай бұрын
​@@fishsayhelo9872try finger, sum hole
@MCorange9
@MCorange9 5 ай бұрын
@TigranK115 yes
@gorenbk
@gorenbk 5 ай бұрын
whats the port called?
@sanjaux
@sanjaux 5 ай бұрын
He was the only reason I got into actual programming, before I was just messing around in JS. Now I'm just messing around in JS.
@JekasObps
@JekasObps 5 ай бұрын
"repeat after me... just vector and write function, bada beam, bada boom..." hilarious af
@size_t
@size_t 5 ай бұрын
I love the roasting of some random js/framework Andy's
@robheusd
@robheusd 5 ай бұрын
YAPL - Yet Another Programming Language.....
@victorguidi6223
@victorguidi6223 5 ай бұрын
“I can do that and you cannot” really hit that hard lol
@mofekayode8944
@mofekayode8944 5 ай бұрын
what timestamp ?
@0ia
@0ia 5 ай бұрын
@@mofekayode89440:33
@Lewdovico
@Lewdovico Ай бұрын
0:33
@Mozartenhimer
@Mozartenhimer 5 ай бұрын
Just vector and write function.
@houssembousmaha3615
@houssembousmaha3615 5 ай бұрын
Sssshhhh, just vector and write function, repeat after me, just vector and write function. Tsoding is the teacher we never had, saving us from monster unnecessarily complex software, 💓
@execute214
@execute214 5 ай бұрын
dang, you did a good job man! I've made a programming language myself but never thought of it when generating bin modules lol.
@lucaspalomodevelop
@lucaspalomodevelop 5 ай бұрын
here we go again 🤪
@pokefreak2112
@pokefreak2112 5 ай бұрын
That BD logo with white text on red(-ish) background made me think of something else for a second there 😳
@omglynx
@omglynx 5 ай бұрын
Bada Dragon
@Simple-EDU
@Simple-EDU 5 ай бұрын
wtf bro
@FaraazAhmad
@FaraazAhmad 5 ай бұрын
Btw thanks for providing timestamps on a 3+ hr stream
@defnlife1683
@defnlife1683 5 ай бұрын
Porth took me down the Forth rabbit hole and it's actually not that bad. I kinda like it a lot. very different. now a beam lang? omfg
@MrPetzold123
@MrPetzold123 5 ай бұрын
Woah, you are starting to be real productive in Rust, even though it still sometimes hits your nerve 💪. Also, Erlang VM looks like a really nice compilation target 👍.
@axelandru9346
@axelandru9346 2 ай бұрын
There is so much to say to you man ! It is a pleasure to listen to your streams and discover how your brain works. You are a wondefully talented engineer ! Thanks for the emulator implementation concept, that was interesting to find out ! Keep it going ! Much love from Romania !
@MrCortey
@MrCortey 5 ай бұрын
Thanks for all this information and methods for exploring interesting topics! Been watching all your videos. I like the way you learn something and explain what you understood from it! It is what it is and it isn't what it isn't 😂👍
@Humble_Electronic_Musician
@Humble_Electronic_Musician 4 ай бұрын
This is extremely interesting content! Thank you for making KZfaq a better place!
@iglobrothers645
@iglobrothers645 5 ай бұрын
You're like the only real reason I open KZfaq everyday in hopes you have a new video ❤
@Crux161
@Crux161 5 ай бұрын
The only reason to install Twitch- but KZfaq backups are a nice substitute
@rafagd
@rafagd 5 ай бұрын
39:56 - I think in practice we're not running stuff on ring 0 or less, so some stuff may break, would be my guess. And UEFI may make things awkward.
@kamertonaudiophileplayer847
@kamertonaudiophileplayer847 5 ай бұрын
I implemented also a new language in Rust a year ago. I'm glad to see you do the same.
@user-nt1uf4gl1i
@user-nt1uf4gl1i 5 ай бұрын
Hi tsoding, Awsome content as usual. Thank you.
@Deemo_codes
@Deemo_codes 5 ай бұрын
IIRC the elixir compiler generates erlang AST then hands it off to the erlang compiler. The idea being, why reinvent the wheel
@TsodingDaily
@TsodingDaily 5 ай бұрын
lol
@Ilyas_Alrai
@Ilyas_Alrai 5 ай бұрын
tsoding starts a new programming language every 10 sec
@rupen42
@rupen42 2 ай бұрын
Cargo is nice not only for dependencies but also to get rust analyzer (lsp) to understand the project.
@mikumikudice
@mikumikudice 5 ай бұрын
u could encode in the program usize value some kind of tag also to tell if the value is a literal or an index to an scope, and then keep the same structure when generating the functions' instructions
@JamesSjaalman
@JamesSjaalman 5 ай бұрын
Coding this in C would be much simpler. You are a braver man than I, Tsoding!
@OneSaile
@OneSaile 5 ай бұрын
i learn a lot with the videos of this guy
@sukina5066
@sukina5066 5 ай бұрын
17:13 ui.beam....
@peterklaus4436
@peterklaus4436 5 ай бұрын
bada beam... Ingenious
@hereticstanlyhalo6916
@hereticstanlyhalo6916 5 ай бұрын
Wow... I've been designing a custom language of mine abbreviated as BS (not the cuss word lol)... and the syntax looks RLLY similar to this... that's crazy... ofc other languages use a similar syntax like TypeScript... but damn... I saw this video and just was amazed how close my language is this this one LOL
@random_guy1024
@random_guy1024 5 ай бұрын
BD is for Bang-ladesh 🇧🇩 Cool video, you’ve earned a new subscriber ❤️
@N0RT0X
@N0RT0X 5 ай бұрын
The first minute goes hard
@MisterCallox
@MisterCallox 5 ай бұрын
is it me or since 1080p enhanced bitrate is available ( this video at least ) the regular 1080p downgraded A LOT ? Or maybe you changed your upload settings ?
@nikeedev
@nikeedev 5 ай бұрын
Zozin scared my programming language knowledge fourth time, and I only managed to create a lexer…
@SimGunther
@SimGunther 5 ай бұрын
Ts-rust-zig-deez project is very good to look at monkeyscript implementations in all kinds of different languages to get you started on the rest of the phases ;)
@glowiak3430
@glowiak3430 5 ай бұрын
Will it have a raylib binding?
@BenjaminScherrey
@BenjaminScherrey 5 ай бұрын
42:30 re: Erlang is not a stack machine. Historically, the first Erlang VM was written in Prolog. The first real Beam was done in C as a stack machine. The "latest" Beam is a register based machine but you can definitely still smell its stack heritage. I think for something that wants to super efficiently implement the actor concurrency model, stack machines are pretty much ideal. Forthwrights know how to keep their stacks shallow and efficient. I really wish they would have kept 100% to the stack machine model with Beam but the belief at the time was CPUs were being super optimized for register models. Don't think that belief is going to age too well eventually.
@reinettetinekerr219
@reinettetinekerr219 5 ай бұрын
bada-beam bada-boom 😆
@MrCortey
@MrCortey 5 ай бұрын
Missed opportunity bada:boom().
@ecosta
@ecosta 5 ай бұрын
1:06:05 - Erlang is powerful, but error messages and docs talk to their users in very patronizing ways. Tsoding's reaction here is the same as mine when they explicitly say the reader should know floating pointers to understand part of the "Getting Started".
@lorenzojojoba2832
@lorenzojojoba2832 5 ай бұрын
Could the UTF-8 issue at 1:04:57 be because rust encoded strings as Utf8 so any other encoding and te VM tries to read it incorrectly which leads to it being a 'corrupt' file
@TsodingDaily
@TsodingDaily 5 ай бұрын
I was not using any non-ASCII characters. And an ASCII string is also a UTF-8 string.
@mattshu
@mattshu 5 ай бұрын
I need a lecture and the right feng shui, got it!
@MessageKyle
@MessageKyle 5 ай бұрын
Ah yes the "this looks awful" to know you found the right rust solution LMAO
@thisguyisnotable
@thisguyisnotable 5 ай бұрын
bro makes a new programming language every month 💀
@phamiersc2179
@phamiersc2179 5 ай бұрын
I miss porth... Alexei, please bring it back
@Simple-EDU
@Simple-EDU 5 ай бұрын
NICE
@claudiusraphael9423
@claudiusraphael9423 5 ай бұрын
Just Vector And Write Function ... Just Vector And Write Function ... Just Vector And Write Function ...
@kbityy
@kbityy 5 ай бұрын
cant wait for recruiters to start asking for 3 years of experience in this language
@19DonCorleone87
@19DonCorleone87 5 ай бұрын
Fun fact: the top-level-domain tv does not stand for "television". Rather, tv is the ccTLD for Tuvalu, the fourth-smallest island state in the Pacific Ocean. Hope you had fun
@petromudrievskyj
@petromudrievskyj 5 ай бұрын
Yeah, I also mentioned it before. It's Twitch dot Tuvalu
@eldyj
@eldyj 4 ай бұрын
3:03:01 why don't you just let Some(input_path) = args.next() else {panic!("ERROR: no input is provided")};?
@afmikasenpai
@afmikasenpai 5 ай бұрын
3:06:25 literally me
@Smrad-zp6mz
@Smrad-zp6mz 5 ай бұрын
where's porth?
@sanjaux
@sanjaux 5 ай бұрын
Now this is gaming
@judahmatende3769
@judahmatende3769 5 ай бұрын
you do know we will watch all 3 hours i won't have lunch or supper, until i see the conclusion #notfair
@Simple-EDU
@Simple-EDU 5 ай бұрын
if are you on about bro
@fishsayhelo9872
@fishsayhelo9872 5 ай бұрын
ilove tsmomdinmg
@prokras8609
@prokras8609 5 ай бұрын
how many programming language that you have made lol..
@diegorocha2186
@diegorocha2186 5 ай бұрын
chungs indeed!
@user-ne4bd3ry1n
@user-ne4bd3ry1n 5 ай бұрын
есть функция на c++ нужно ее переписать на си, и в so шку засунуть. поможете?
@lol-kb8hz
@lol-kb8hz 4 ай бұрын
i have to agree, rust does way too much when it comes to crates. i like the crate system but having a crate for every little thing and having a crate pull in 300 crates makes me want to reinvent the wheel just to have control over my program.
@spacewad8745
@spacewad8745 5 ай бұрын
ah! the Messiah is back to liberate all of us
@kibaofficial6332
@kibaofficial6332 5 ай бұрын
you know that bada was an Mobile Phone OS by Samsung? xD
@RealCatDev
@RealCatDev 5 ай бұрын
Halo!
@labsendeyshent
@labsendeyshent 5 ай бұрын
БОБР, БОБР КУР
@ekshalibur
@ekshalibur 4 ай бұрын
wa
@betapacket
@betapacket 5 ай бұрын
ok
@theoDSP
@theoDSP 5 ай бұрын
about time lol
@ibrahim-tech
@ibrahim-tech 5 ай бұрын
BD is a type of cigarette in India
@kyuss0x1
@kyuss0x1 5 ай бұрын
Ι become a fun
@ikefir
@ikefir 5 ай бұрын
Should have picked C. No one understands it and those who do are not addicted to soy.
@user-ck8kp8vb4l
@user-ck8kp8vb4l 2 ай бұрын
soy jokes? in this day and age? go back to 2016 lmao
@fedang
@fedang 5 ай бұрын
Bidoo programming language
@REALsnstruthers
@REALsnstruthers 5 ай бұрын
congrats on inventing the BalD programming language; well done sir 👏 👏 🫡
Paid Zig Stream
3:20:37
Tsoding Daily
Рет қаралды 84 М.
I regret doing this...
1:20:07
Tsoding Daily
Рет қаралды 61 М.
How many pencils can hold me up?
00:40
A4
Рет қаралды 18 МЛН
OMG 😨 Era o tênis dela 🤬
00:19
Polar em português
Рет қаралды 11 МЛН
Sigma Girl Education #sigma #viral #comedy
00:16
CRAZY GREAPA
Рет қаралды 73 МЛН
QUICK 'n' DIRTY synth tips and tricks #6: Combining Sequencer Outputs
6:59
Ambient Synths In The Wild
Рет қаралды 36
I implemented Goto in OCaml
38:41
Tsoding Daily
Рет қаралды 37 М.
Let's Create a Compiler (Pt.1)
1:11:03
Pixeled
Рет қаралды 461 М.
Super awesome Terminal UIs (TUIs) in Rust using RATATUI.rs
28:00
Easy Dev For All
Рет қаралды 1,6 М.
Virtual DOM for Your Terminal
1:44:03
Tsoding Daily
Рет қаралды 38 М.
Ok, I made C compiler in PHP (c.php Ep.01)
3:02:49
Tsoding Daily
Рет қаралды 115 М.
Data Mining in C
1:59:50
Tsoding Daily
Рет қаралды 38 М.
Compiler is All You Need - Refactoring Without IDE
1:48:19
Tsoding Daily
Рет қаралды 29 М.
How To Learn A New Programming Language
6:24
ThePrimeagen
Рет қаралды 245 М.
A Comprehensive Guide to Using Zoyya Tools for Photo Editing
0:50
Huawei который почти как iPhone
0:53
Romancev768
Рет қаралды 515 М.
The power button can never be pressed!!
0:57
Maker Y
Рет қаралды 54 МЛН
XL-Power Best For Audio Call 📞 Mobile 📱
0:42
Tech Official
Рет қаралды 773 М.
How much charging is in your phone right now? 📱➡️ 🔋VS 🪫
0:11
Kalem ile Apple Pen Nasıl Yapılır?😱
0:20
Safak Novruz
Рет қаралды 1,2 МЛН