From PHP to Rust: Part I — What is a system language?

From being on taxis to travel around the city, to your own car for going anywhere.

Going deep. Going hard.

Rust is a system language. It’s very different to PHP, which is a interpreted language:

  1. Opcache and the next JIT engine in PHP 8 may speed up things.
  2. PHP is a web-bound language.

Rust for dummies

Most of your coding work that goes into Rust, like you would using C++ or any other similar language, it’s finally compiled into a single binary, which depending on what you do, may take some megabytes. That binary (or “executable”) is bound to the system architecture (x86–64, ARM, RISC-V, for example) and the operative system kernel (Windows, Linux, MacOS, Android, iOS).

The PHP stack on Rust

The “PHP” stack is mostly comprised of having a web-server, like NGINX or Apache, the PHP interpreter running behind of it with a network socket, and the PHP files to read.

A system language

Let’s start with the basic: PHP is an interpreted language. Everytime you write a PHP file, is expected to be picked up by the PHP Interpreter and transform it to machine code, at least once. These files are useless if the PHP interpreter can’t picked them up.

Graphic Designer graduate. Full Stack Web Developer. Retired Tech & Gaming Editor.