Live data from Hacker News

Backend of Meta Threads is built with Python 3.10

twitter.com

241–250 of 458 posts

Re: Backend of Meta Threads is built with Python 3.10

#241

Earlier quoted context omitted.

They ended up compiling PHP to assembly! Facebook is a company that will go to ridiculous lengths to avoid rewrites.

Was there a separate initiative for assembly, or are you thinking about HipHop? HipHop was for C++ and got a lot of attention back when it was released.

I was thinking about HHVM, which I believed was essentially assembly for a VM. Am I wrong on that?

Re: Backend of Meta Threads is built with Python 3.10

#242
post #177
post #122

Earlier quoted context omitted.

Is your problem that the c part of GDAL isn't concurrent and you are calling it multiple times, or are you blocking on something you shouldn't? Python calling a concurrent c thing is super common. For more complex things there is multiprocessing, but that essentially is simplification of IPC.

Had a massive amount of images that I was trying to process for a specific purpose. I wound up spinning up multiple python processes within a java wrapper using concurrent linked queues. Got the job done but it's not the proudest moment of my life.

You could have done this with the multiprocessing module. It interfaces like the threading library but it's launching new processes for each "thread". I've done a shitload of image processing in Python with it. You'll end up with a 100% Python version of what you did.

Re: Backend of Meta Threads is built with Python 3.10

#243

Earlier quoted context omitted.

Was there a separate initiative for assembly, or are you thinking about HipHop? HipHop was for C++ and got a lot of attention back when it was released.

I was thinking about HHVM, which I believed was essentially assembly for a VM. Am I wrong on that?

No, you're right. HHVM was the 2nd iteration. I was thinking of the first project, which was for C++. Looking at wikipedia, that was called HPHPc.

Re: Backend of Meta Threads is built with Python 3.10

#246

For the “Python isn’t fast enough for production backend” crowd from the same company that brought you the largest social network built on PHP + MySQL.

In addition to the Facebook/PHP comments here, an often overlooked one is that Instagram was a big Python/Django shop for years (and probably still is in many parts).

Re: Backend of Meta Threads is built with Python 3.10

#247
post #227

Earlier quoted context omitted.

They ended up compiling PHP to assembly! Facebook is a company that will go to ridiculous lengths to avoid rewrites.

Rewriting in hip-tech-du-jour is for startups with lots of funding and little of traction. Why would a massively successful company toss a stick in their own spokes by tearing the product to ground?

But it's actually a _really bad_ strategy for a startup! It'll be realized the moment you try to hire for hip-tech-du-jour. Most likely, you don't even have the problem that hip-tech-du-jour claims to solve.

Re: Backend of Meta Threads is built with Python 3.10

#248

Earlier quoted context omitted.

For me, it does seem really strange since PHP (currently) is faster than Python and PHP wasn't fast enough for Facebook. But it's interesting to see how it'll play out.

Probably Python is deemed as more appealing to hipsters than good old PHP.

Python is older than PHP.

Re: Backend of Meta Threads is built with Python 3.10

#249

For the “Python isn’t fast enough for production backend” crowd from the same company that brought you the largest social network built on PHP + MySQL.

Except PHP actually is fast while Python isn't.

Except it's not. Bindings to C libraries are.

Re: Backend of Meta Threads is built with Python 3.10

#250

For the “Python isn’t fast enough for production backend” crowd from the same company that brought you the largest social network built on PHP + MySQL.

Yep, Vanilla Python isn't fast enough so they have to do more: "It's running on Instagram's #Cinder fork that includes a JIT, lazy-loaded modules, pre-compiled static modules, and a bunch of other interesting tweaks against vanilla Python 3.10" From the Tweet. Personally, I don't care what language people use. We all know that if you have money, you can just throw in more servers. Until your CFO and CTO decided that…

> We all know that if you have money, you can just throw in more servers.

Definitely not true at Facebook scale. You need to be smart, fast, _and_ throw more servers at it.

Post reply on HN