I was looking at some of the comments on Seif’s blog post and I thought that something needs to be addressed.
1. C is an awesome language and its very very fast but its not the easiest to learn.
2. Python and Ruby are easy to learn but not fast.
Some people suggested moving all the work that Zeitgeist have done so far (and its a lot at this stage) and port it to Vala or C. It would be not only lots of work but why bother, we are going into a new era of computing, one that the languages dont exactly matter because computers are getting faster. Python doesnt need to be the fastest it just needs to be nice to program in. C will be the fastest language for a long time because its the most mature, its older then me (which isnt saying much, a lot of languages are older than me) but outside of college work or maybe helping out with bugs I dont plan on using C because its not programmer friendly. (I might use Vala when it matures but that wont be for a year or two)
We will get more developers if we advertise that all programmers are welcome here. In the repo we have almost every language in use today. If your a Mac developer we have Objective-C, if your a Windows developer we have C# and VB.Net, if your a web developer you can use JavaScript with Gnome-Shell, if you dont know how to program yet then we have lots of Python tutorials around for opportunistic developer week. So go out and have fun
Oh the old computers are getting faster thing. Well, I say computers are on their way out and mobile phones are the computers for most people on the planet.
And languages matter, everytime I try to use a java application on my netbook I cringe because it is sooo slow. Python is better, but what I suggested was porting GAJ to Genie ( http://live.gnome.org/Genie ) not Vala and certainly not C.
Genie is fairly similar to Python and much much faster, albeit not as mature that is why I asked for a slow migration.
If Gnome wants to run on really cheap mobile devices (ARM7/ARM11, MIPS) it has to drop Mono, Python etc.
Actually phones are getting a lot faster too some smart phones go nearly 1ghz now so its not too bad.
Pingback: Shane Fagan: Do the language that you like | TuxWire : The Linux Blog Aggregator
I think discussions (and wars) about languages are not that bad. Besides being fun, they help the community shape its future and converge on the “best” languages. It’s great you’re open to any language, but then differences remain. And incompatible implementations. And duplicate efforts too.
Well discussions are good but each to their own. I love python myself and started on Java.
It’s easy to assume that Python apps are slow, and that C apps are fast. However, this is often not true. Many Python apps use underlying libraries that are fast, and the Python code is then just glue code for fast code, so the apps are fast.
It’s also quite easy to write slow apps in C. If you write a bubble sort to sort thousands of records, it will be slow, even in C.
It’s best to choose a language you are comfy with. Reuse existing good libraries, and profile before you optimize.
Cheers, Rick
People used to think that the “the number of transistors on a chip doubles every 18 months” thing meant “the speed doubles every 18 months.” And for a while it seemed true. We hit the heat wall in 2003. Processors are NOT increasing in speed anymore. 3GHz is still about the maximum speed you’ll find on a processor. No, computers are NOT getting faster.
What’s changed is that now we have mutli-core CPUs. These are ONLY advantageous if you have multi-threaded programs. And guess what? Python’s version of multi-threaded is to lock *everything*. Essentially, you may *think* you’ve got two threads running simultaneously in Python, but really, only one thread runs at a time, so no, it doesn’t go any faster.
You want a language that’s made to do parallel programming and do it right? You want Erlang.
Well ok python isnt good with threading but really most languages arent. If I remember right Python 3 does threading ok.
Weeeell it’s not really as easy as just saying “This language is better than the other.” Each language is suited for different things and different situations. A lot of times it could just be the chosen algorithm that is the bottleneck, or perhaps you would get really fast code with one language but it would require a lot of effort and man hours such that it isn’t worth it.
If the code works, it’s nice and maintainable, and reasonably fast for the target platforms then by all means. It’s all a part of a grand design, really, where you have to account for these different factors, and if the code you love so much doesn’t work for a particular purpose, you might even have to switch to a language with better performance/paradigm/libraries/code size/etc.
As a developer myself who has coded in numerous languages, I find it important not to to dismiss speed of execution using the “computers are getting faster” argument. Good algorithms and designs are definitely crucial to ensure speed, but also getting it “for free” because you choose one language over another is a consideration.
Maintainability/ readability of python vs C is not an issue in a software house with experienced developers and rigorous coding standards and practices. In this case, using python (as an example), just because it prototypes quicker and can cut development costs, might not be the answer.
I have frequently had to rewrite scripting language code into alternatives when volumes of data processing increased. Sure, the execution speed is pretty similar with 10 000 records in a database, but when you do a millions of rows or have many concurrent users hitting a database or server, speed is crucial.
One of the reasons why some Linux apps feels slow to me is the fact that they are written in scripting languages with toolkit gui’s. It takes us back to the days when they invented Visual Basic on Windows and we were assaulted with 1000′s of frontends.
The opportunistic developer efforts to encourage new developers to get people coding and contributing is a great initiative, but I for one hope that we don’t depend on python (and others) to shape application development for the linux desktop.
just my 1c (bloody economy)
My thoughts exactly, but I think with Vala and Genie Gnome is on the right track. Once Genie is mature most of the new opportunistic devs could make the switch and applications would starter fast and memory usage would drop.
I’m wondering: are there any profiler results available indicating that Python is responsible for slowdown in Zeitgeist and that rewriting it i n C would significantly improve performance?
You wouldn’t rewrite the whole thing anyway. That’d be a ridiculous time investment. I’m told the usual thing to do with slow Python apps is profile them then rewrite the bottlenecks in something like C. So if you had a function to sort something-or-other and it was called inside tightly nested loops…