Introduce Brainf*ck, another Turing complete programming language. Then, try to implement the following from scratch: Interpreter, Compiler [x86_64 and ARM], and JIT Compiler.
Introduce Brainf*ck, another Turing complete programming language. Then, try to implement the following from scratch: Interpreter, Compiler [x86_64 and ARM], and JIT Compiler.
The document summarizes the use of LLVM for code generation when recompiling Nintendo games as native games. LLVM provides a full compiler infrastructure that can be used to generate code for various platforms from a common intermediate representation (LLVM bitcode). The document discusses using LLVM for code generation from 6502 assembly to generate native code for emulation. Optimizations available through LLVM are also discussed.
The document discusses how a "Hello World" program works behind the scenes. It covers topics like compilation, linking, executable file formats, loading programs into memory, and process creation. The key points are:
1) A C program is compiled into an object file, then linked with library files to create an executable. The linker resolves symbols and relocates addresses.
2) Executable files use formats like ELF that contain machine code, data, symbol tables, and sections. Object files have a similar format.
3) When a program runs, the OS loads pages of the executable into memory as needed and sets up the process with its own virtual address space.
4) System calls
Triton and Symbolic execution on GDB@DEF CON ChinaWei-Bo Chen
Triton and Symbolic execution on GDB is a talk about symbolic execution. It introduces Triton, a symbolic execution framework, and SymGDB, which combines Triton with GDB to enable symbolic execution directly within the GDB debugger. Key points include how Triton works, its components like the symbolic execution engine and AST representations, and how SymGDB utilizes the GDB Python API to synchronize Triton's state with the debugged program and allow symbolic analysis of programs within GDB. Examples demonstrating SymGDB on crackme programs that take symbolic user input are also presented.
La Unión Europea ha acordado un paquete de sanciones contra Rusia por su invasión de Ucrania. Las sanciones incluyen restricciones a las importaciones de productos rusos de alta tecnología y a las exportaciones de bienes de lujo a Rusia. Además, se congelarán los activos de varios oligarcas rusos y se prohibirá el acceso de los bancos rusos a los mercados financieros de la UE.
The document summarizes the use of LLVM for code generation when recompiling Nintendo games as native games. LLVM provides a full compiler infrastructure that can be used to generate code for various platforms from a common intermediate representation (LLVM bitcode). The document discusses using LLVM for code generation from 6502 assembly to generate native code for emulation. Optimizations available through LLVM are also discussed.
The document discusses how a "Hello World" program works behind the scenes. It covers topics like compilation, linking, executable file formats, loading programs into memory, and process creation. The key points are:
1) A C program is compiled into an object file, then linked with library files to create an executable. The linker resolves symbols and relocates addresses.
2) Executable files use formats like ELF that contain machine code, data, symbol tables, and sections. Object files have a similar format.
3) When a program runs, the OS loads pages of the executable into memory as needed and sets up the process with its own virtual address space.
4) System calls
Triton and Symbolic execution on GDB@DEF CON ChinaWei-Bo Chen
Triton and Symbolic execution on GDB is a talk about symbolic execution. It introduces Triton, a symbolic execution framework, and SymGDB, which combines Triton with GDB to enable symbolic execution directly within the GDB debugger. Key points include how Triton works, its components like the symbolic execution engine and AST representations, and how SymGDB utilizes the GDB Python API to synchronize Triton's state with the debugged program and allow symbolic analysis of programs within GDB. Examples demonstrating SymGDB on crackme programs that take symbolic user input are also presented.
La Unión Europea ha acordado un paquete de sanciones contra Rusia por su invasión de Ucrania. Las sanciones incluyen restricciones a las importaciones de productos rusos de alta tecnología y a las exportaciones de bienes de lujo a Rusia. Además, se congelarán los activos de varios oligarcas rusos y se prohibirá el acceso de los bancos rusos a los mercados financieros de la UE.
17. 関数定義
def により定義
引数, 返り値ともに Python オブジェクト
Python から呼び出せる
cdef により定義
引数, 返り値ともに C 変数 (Python オブジェクトも含む)
Python から呼び出せない
def integrate(double a, double b, int N):
# 引数, 返り値は自動的に型変換される
cdef int i
cdef double s, dx
s = 0; dx = (b - a) / N
for i in range(N):
s += f(a + i * dx)
return s * dx
cdef float f(double x) except *:
return 1 / x
17 / 39
18. 拡張型
cdef class Interval:
cdef public float x0, x1
def __init__(self, x0, x1):
self.x0 = x0; self.x1 = x1
@property
def length(self):
return self.x1 - self.x0
def widen(Interval i not None, r):
i.x0 *= r; i.x1 *= r
ビルトイン型, 拡張型を継承できる. 多重継承はできない.
アトリビュートには public, readonly を指定できる
拡張型の値は None を取りうる
拡張型の引数には not None を指定できる
<MyClass?> は型チェック付きキャスト
18 / 39