GPU programming coming to low-power and mobile devices – from EU Mont Blanc supercomputer to smartphones

Supercomputing and low-power computing are not normally associated; but at the SC11 Supercomputing conference the Barcelona Supercomputing Center (BSC) has announced a new supercomputer, called the called the Mont-Blanc Project, which will combine the ARM-based NVIDIA Tegra SoC with separate CUDA GPUs. CUDA is NVIDIA’s parallel computing architecture, enabling general purpose computing on the GPU.

The project’s publicity says this enables power saving of 15 to 30 times, versus today’s supercomputers:

The analysis of the performance of HPC systems since 1993 shows exponential improvements at the rate of one order of magnitude every 3 years: One petaflops was achieved in 2008, one exaflops is expected in 2020. Based on a 20 MW power budget, this requires an efficiency of 50 GFLOPS/Watt. However, the current leader in energy efficiency achieves only 1.7n GFLOPS/Watt. Thus, a 30x improvement is required.

NVIDIA is also creating a new hardware and software development kit for Tegra + CUDA, to be made available in the first half of 2012.


The combination of fast concurrent processing, low power draw and mobile devices is enticing. Features like speech recognition and smart cameras depend on rapid processing, and the technology has the potential to make smart devices very much smarter.

NVIDIA has competition though. ARM, which designs most of the CPUs in use on smartphones and tablets today, has recently started designing mobile GPUs as well, and its Mali series supports OpenCL, an open alternative to CUDA for general-purpose computing on the GPU. The Mali-T604 has 1 to 4 cores while the recently announced Mali-T658 has 1 to 8 cores. ARM specifically optimises its GPUs to work alongside its CPUs, which must be a concern for GPU specialists such as NVIDIA. However, we have yet to see devices with either T604 or T658: the first T604 devices are likely to appear in 2012, and T658 in 2013.

New OpenACC compiler directives announced for GPU accelerated programming

A new standard for accelerating C/C++ programming with compiler directives has been announced at the SC11 Supercomputing conference in Seattle. The new standard is called OpenACC  and has been created by NVIDIA, Cray, PGI (Portland Group) and CAPS enterprise.

OpenACC compiler directives are code annotations that enable the compiler to parallelise code while ensuring thread-safety. The big difference between OpenACC and the existing OpenMP standard is that OpenACC primarily targets the GPU rather than CPU, whereas OpenMP is generally CPU only. That said, OpenACC can also target the CPU so it is flexible; the idea is that it will adapt to the target system.


OpenACC is “defined to be interoperable with OpenMP” according to the FAQ and the OpenACC CEO hopes for some future integration, though it seems to have been developed independently which may cause some tension.

OpenACC is expected to ship during the first half of 2012 on compilers from PGI, Cray and CAPS Enterprise. The NVIDIA involvement may make you wonder whether it is GPU-specific; the answer is “maybe”. The FAQ says:

Will OpenACC run on AMD GPUs?

– It could, it requires implementation, there is no reason why it couldn’t

Will OpenACC run on top of OpenCL?

– It could, it requires implementation, there is no reason why it couldn’t

Will AMD/Intel/MS/XX support this?

– As this is just announced we can’t speak to the rate of external adoption or participation.

Will OpenACC run on NVIDIA GPUs with CUDA?

– Yes. Programmers may wish to develop some code using directives, and more sophisticated code using CUDA C, CUDA C++ or CUDA Fortra

Spot the Yes in the above! Still, you can scarcely blame NVIDIA for supporting its own GPU family; and I have been impressed with how the company works with the scientific and academic community to realise the potential of massively parallel computing.

OpenACC is about democratising parallelism, rather than advancing the state of the art. Best optimisation is obtained by more complex programming, but directives make some remarkable performance improvements easy to achieve.

Developing for Windows Phone: what’s new

One thing that is easy to overlook in all the talk about Windows Phone, Nokia, and Microsoft’s prospects against iPhone and Android, is that the Windows Phone developer platform has substantially improved with the 7.1 SDK – the phone is 7.5 but the SDK is 7.1, just to confuse you.

Here are a few highlights from the list of what’s new:

Multitasking. Apps still do not continue to run when they do not have the focus. However, Microsoft has implemented several features to make it look as if they do. This includes background agents, background audio (another kind of agent), scheduled tasks, background file transfers, and fast application switching. Although apps do not execute in the background, they do stay in memory if free space allows, so that resume is near-instant.

Silverlight 4. The version of Silverlight implemented in Windows Phone is now Silverlight 4, though there are some differences between Silverlight on the desktop and Silverlight on the phone, including the fact that there is no Silverlight in the browser.

Apps that combine Silverlight and XNA. You can now render both XNA and Silverlight content in a single combined Windows Phone app.


Visual Basic and XNA. XNA was C# only in the initial release. No longer.

Better sensor support. You can now access the compass and gyroscope, and use a combined motion API.

Socket support. Use TCP and UDP socket protocols.

Network information. This is actually critical to creating well-behaved apps. New network information classes let you get network status and capabilities. You can also register for network availability change events.

Two-sided Live Tiles. Live Tiles in Windows Phone have two sides and flip automatically, effectively giving more space to show information.

Advertising SDK. Sign up to include ads from Microsoft Advertising in your app.

IE9 WebBrowser Control. You cannot embed your Silverlight app in the browser, but you can embed the WebBrowser control in your Silverlight app, now with IE9’s fast Javascript and HTML 5 features.

Local Database. A local database API is now included in Windows Phone. Sadly this is not Sqlite; I’m guessing it is a variant of SQL Server Compact Edition. You access and manipulate data with LINQ to SQL – no Entity Framework ORM (Object Relational Mapping) on the phone, though LINQ to SQL is also an ORM framework. There is no way other than LINQ to execute SQL locally.

New Launchers and Choosers. Launchers and Choosers let your app present picklists from data stored elsewhere in the phone. You can now choose an address, invite players to a game session, show a location on a map, or show map directions.

Read-only access to Contacts and Calendar.

Encrypted credential store. This enables you to store login details securely using a built-in API.

Programmatic access to the camera. This includes real-time access to the raw frames so you can create apps that use the camera.

Pictures and Search Extensibility. This lets your app interact with the Pictures hub and with the built-in search. Users who search Bing can launch your app from the results if there are matches.

New on-screen keyboards. There are now specialist keyboards for numbers and formulae.

Additional language support including East Asia. Overall there are 16 additional cultures available including font support.

Overall it adds up to a major update for developers. If you tried the first Windows Phone SDK and found too many annoyances, it might be worth a second look.

Is this the best mobile developer platform? I had this discussion today with Keith Varty, developer evangelist for Nokia. After rather enjoying a brief go with Xcode for iOS, I am not sure; there is no simple answer. It is certainly a candidate though: you get the excellent C# language, the mature Visual Studio IDE, and strong frameworks for both form-based and gaming applications. Then again you may miss those beautiful iOS controls.

Asus Transformer Prime looks great – but I would rather have it with Windows 8

Asus has announced the Transformer Prime, a quad-core tablet which comes with a mobile dock. The tablet looks like this:


but it docks with a keyboard to become more like a laptop:


The dock includes a keyboard, USB port, SD card slot, and an additional battery. Asus claim a battery life of 18 hours for the tablet when docked, or 12 hours for the tablet alone.

Specs for the Transformer Prime include 32GB storage, 1GB RAM, micro HDMI port, front and rear facing cameras (the rear camera can take full 1080p HD video), light sensor and gyroscope, GPS, combined audio and mic-in jack, and of course wi-fi and Bluetooth.

The real star of the Transformer Prime though is NVIDIA’s new Tegra 3 SoC (System on a Chip).


Tegra 3 includes a quad-core ARM Cortex A9 CPU and a 12-core GeForce GPU, compared to its predecessor the dual-core Tegra 2 with its 8 core GPU. It also supports double the amount of RAM: 2GB rather than 1GB. Anand Lal Shimpi has a great overview here.

The Transformer Prime is set to arrive in the UK in early January with a recommended price of £499 inc VAT. It will run Android Ice Cream Sandwich.

Perhaps I have spent too much time with the Windows 8 preview over the last month, but I cannot help thinking that this would make an excellent Windows 8 tablet. I like the idea of the keyboard/dock which also forms protection for the tablet screen; with Windows and Office this might be the only device I need when travelling.

Adobe’s cloud plans: most customers will migrate, pay more, get more

I’ve been listening to some of the sessions from Adobe’s Financial Analyst meeting in New York City yesterday. Since this event was focused on financials, Adobe talked in detail about how it intends not only to win its customers over to a cloud model, but also to make more revenue from them. I found it fascinating.

First, a little background. Adobe announced its Creative Cloud at the MAX event in Los Angeles last month. I was there, and while it was obvious that the announcement was significant, I did not appreciate until yesterday how profoundly the company is changing its business model.

Adobe has its own take on what cloud computing means. There are no plans for Creative Suite – which bundles products including Photoshop, Dreamweaver, Flash and Premier Pro – to become software as a service in the manner of Google Apps or Rather, the Creative Cloud is primarily two things:

1. A new purchase model for Creative Suite and associated tablet apps, based on subscription rather than perpetual licencing.

2. A set of cloud-based services which extend the features of the desktop applications. These services include storage of your projects, synchronisation across different desktop PCs and mobile devices, font licensing, digital publishing, analytics, and website building.

There is also a community aspect. I grabbed a screen from one of the presentations, and on the right you can see that the customer has a Twitter-style “followed” and “following” count, as well as status activity reported.


In the main part of the screen, you can see the desktop apps she has installed “on this machine” – implying some link between cloud and local machine – tools “you do not have yet” which can be installed from the cloud, and a set of Android and Apple iOS touch apps also marked “click to install”.

One thing Adobe made clear to its analysts is its intention that all its Creative Suite customers will eventually move to the Creative Cloud, and that the majority of its Creative Suite business will be cloud subscription within 4 years.

Why will you move? Well, Adobe is going to reserve some benefits for subscription customers. During the Q&A at the end of the day, the execs were asked whether Adobe Edge and Muse will be in Creative Suite 6, the next major version. Edge is for designing HTML 5 animations, while Muse is for building web sites without writing code. This is what Senior VP David Wadhwani said:

We’ve announced they will be available in the CS6 timeframe. They will be available as point products, as subscriptions, and in the Creative Cloud. Our current thinking is not that we’ll be adding them to Creative Suite. Creative Cloud is what we believe adds more value to our customers and we want to continue to drive people in that direction.

It is not just adding value to customers though, it is adding value to Adobe as well. Adobe presented figures which spell this out (it was a financial meeting, remember). The example was CS 5.5 Design Premium.


This particular suite costs as much as $1,899 today if you buy a perpetual licence, or as little as $399.00 as an upgrade from CS 5 (still a perpetual licence). Adobe has a sliding scale of upgrade prices, which rise according to the age of your current version, though apparently this is changing and you will no longer get upgrade prices more than two versions back (I think this means that CS 4.x versions will not get upgrade pricing for CS 6).

The existence of upgrade prices makes calculating revenue per customer over time rather complex, because it depends how often they upgrade. CS is now on an annual release cycle, and according to Adobe this means the revenue from a perpetual licence customer might be as much as $3,894 over six years, or as little as $1,424 if they are an existing customer who upgrades just once at the beginning of that six year period.

On average, Adobe says, its perpetual licence Creative Suite customers pay $30.00 per month “over all CS suites and geographies”.

By contrast, the Creative Cloud subscription would be either $49 or $69 per month (I am not quite sure what extra you get for the $20) and over 6 years, allowing for some customers to drop out, Adobe reckons it will get $40.00 revenue per month.

In other words, it is projecting that its Creative Suite customers will pay on average 33% more under the new Creative Cloud model, than they do today.

I am not clear how dealer margins affect these figures; but Adobe did say that it will continue to work with its retail channel and partners, so that will continue at some level.

One analyst asked why customers will be willing to pay more than they do at the moment. Here is Wadhwani’s answer:

There’s a lot of new value in the creative cloud. You get all of the desktop tools as they’re ready. You get all of the touch tools. When our creative Suite customers are starting to use tablets they want automatic synchronisation and the ability to use those directly with the desktop tools. That’s one of the functions the creative cloud includes.

There’s a lot more in there around community, there’s a lot more in there around training. We’ve talked about Adobe gurus, people that are recognized names in the community participating and helping our customers with new ideas. We’ve also introduced the idea of some segments of the digital publishing suite and business catalyst and some of our publishing services being available,

And recently we’ve acquired a company called Typekit which addresses one of the biggest issues as people move to being more digital, which is how do they manage and licence fonts? That whole aggregate value is substantially more than what they get with a single version of the creative suite.

Is that worth on average 33% more? It is hard to judge as it depends on the individual customer’s pattern of work.

Whatever you think of this strategy, it is in line with something Adobe has been pushing hard in recent years, which is to drive for recurring revenue rather than one-off purchases. In fact, this is stated in the financial presentation. Apparently, 40% is already recurring revenue, but the company plans to transition the majority of overall Adobe business to recurring revenue within 4 years.

Google App Inventor not dead, MIT to offer public service in 2012

Google’s App Inventor is a visual and mostly browser-hosted development environment for Android. There is a design tool:


and a "Blocks Editor” which lets you create program logic using visual blocks:


App Inventor is a great concept but in practice most developers find it easier to use more traditional tools to code their applications. Earlier this year Google said that App Inventor would close, but that the code would be open sourced in partnership with MIT Media Labs. This is a kind of homecoming, since it was Professor Hal Abelson at MIT who proposed it as a project while on sabbatical with Google in 2008.

Google now says, in an email to App Inventor users:

Sometime in the first quarter of 2012, the Center plans to provide an App Inventor service for general public access, similar to the one Google is currently running.

Since App Inventor will continue running at Google until December 2011, this may mean only a short interval during which App Inventor will be unavailable. There will be no migration of projects though, so you have to download any existing projects and later upload them to the new service.

App Inventor is inspired by Scratch, an existing open source MIT project which is used to good effect in education.

What next for Adobe Flash? Think runtime not plugin

Adobe is stating that mobile Flash will no longer be developed:

Our future work with Flash on mobile devices will be focused on enabling Flash developers to package native apps with Adobe AIR for all the major app stores. We will no longer continue to develop Flash Player in the browser to work with new mobile device configurations (chipset, browser, OS version, etc.) following the upcoming release of Flash Player 11.1 for Android and BlackBerry PlayBook. We will of course continue to provide critical bug fixes and security updates for existing device configurations. We will also allow our source code licensees to continue working on and release their own implementations.

Although this seems like a major shift in strategy, Adobe has been moving in this direction for some time. At the MAX conference last month the company was clear that most web developers can be expected to use HTML 5 rather than Flash most of the time, reserving use of the plug-in for video, games and certain kinds of application. As for mobile, all the talk was about AIR and the captive runtime, an approach similar to the iOS packager which bundles the Flash runtime into your application so that no plug-in or additional download is required.

This approach is now explicit, and I reckon we can further conclude that if the Flash plugin for mobile is being abandoned, then the Flash plugin for the desktop is also less important than before. Mobile browsing is huge, and likely to grow, so developing web pages for Flash is unattractive other than in cases where there is an easy way to direct mobile browsers to a non-Flash alternative. Flash as a browser plugin will now decline forever, which is a good thing for web standards even if it is not necessarily a good thing for web developers, who must face the challenge of cross-browser development.

So what is Flash now? It is still Adobe’s runtime, and the client for its media services, and in that role it remains significant. Thanks to Adobe’s packaging work, you can take your Flash or Flex application and deploy it to most desktop and recent mobile platforms, though not to Windows Phone or older Android devices. Could you not use HTML 5, JavaScript and PhoneGap instead? Maybe in some cases; but Flash is a richer, faster and more consistent platform, as well as benefiting from Adobe’s design and development tools.

See also my piece for the Register: Down but not out: Flash in an HTML5 world.

Update: Added official Adobe link for statement on mobile Flash.

Adobe “shifting its business model”: more publishing, less programming

Adobe has announced a shift in its business strategy, together with the loss of around 750 employees.

So what is changing? Adobe says it will be focusing on digital media and digital marketing, while investing less in “certain enterprise solution product lines.” In line with this strategy, Adobe acquired video advertising company auditude last week.

Here are the things which Adobe says are “important elements” in its new approach:

  • Creative Suite extended with tablet apps and delivered through the cloud
  • Greater investment in HTML 5: Dreamweaver, Edge and PhoneGap
  • Flash positioned for “advanced” web, video, and mobile apps
  • Digital publishing solutions
  • Video advertising
  • Document services such as electronic contracts and signatures

So what will Adobe be doing less? This is harder to discern as the releases, naturally enough, say less about it. The key remark is that:

the company will reduce its investment, and expected license revenue, in certain enterprise solution product lines

We can conclude, I guess, that the Digital Enterprise Platform once known as LiveCycle is going to get less attention as the company focuses more on digital content and less on providing a platform for enterprise applications. I would guess that this will impact the middleware services more than things like the Flex framework and Flash Platform tools, but I am speculating. More information is coming in a financial analyst meeting tomorrow in New York.

What will it take to make Windows Phone a success?

Microsoft made a splash in New York City yesterday with a giant Windows Phone in Herald Square.


The idea I guess was to show how each “Live tile” is a window into a feature of the device, with a special emphasis on “people” – the way Windows Phone aggregates Facebook, Twitter, LinkedIn, Windows Live and more into a single feed and tile.

This is the kind of stunt you get when a huge corporation with a lot of money to spend is trying to muscle its way into a market.

Is it enough? It does feel as if Microsoft has managed the re-launch of Windows Phone better than its first effort around a year ago – the first devices went on sale in October 2010. The operating system has been tweaked, the new devices are more imaginative, and partner support seems better. I actually saw some window displays for Windows Phone in my local small town though they were gone a few days later.

It still feels as if Microsoft is fighting an uphill battle. There is not much wrong with the phones now, but what is the killer feature that will sell it alongside Android and iPhone? Personally I like the SharePoint integration, but Microsoft is still primarily going after consumers rather than business users.

There is also the matter of the tiles. They work well, but look at the photo above: are they beautiful? Not really; and it is unfortunate in some ways that all the Windows Phones look like this.

That said, I enjoyed my few minutes with an HTC Titan; it has an exceptionally large display and a great camera but does not feel too bulky, and I can see it doing well if the marketing is right. Nokia’s Lumia 800 looks good too.

Microsoft came late into this market though, persevering with its old Windows Mobile for too long, and it is not going to be easy to catch up.

Eclipse and Xtend: some confusion in getting started

Last weekend there was some publicity around Xtend, an Eclipse project which extends Java with new language features. Xtend now has a new landing page, as announced by the lead architect Sven Efftinge.

I did intend to post about this yesterday, but I wanted to see it in action first, so I tried to download it and have a look. I believe this is a case where those who wrote the new landing page are too close to the project and made some assumptions, because I did not find it obvious how to proceed.

If you follow the Download link you are invited to paste one of the three URLs into the Eclipse update manager.


As a newcomer to the project, I did not want three URLs to choose from, I wanted just one. I picked Release as in general this one is likely to work.

Now, the instructions say:

To install the Xtend plugins open the update manager and paste one of the URLs on the right into the field ‘Work with’ and select the Xtend SDK.

The update manager actually presents you with a long list of updates, none of which say Xtend. I took a stab at what I thought was the right thing.


The All-In-One includes the Xtend SDK, which is what I want, right?

Wrong. After installation I could not find the tutorial which the docs said would be available.

I did some messing around with Eclipse and got the occasional error like this one:


Then I realised that I should have looked under the TMF Xtext-2.1.0 tree, which is where the correct Xtend SDK resides:


Except that if you find this helpful post by  Max Rohde you will know:

The other packages need to be selected since otherwise the Xtend editors will not work.

So you should select all of TMF Xtext-2.1.0 (or the latest release). Easy when you know, but not obvious since the word Xtend does not appear in the top node of the tree.

I was then able to create the tutorial project. I opened HelloWorld.xtend and got this:


Ah, but you have read Rohde’s post so you know this is expected and that you should run this as a JUnit Test. However it does not have any output. To see some output, you have to run one of the other examples, like Xtend08_RichStrings, or perhaps add:


to the testHelloWorld() method in HelloWorld.xtend.


OK, it works.

So what is Xtend? It is essentially a code generator which lets you write in Xtend and generate Java. You can see the generated code in the tutorial project under xtend-gen.


Xtend adds some nice features: type inference, property syntax, closures, switch expressions with no fall-through, template expressions, extension methods, and multiple dispatch.

I can imagine C# creator Anders Hejlsberg smiling here, as most of this is already in C# in some form or other.

But is Xtend the right way to bring these features to Java? I am not convinced so far. It is an interesting Eclipse project, but it may be more significant in speeding the implementation of features like these into Java itself, than as a mainstream approach to writing applications. Xtend is a kind of hybrid approach, where you will be switching between Java and Xtend while you code and debug your application, and I suspect it would get frustrating.

There is also the question of widespread community support – beyond Eclipse.

Finally, it would be good if the new landing page could be made more helpful for those getting started.