Nowadays you can enjoy it on GCC, as it is now an officially supported frontend, after GNU Modula-2 got merged into it.
https://gcc.gnu.org/onlinedocs/gcc-15.2.0/gm2
Even available on compiler explorer to play with, https://godbolt.org/z/ev9Pbxn9K
Yes, that was a common trend across all programming languages designed by him.
That is also how P-Code came to be, he didn't want to create a VM for Pascal, rather the goal was to make porting easier, by requiring only a basic P-Code interpreter, it was very easy to port Pascal, a design approach he kept for Modula-2 (M-Code) and Oberon (Slim binaries).
With all due respect to Wirth, P-Code did not originate in a vacuum. Martin Richards's BCPL compiler, dating from the late 1960s, targeted a hypothetical OCode machine. Furthermore, although there were backends for this that generated good machine code on popular computers of the time, Richards also had a backend that generated a severely reduced instruction set, which he called Intcode. You could write an assembler and interpreter for Intcode in a few hundred lines of Fortran (I did), which meant you could have a slow BCPL implementation on a new machine in a day or so's work, and then you could write a better backend in BCPL.
I have never been able to determine whether Wirth knew of this work, but, given that Richards's 1969 BCPL paper described OCode, I suspect he was aware of it, and that it influenced his design of the Pascal-P compiler. (I am not sure when Intcode appeared, but it was present when I obtained the BCPL compiler in 1972, a year before the Pascal-P release.)
With all due respect to Martin Richards, neither did his BCPL, given that bytecodes as idea go back to compilers being developed in 1950's after FORTRAN came to be, and was already part of CPL ideas anyway.
If fact there were all operating systems written with such ideas like Burroughs B5000 in 1961, nowadays still sold by Unisys, and thanks to this approach being easily retargeted to modern hardware.
Why this "who did it first thread?" in first place?
You had commented before I created a new account, so I will just add that I have never seen Wirth claim that he or his colleagues at ETH were the originators of the idea. Moreover, this idea was already used in Wirth’s “first” language, namely Euler, which he published in 1965 while at Stanford. An even earlier example may be Schorre’s META‑II from 1964 (UCLA).
Regarding the popular opinion here that Pascal was created for educational purposes (only) - implicitly meaning not for building real, large-scale software - Wirth considered these two characteristics equivalent, and in his view one was a necessary condition for the other.
From the summary/abstract of his original publication about Pascal (The Programming Language Pascal) written in 1970 and published in Acta Informatica in 1971:
In view of its intended usage both as a convenient basis to teach programming and as an efficient tool to write large programs, emphasis was placed on keeping the number of fundamental concepts reasonably small, on a simple and systematic language structure, and on efficient implementability.
This is interesting!
Would you mind posting links to the relevant papers?
The original paper is probably behind a paywall. But you can have a look at an excerpt (chapter 2) from the book Virtual Machines (2006) by Iain D. Craig.
https://beckassets.blob.core.windows.net/product/readingsamp...
And there's the chapter 7 in the Richard's book (1979): https://archive.org/details/richards1979bcpl/page/n131/mode/...
You will find much more information and references at the software preservation site.
https://softwarepreservation.computerhistory.org/BCPL/
Very Nice and Thank You.
Your last link (BCPL history) contains links to a lot of papers (all?) by Martin Richards one of which is (pdf) INTCODE - An Interpretive Machine Code for BCPL which i presume was what "vincent-manis" was referring to in addition to the other papers on BCPL Language/Compiler/Manuals. Seems quite comprehensive, i must say.
We really need to publicize all of Martin Richards' contributions to computer science. He seems to be one of those unsung heroes mentioned everywhere having contributed to Languages/Compilers/VMs/OSes but not that well-known.
From the site;
BCPL—the language and systems built with it—connects the first few generations of computer scientists and software engineers, spanning mainframes to minis to micros. It was driven from the UK, but with a tributary into the heart of US research institutions, where it begat C, the most popular systems programming language of all time.