Rate This Document
Findability
Accuracy
Completeness
Readability

Porting Advisor Functions

The Porting Advisor simplifies the application porting process and supports scanning, analysis, and porting of software from x86 Linux to Kunpeng Linux. This tool can automatically analyze applications and generate guide reports, greatly improving code porting efficiency.

When multiple modules are running concurrently, only one log level can be set at the same time.

Prerequisites

  • You have installed the Porting Advisor tool. For details, see Installing the Tool.
  • If you have installed the tool using a compressed package, decompress the package and switch to the tool directory. Then run the command in ./ mode, for example, ./devkit porting -v. If you have installed the tool using an RPM package, run devkit porting -v. This section uses an RPM package as an example.

Command Function

Displays the help information about application porting tasks.

Syntax

1
devkit porting -h

Example

Run the following command to query the parameter descriptions of all commands:

1
devkit porting -h

Command output:

1
2
3
4
5
6
7
Usage: devkit porting [-h|--help] TASK [ARGS]

  The most commonly used devkit advisor sub tasks are:
    src-mig                  Run the source migration task.
    pkg-mig                  Run the package migration task.

See 'devkit porting TASK -h/--help' for more information on a specific task.
Table 1 Function description

Subcommand

Function

Description

Supported Platform

src-mig

Source code porting

Analyzes the portability of software written in C/C++/ASM/Fortran/Go/Java/Python/Scala.

  • Checks the C/C++/ASM/Fortran/Go software build project files and provides porting suggestions.
  • Checks the link libraries used by C/C++/Fortran/Go/interpreted language software build project files and provides porting suggestions.
  • Checks the C/C++/ASM/Fortran/Go/interpreted language software source code and provides porting suggestions. The tool supports porting of Fortran source code from the Intel Fortran compiler to the GCC Fortran compiler, and checks of compiler features and syntax extensions.
  • Checks the compatibility of the SO files loaded by the Python/Java/Scala program through the ctypes module.
  • Analyzes some x86 assembly instructions and converts them into equivalent Kunpeng assembly instructions.

Kunpeng, x86

pkg-mig

Software porting assessment

Analyzes the SO library files in the software installation path in the x86 environment and checks whether these files are compatible with the Kunpeng platform.