Skip to content

chaomaer/cpp-jvm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

An Educational Java Virtual Machine

使用方法

准备工作

# 解压rt.jar到指定文件夹
cd ${dir-rt-extract} && jar -xvf rt.jar
# Clone a repo
$ git clone https://github.com/chaomaer/cpp-jvm
$ cd cpp-jvm

# Build cpp-jvm
$ mkdir build
$ cmake .. (如果是Mac系统,需要加-DAPPLE=1)
$ make

# 运行class文件
$ cd build/
$ ./cpp-jvm {dir-rt-extract} {path-of-class} ${name-of-class}

功能实现

  • ✅ 加载class文件
  • ✅ 字符串和数组
  • ✅ 函数调用
  • ✅ 类和对象
  • ✅ 多线程
  • ✅ monitor支持
  • ⬜ 垃圾回收GC
  • ⬜ 多亲委派类加载

About

An Educational Java Virtual Machine

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published