Form of instruction set designed to be run by a software interpreter
"Portable code" and "P-code" redirect here. For other uses, see software portability and P-Code (disambiguation).
This article needs additional citations for verification. Please help improve this article by adding citations to reliable sources. Unsourced material may be challenged and removed. Find sources: "Bytecode" – news · newspapers · books · scholar · JSTOR(January 2009) (Learn how and when to remove this template message)
Program execution
General concepts
Code
Translation
Compiler
Compile time
Optimizing compiler
Intermediate representation (IR)
Execution
Runtime system
Runtime
Executable
Interpreter
Virtual machine
Types of code
Source code
Object code
Bytecode
Machine code
Microcode
Compilation strategies
Ahead-of-time (AOT)
Just-in-time (JIT)
Tracing just-in-time
Compile and go system
Precompilation
Transcompilation
Recompilation
Notable runtimes
Android Runtime (ART)
BEAM
Common Language Runtime (CLR) and Mono
CPython and PyPy
crt0
Java virtual machine (JVM)
LuaJIT
Objective-C and Swift's
V8 and Node.js
Zend Engine
Notable compilers & toolchains
GNU Compiler Collection (GCC)
LLVM and Clang
MSVC
v
t
e
Bytecode (also called portable code or p-code[citation needed]) is a form of instruction set designed for efficient execution by a software interpreter. Unlike human-readable[1] source code, bytecodes are compact numeric codes, constants, and references (normally numeric addresses) that encode the result of compiler parsing and performing semantic analysis of things like type, scope, and nesting depths of program objects.
The name bytecode stems from instruction sets that have one-byte opcodes followed by optional parameters. Intermediate representations such as bytecode may be output by programming language implementations to ease interpretation, or it may be used to reduce hardware and operating system dependence by allowing the same code to run cross-platform, on different devices. Bytecode may often be either directly executed on a virtual machine (a p-code machine, i.e., interpreter), or it may be further compiled into machine code for better performance.
Since bytecode instructions are processed by software, they may be arbitrarily complex, but are nonetheless often akin to traditional hardware instructions: virtual stack machines are the most common, but virtual register machines have been built also.[2][3] Different parts may often be stored in separate files, similar to object modules, but dynamically loaded during execution.
^Cite error: The named reference Dynamic_Machine_Code was invoked but never defined (see the help page).
^Cite error: The named reference Jucs_Lua was invoked but never defined (see the help page).
^Cite error: The named reference Dalvik was invoked but never defined (see the help page).
Bytecode (also called portable code or p-code[citation needed]) is a form of instruction set designed for efficient execution by a software interpreter...
Java bytecode is the instruction set of the Java virtual machine (JVM), crucial for executing programs written in the Java language and other JVM-compatible...
make up the Java bytecode, an abstract machine language that is ultimately executed by the Java virtual machine. The Java bytecode is generated from...
as programs written in other languages that are also compiled to Java bytecode. The JVM is detailed by a specification that formally describes what is...
Python, Julia, and Ruby. A number of systems can compile Java and other bytecode languages to JavaScript and WebAssembly. These include CheerpJ, JWebAssembly...
interpreter, usually after being translated into an intermediate code, such as a bytecode, that is then interpreted. Machine code is by definition the lowest level...
machine or p-code machine can be considered an intermediate language: Java bytecode Microsoft's Common Intermediate Language is an intermediate language designed...
intermediate representation (PIR, an intermediate language) to Parrot bytecode and execute it. Parrot is free and open-source software. Parrot was started...
JIT compilation, Hack code is first transformed into intermediate HipHop bytecode (HHBC), which is then dynamically translated into x86-64 machine code,...
translate the source code into some intermediate form (often called p-code or bytecode), which is then passed to an interpreter which executes it. Programs compiled...
Applications are compiled into a format similar to machine code, known as bytecode, which is then executed by the VM. A virtualized version of a complete...
virtual machine is a special type of interpreter that interprets bytecode. Bytecode is a portable low-level code similar to machine code, though it is...
languages are interpreted by a Java program, and some are compiled to Java bytecode and just-in-time (JIT) compiled during execution as regular Java programs...
source code via the interpreter's machine code. Other technology (i.e. bytecode) incorporates both mechanisms by converting the source code to an intermediate...
collection of objects). Java Card bytecode run by the Java Card Virtual Machine is a functional subset of Java 2 bytecode run by a standard Java Virtual...
CPU. In some contexts, a file containing scripting instructions (such as bytecode) may also be considered executable. Executable files can be hand-coded...
Application virtual machines are typically used to allow application bytecode to run portably on many different computer architectures and operating...
assembly languages are not necessarily compatible with each other. eBPF bytecode has recently become a target of higher-level languages. LLVM added eBPF...
microcontroller. MicroPython consists of a Python compiler to bytecode and a runtime interpreter of that bytecode. The user is presented with an interactive prompt...
which target the CLI compile to CIL. CIL is object-oriented, stack-based bytecode. Runtimes typically just-in-time compile CIL instructions into native code...