Menu
Sign In Search Podcasts Charts People & Topics Add Podcast API Pricing

Pablo Galindo

👤 Person
238 total appearances

Appearances Over Time

Podcast Appearances

I don't think this 1x is enough.

I don't think this 1x is enough.

We, as an anecdote, a small anecdote, we at PyCon, this is this big conference that happens every year. Well, there's several other ones, but the big one is in the US. So I normally just normally give like a talk every year. So especially in PyCon US, there is these people that try to transcribe live. So like people with hearing problems can read. So it's really, really cool.

We, as an anecdote, a small anecdote, we at PyCon, this is this big conference that happens every year. Well, there's several other ones, but the big one is in the US. So I normally just normally give like a talk every year. So especially in PyCon US, there is these people that try to transcribe live. So like people with hearing problems can read. So it's really, really cool.

And this year, before giving the talk, I apologized to the person. It's like, I'm really sorry about what is going to happen, but I'm not being able to speak slower. And she was like, yeah, no problem. But like, oof. She really struggled with that.

And this year, before giving the talk, I apologized to the person. It's like, I'm really sorry about what is going to happen, but I'm not being able to speak slower. And she was like, yeah, no problem. But like, oof. She really struggled with that.

Right. So the GIL is basically a ginormous lock all around Python. So when, like Python is really, you know, is the language, but it really doesn't exist, right? Like it's an abstraction. And really, normally there is a second language behind. In CPython it's C, which is, CPython is the default implementation of Python that normally people use. There are others.

Right. So the GIL is basically a ginormous lock all around Python. So when, like Python is really, you know, is the language, but it really doesn't exist, right? Like it's an abstraction. And really, normally there is a second language behind. In CPython it's C, which is, CPython is the default implementation of Python that normally people use. There are others.

But then when this program that is the Python interpreter is executing Python code, it can have multiple threads at the same time. And all these little objects that Python exposes could be mutated at the same time, which is a problem. And Python in particular, Cpython as well, and most of the implementations is reference counted.

But then when this program that is the Python interpreter is executing Python code, it can have multiple threads at the same time. And all these little objects that Python exposes could be mutated at the same time, which is a problem. And Python in particular, Cpython as well, and most of the implementations is reference counted.

This means that to decide if an object is still alive or the interpreter can actually get rid of it, we have this little number inside every object that tells how many different structures or fields are using it. When this number reaches zero, we know that we can remove it.

This means that to decide if an object is still alive or the interpreter can actually get rid of it, we have this little number inside every object that tells how many different structures or fields are using it. When this number reaches zero, we know that we can remove it.

But as any person who has done some multi-threading in computer science knows, having a little number being mutated by multiple threads at the same time is not bueno. So the solution is basically to add a ginormous lock all around the interpreter. Because we don't know what the threads are doing, we need to just basically lock the entire thing.

But as any person who has done some multi-threading in computer science knows, having a little number being mutated by multiple threads at the same time is not bueno. So the solution is basically to add a ginormous lock all around the interpreter. Because we don't know what the threads are doing, we need to just basically lock the entire thing.

So this means that only one thread at a time can be accessing Python code and executing Python code. which means that you can still use threads because those threads can switch from one to the other, which is what we call concurrency. You don't need to wait until one thread finishes to start the other.

So this means that only one thread at a time can be accessing Python code and executing Python code. which means that you can still use threads because those threads can switch from one to the other, which is what we call concurrency. You don't need to wait until one thread finishes to start the other.

So they interleave, but there's no parallelism really because only one thread at a time can be executing Python code, which is a big problem in these days when we have... you know, machines with 120-something cores if you have a repair or servers, right? Or even your phone, right? Like, your phone has plenty of cores.

So they interleave, but there's no parallelism really because only one thread at a time can be executing Python code, which is a big problem in these days when we have... you know, machines with 120-something cores if you have a repair or servers, right? Or even your phone, right? Like, your phone has plenty of cores.

And right now, you're running Python on iOS, which is now, I think, by the way, this is something... Python on iOS is a thing as well.

And right now, you're running Python on iOS, which is now, I think, by the way, this is something... Python on iOS is a thing as well.