Porting from Intel x86 to Power systems running Linux

1 like Updated 1/15/15, 3:39 PM by pflugTags:

Have you considered porting to Linux on a Power Systems™ server? Not sure?  The instructions below guide you through the process of porting applications from Intel x86 systems to Power systems. 

Linux on POWER: An overview for developers gives you some of the highlights of the advantages of Linux on the POWER® platform. While the information in the overview was written before the most recent Power systems became available, it is still pertinent today. Following are some relevant details for POWER7® processors.

Recommended distributions for IBM® POWER8

Not sure which Linux distribution to install? The following distributions are optimized for POWER8 systems:

Recommended distributions for IBM® POWER7 and POWER7+ systems

Not sure which Linux distribution to install? The following distributions are optimized for POWER7 and POWER7+ processor-based servers:

  • SUSE Linux Enterprise Server 11 SP1, any subsequent service packs. SLES 11 SP3 is the latest service pack.
  • Red Hat Enterprise Linux 6, and subsequent updates. RHEL 6.5 is the latest update.

Do you have an older distro? Red Hat Enterprise Linux 5 and SUSE Linux Enterprise Server 10 do run on POWER7 servers, but they will boot the server into a POWER6® compatibility mode. The latest service packs and updates from SUSE and Red Hat are always recommended.

Portability considerations

How easy is it to port my code?  Generally speaking, interpreted languages such as Python and Perl are easily portable because they rely on a specific program (the language interpreter) to make that same program run in different architectures. So, for instance, the Python interpreter in a PowerLinux machine can translate Python code  into Power instructions. A Python interpreter in a Linux x86_64 machine can translate that same Python code to Intel x86_64 instructions, and so on. 

The Java language and environment is designed to be cross-platform portable. A Java Class file does not contain any machine specific instructions. The IBM JDK handles the translation of the Java class / program to the specific machine that is running (via a Java byte code interpreter and a Just-in-time compiler).



C, C++, FORTRAN languages are compiled to instructions for a specific machine/platform. The C language in particular can expose more of the underlying machine architecture to the program and thus is less portable.

 

Migration tools to consider

Don't know what tools to use to migrate your applications?

The IBM Software Development Kit for PowerLinux provides a number of useful development tools, including the Linux Cross-platform Tool (LCT) to identify porting issues. The Linux Cross-Platform Tool is similar to the tool available from the ChipHopper Program. The Linux Cross-platform tool runs as a command line tool on an existing Intel x86 system and provides a report of potential platform portability issues. After you install the IBM SDK for PowerLinux, you can find documentation for the LCT in the README for the tool.



If you already have a Power Systems server you can used for development, you can take advantage of the graphical Migration Advisor also included in the IBM SDK for PowerLinux. The advisor uses the Eclipse C/C++ Development Tools code analysis tool. The code analysis tool locates potential migration problems within a project, such as source code that might produce different results when run on Power Systems servers. Documentation for the Migration Advisor is included in the IBM SDK for PowerLinux user guide, available in the Linux Information Center, or through the Eclipse help in the SDK.

 

IBM programs to consider

Thinking you'd like to work with IBM on your migration?

Check out IBM PartnerWorld's ChipHopper, IBM Systems Application Advantage for Linux. This program can be valuable in assessing potential porting challenges. If you are interested and if your applications and system meet the criteria, the enrollment form is the first step. On the ChipHopper page, click the link in the "Get started" section. Once the team receives the enrollment form, they will contact you for a pre-porting call to discuss the ChipHopper processes and the porting details.



IBM Migration Factory is another consideration for assistance with porting. IBM Migration Factory can help you develop a migration roadmap, an estimate of the migration effort, and a customized business case for the migration.



If you don't have access to a POWER7 server, you're welcome to look into IBM's Power Development Platform. This program offers no-charge remote access to IBM hardware, including IBM POWER7. It is recommended that you have access to a POWER7 system for testing your application. It is possible to build on older servers or distros, targeting POWER7.



Note: The IBM SDK for PowerLinux is preinstalled on images provided by the ChipHopper and Virtual Loaner Program for your immediate use.

 

Planning the migration

Here are a couple of (older) resources for the important planning stages.

 

Questions to think about

There are a number of areas that should be considered in getting ready to port to PowerLinux.

 

Installing and setting up your new system

Now, get your system installed with all of the right pieces.

Get the Service and Productivity tools, also known as RAS (reliability, availability, and serviceability) tools. These tools include hardware service diagnostic aids, productivity tools, and installation aids for Power Systems servers running Linux. You can find documentation for the tools in the Linux Information Center.

Download and install the IBM Installation Toolkit for PowerLinux, a set of tools and functions that allow you to quickly set up Linux on PowerLinux servers. The IBM Installation Toolkit documentation is located in the Linux Information Center.

Download and install the IBM Software Development Kit for PowerLinux for a free, Eclipse-based Integrated Development Environment (IDE). The IBM SDK for PowerLinux integrates C/C++ source development with the IBM Advance Toolchain for PowerLinux and classic Linux debugging and performance analysis tools. See the IBM SDK for PowerLinux user guide, available in the Linux Information Center.

If you don't plan to use the IBM SDK for PowerLinux, you should still install the latest IBM Advance Toolchain for PowerLinux, for easy access to libraries and the latest compiler technologies for Linux distributions. You can find information in the Linux Information Center.

If you're using Java, always download and install the latest IBM Java to ensure the best performance. See Tested Linux platforms and distributions for information about the latest supported distributions and platforms for Java SE 7, Java SE 6, J2SE 5.0, and J2SE 1.4.2.

 

 

Running your ported applications

► Java and Open Source infrastructure applications run on PowerLinux servers without recompilation.

Applications written either in Java or in a scripting language like PHP or Perl will "just run" on PowerLinux servers. In addition, the most popular Open Source applications such as Apache, Tomcat, MySQL, Squid, and Postfix that ship with the Red Hat and SUSE distributions for Power Systems servers will "just run" on PowerLinux servers since they have already been compiled and packaged for POWER.

 

► Customer-written applications (C/C++ and others) must be recompiled on a PowerLinux server before they will run on PowerLinux.

Recompiling your C/C+ applications is quick and easy using the IBM Software Development Kit for PowerLinux. The Eclipse-based IBM SDK for PowerLinux provides a familiar environment for x86 Linux developers. Feedback from our customers indicates that re-compiling can be as fast as just a few minutes. Tools within the IBM SDK for PowerLinux, as well as programs such as ChipHopper can help identify areas of code to improve portability.

 

You should also be aware of the ever-increasing number of applications available for PowerLinux, from both IBM and Independent Software Vendors (ISVs). The IBM Software product compatibility reports site is kept up-to-date to allow you to determine what IBM software products are compatible with PowerLinux. On this site, you can select an operating system, specify Linux as a platform, and then specify your distro and hardware to find a list of applications.

The ISV application portfolio for PowerLinux grows each month, primarily around ISVs aligned to Big Data, Industry Applications, and Open Source Infrastructure.

 

Optimizing your application performance for PowerLinux

Stop on over at Performance - Best Practices for many tips and tricks for optimizing the performance of your ported applications.

 

 


Don't forget to write! Let us know how you are doing, and how we can help, on our Message Board in the PowerLinux Community.