Giter Club home page Giter Club logo

neo-hypervm's Introduction

neo-hypervm

Virtual Machine for the NEO blockchain written in C++

Overview

neo-hypervm aims to be a virtual machine in C++ 100% compatible with the NEO standard.

Projects

  • Neo.HyperVM - C++ Native Virtual Machine
  • NeoVM.Interop - Interoperability for C# calls
  • NeoVM.Interop.Tests - Unit Tests
  • Neo.HyperVM.Benchmarks - Benchmarks

Installation

Visual studio (Windows Users)

For debugging the native source make sure to append the following line in **/Properties/launchSettings.json

"nativeDebugging": true

Copy binaries or create a symbolic link, also you can set NEO_HYPERVM_PATHenvironment variable with the path of the native library

cd C:\neo-hypervm\tests\NeoVM.Interop.Tests\bin\Debug\netcoreapp2.0
mkdir Windows
cd Windows
mkdir x86
mkdir x64

cd x86
cmd /c mklink Neo.HyperVM.dll C:\neo-hypervm\src\Neo.HyperVM\Win32\Debug\Neo.HyperVM.dll
cd ../x64
cmd /c mklink Neo.HyperVM.dll C:\neo-hypervm\src\Neo.HyperVM\x64\Debug\NeoVM.dll

Benchmarks

You can see the benchmarks here

Other

There is a Makefile in the root of the project. To build the VM source:

make

For cross compiling x86 from x64

apt-get install g++-multilib

Contributing

Feel free to contribute to this project after reading the contributing guidelines.

Before starting to work on a certain topic, create an new issue first, describing the feauture/topic you are going to implement and remember to use development branch.

License

  • Open-source MIT

neo-hypervm's People

Contributors

belane avatar igormcoelho avatar shargon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

neo-hypervm's Issues

Feature: Create public event handler to allow calling assemblies to receive instrumentation events from hypervm

When implementing neo-hypervm, calling assemblies will need to be able to attach an event handler(s) to receive instrumentation data created within the neo-hypervm. I think we may want two separate events raised that we could attach separate event handlers to depending on the needs of the calling / referencing assembly.

The two events I could see we need initially:

  • Logging events with various classes of event (info, warning, error, etc)
  • Performance instrumentation (timing metrics, etc)

Rename linux library

Shargon, I think linux static library must be renamed for easier use: "linux-libcrypto-x64.a" => "liblinux-libcrypto-x64.a". This "lib" prefix is very important in linux, it helps path resolution in compiling with "-L".
Congratulations, project is getting great! I'll take a deeper look in the next days/weeks/months :)

ARM support

We need to be able to compile and execute in ARM processors

Feature: Create linked list for stack and its stack items

Problem

A VM implementation needs to push and pop a lot of data. Using a stretchy buffer (which the std::list is) will need to grow a lot in a single program execution, an intensive operation.

Solution

A double linked list will significantly improve performance. We could use a single linked list, but some DROP instructions will remove list items that are not on the top of the stack. I suggest using a double linked list implementation.

Feature: c++ program stucture

As doing lots of c++ projects in the past I suggest renaming some folders to match a more "standard" way of structuring opensource c++ projects. This is what I see the most in large opensource c++ project.

|
- tests
- bench
- vendor
- interop
- src

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.