wow I must confess that thats was a little weird intro of how you spent your free time , but it got me thinking that - maybe thats how geniuses spend their free time - coz honestly this material is awesome thank you very much!
The animation is awesome, but the overall impression of the presentation is that it's a bit shallow. For example, aren't networking calls system calls? They are. How does a `g` gets unblocked after a syscall? By itself or with a help from the scheduler? Also, you said shrinking of a stack is easy, but if we borrowed a continuous region of memory from the heap, we can't simply ask the OS to reduce its size to match the new stack, can we?
Networking calls are system calls, but if you use i.e net/http, go will manage these in a separate component net-poller, it is a interface, which is important, because the implementation of how net-poller will unblock a 'g' will depends on the actual O.S it is running.
All code needs to be put in cpu to run. Go routine is a higher level concept than OS thread. From low level to high level: CPU => Processes => OS Threads => go runtime => Goroutines
@@chriszhang8365 so does goroutines stack and os stack has anything to do with each other I'm still confused how they are combined It's great if you can give me some references Thanks for your reply
@@NguyenTuan-ek1pv The OS scheduler needs a stack for any thread that it is running. It is alot of memory though (like 2MB). The Go runtime scheduler also has a stack for every goroutine. But the scheduler keeps alot of the context for threads in the runtime memory, so that goroutine stacks are really small (like 2KB)
absolute cinema
This has become a regular refresher watch for me, the presentation style really works for me!
Thank you so much Vicki ! I could not find any resource which explains go routines in detail
This is really informative. Nice job
wow I must confess that thats was a little weird intro of how you spent your free time , but it got me thinking that - maybe thats how geniuses spend their free time - coz honestly this material is awesome thank you very much!
Thank you ကျေးဇူးတင်ပါတယ်။
This was a fantastic video, thank you!
nice and concise!
that was really helpful, thanks!
The animation is awesome, but the overall impression of the presentation is that it's a bit shallow. For example, aren't networking calls system calls? They are. How does a `g` gets unblocked after a syscall? By itself or with a help from the scheduler? Also, you said shrinking of a stack is easy, but if we borrowed a continuous region of memory from the heap, we can't simply ask the OS to reduce its size to match the new stack, can we?
Networking calls are system calls, but if you use i.e net/http, go will manage these in a separate component net-poller, it is a interface, which is important, because the implementation of how net-poller will unblock a 'g' will depends on the actual O.S it is running.
Hi, why does Goroutine needs an OS thread to run on?
Can it run without OS thread?
Thank you.
All code needs to be put in cpu to run. Go routine is a higher level concept than OS thread. From low level to high level: CPU => Processes => OS Threads => go runtime => Goroutines
@@chriszhang8365 so does goroutines stack and os stack has anything to do with each other
I'm still confused how they are combined
It's great if you can give me some references
Thanks for your reply
@@chriszhang8365 The importance of this reply cannot be overstated.
@@NguyenTuan-ek1pv The OS scheduler needs a stack for any thread that it is running. It is alot of memory though (like 2MB).
The Go runtime scheduler also has a stack for every goroutine. But the scheduler keeps alot of the context for threads in the runtime memory, so that goroutine stacks are really small (like 2KB)
i fell i love...
strange comment
I fell in love with goroutines too, they are really great!
Creepy