PeachPie PHP to .NET project reaches 1.0 milestone

Now with support for Visual Studio Code and other IDEs, the PHP-to-.NET converter runs WordPress and other apps.

PeachPie PHP to .NET project reaches 1.0 milestone

PeachPie, a project to support the PHP language natively on the .NET runtime, is now available in a 1.0.0 release, with a slew of features—including IDE support—aimed at getting developers on board.

Originally announced in 2016, PeachPie is intended to be not only a runtime for PHP on .NET, but a full development platform. It allows a legacy PHP codebase to be migrated incrementally, with two-way interaction between the PHP and .NET worlds. Many, but not all, PHP extensions are supported through PeachPie.

The PeachPie 1.0 release contains support for the commonly used 7.4 version of PHP, integration with IDEs, user-friendly error messages, and a number of other features intended to help developers adopt it. An online version of the compiler lets you try out compiling PHP code to C#, Visual Basic, or the .NET IL to get an idea of what the generated code is like. Compiling to WebAssembly is also supported.

Right now the PeachPie project makes few explicit claims about performance, with the Benchmarks section of the site listing only a few. But of those listed, PeachPie scores better than both the original PHP runtimes and the HHVM project devised by Facebook to accelerate PHP performance. The announcement blog post provides some detail about using PeachPie’s ahead-of-time compilation tool, NativeAOT, for further performance enhancement, noting the gains will vary depending on workload and the state of the original PHP code. (PHP code with type hints tends to perform better, as it allows PeachPie to perform more targeted optimizations.)

Many existing PHP applications are available in PeachPie’s catalog of applications ported to the PeachPie runtime. Among them is WordPress, arguably the most popular application written in PHP, and one of the apps most likely to benefit from the performance boosts promised by PeachPie. 

Copyright © 2021 IDG Communications, Inc.

How to choose a low-code development platform