Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
P-code machine
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==P-code versus machine code== While a typical [[compiler]] model is aimed at translating a program code into [[machine code]], the idea of a P-code machine follows a two-stage approach involving translation into P-code and execution by [[Interpreter (computing)|interpreting]] or [[just-in-time compilation]] (JIT) through the P-code machine. This separation makes it possible to detach the development of a P-code [[Interpreter (computing)|interpreter]] from the underlying machine code compiler, which has to consider machine-dependent behaviour in generating its [[bytecode]]. This way a P-code interpreter can also be implemented quicker, and the ability to interpret the code at runtime allows for additional [[Run-time checking|run-time checks]] which might not be similarly available in native code. Further, as P-code is based on an ideal virtual machine, a P-code program can often be smaller than the same program translated to machine code. Conversely, the two-step interpretation of a P-code-based program leads to a slower execution speed, though this can sometimes be addressed with [[just-in-time compilation]], and its simpler structure is easier to [[Reverse engineering|reverse-engineer]] than native code.
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
P-code machine
(section)
Add topic