Curl Blog : May 12, 2008

Previous Next

10

Sreenu Kaimal is an MVP!

Posted by RMH May 12, 2008

I'm very proud to announce that Sreenu Kaimal (picture attached), a software developer in India, has been nominated and been awarded the status of Most Valuable Professional (MVP) in the Curl community. Sreenu is our third community member ever be awarded the status of MVP. She has good company with Robert Shiplett of the US and Friedger Müffke of Belgium as the other two MVPs.

Sreenu graduated with a Bachelors degree in Electrical Engineering. Over the past 7 years she has worked on quite a few technologies including C, C++, C#, .Net Compact Framework, PocketPC, Windows Mobile applications, device drivers, etc. Sreenu's acquaintance with Curl began with an evaluation project done on RIA technologies. Sreenu says, "I was impressed with Curl GUI Toolkit (even though not flashy like others), customizable layouts, controls, which are superior to other similar languages. Ease of learning, even to a beginner, is what attracted me the most." However, as is true with any good MVP Sreenu is interstined in making Curl an even better platform. Sreenu told me, "There are a few areas where there is scope for improvement for Curl. For eg. "search" in the documentation. If you type in more than a word to search, results are zero!! Maybe as a Curl MVP, I can contribute a bit towards closing those gaps."

We are taking Sreenu's advice seriously and looking into ways to improve search capabilities. This is the type of proactive engagement we love to see from our community. Sreenu is going to make an excellent MVP and ambassador for Curl. She is also applying her expertise in the Curl platform to help other developers on our forum. Please join me in extending a warm congratulations to our latest MVP, Sreenu Kaimal of India!

Congratulations Sreenu!

10 Comments 0 References Permalink
11

Curl outperforms ActionScript by a factor of 8 to 10


Curl was designed from the beginning so that Curl programs could be compiled to very high quality native code. We have always been proud of the performance of Curl programs, and have made claims of "unmatched performance".

Performance claims should be substantiated by repeatable tests. So we decided to do a performance comparison to quantify how two platforms compare when executing some computationally demanding code.

One of the new components in the Flex 3 Framework is the JPEGEncoder class. That functionality is used to good effect in the AIR SalesBuilder demo to drop a "snapshot" of the dashboard display onto the users desktop. However, the Salesbuilder demo script does warn about a delay when you start dragging.

JPEG encoding seems like an ideal test case since it's a computation that many people do all the time, which makes this computation more interesting than any synthetic benchmark. At the same time, this computation really measures the inherent performance of the language that the algorithm is written in, because even the inner loops are all written in the same language: there is no escape to library routines that might be written in a different language with different performance properties.

In fact, the original motivation for implementing a JPEG encoding algorithm in ActionScript was to illustrate the substantial performance improvements achieved in ActionScript 3 compared to earlier versions.

So we translated this ActionScript program to Curl in the straightforward way and compared the resulting performance for three images ranging from small to moderately large. These are the results that we observed:

  Curl time Flex time Image size Megapixels Output file size
Small image 0.16 seconds 1.72 seconds 700 x 933 0.65 72 kB
Medium image 0.46 4.43 1170 x 1560 1.83 195 kB
Large image 1.36 11.69 2560 x 1920 4.92 511 kB


The performance comparisons were done between Curl version 6.0 and Flex 3, running on a Dell XPS M170 computer (2.26 GHz, 2 GB RAM, Windows XP SP2).

These results show that Curl retains a substantial advantage in raw execution speed, by a factor of about 8 to 10. We attribute this mainly to the fact that ActionScript is derived from a language that was not architected to be able to be compiled to efficient code, while the Curl language was.

This difference will be important in any application that needs to do data processing or visualization specified by logic in the application itself, which cannot be delegated to predefined, optimized libraries that are already included in the underlying platform.

From the viewpoint of programmer productivity, it is also interesting to note that compiling the JPEG encoder (only about 600 lines of code) took about 8 seconds for the ActionScript implementation using the Flex 3 SDK, and produced a 170 kB SWF file. The Curl implementation requires no compilation step before the 22 kB Curl file is deployed to a Web site, and the just-in-time compilation that occurs when the Curl application is used took less than a quarter of a second.

We've attached the Curl and Flex sources so you can see the exact source code that we compared, if you are curious.

We look forward to your feedback and to any suggestions how this comparison study can be improved.

References


The JPEGEncoder is now part of the Flex 3 framework. The SalesBuilder demo uses an earlier, open source version, from the as3corelib project. The Curl code was transliterated from as3corelib; the reported Flex timings used the Flex3 framework.

The as3corelib code originated in an internal experiment intended to illustrate the performance advantage of the (then, new) AS3 virtual machine. That experiment adapted a free C implementation written by a Rumanian student, Cristi Cuturicu. In fact, the Flex 3 documentation references his paper about the JPEG algorithm.


Flex 3: http://livedocs.adobe.com/flex/3/langref/mx/graphics/codec/JPEGEncoder.html
as3corelib: http://code.google.com/p/as3corelib/source/browse/trunk/src/com/adobe/images/JPGEncoder.as
Original Actionscript: http://www.kaourantin.net/2005/10/more-fun-with-image-formats-in-as3.html
Original C: http://www.yov408.com/html/codespot.php?gg=47
Salesbuilder: http://coenraets.org/air/salesbuilder/salesbuilder_script.pdf

11 Comments 0 References Permalink