this repo has no description
at trunk 98 lines 3.6 kB view raw view rendered
1# Welcome to Skybison! 2 3Skybison is experimental performance-oriented greenfield implementation of 4Python 3.8. It contains a number of performance optimizations, including: small 5objects; a moving GC; hidden classes; bytecode inline caching; type-specialized 6bytecode; an experimental template JIT. 7 8## Is this supported? 9 10No. 11 12Even though the project is no longer under active development internally, we've 13made Skybison publicly available in the hopes that people might find its 14history and internals interesting, or maybe even useful. It has not been 15polished or documented for anyone else's use. 16 17We cannot commit to fixing external bug reports or reviewing pull requests. 18That said, if you have experience in dynamic language runtimes and have ideas 19to make Skybison faster; or if you work on CPython and want to use Skybison as 20inspiration for improvements in CPython, feel free to open a Pull Request. 21 22Instagram is now developing 23[Cinder](https://github.com/facebookincubator/cinder/). 24 25## How do I build it? 26 27See [INSTALL.md](doc/INSTALL.md) for an overview. However, this project was 28built in an internal development environment. We cannot guarantee that this 29project will build or run on any arbitrary environment. 30 31## What's here? 32 33The project is structured in the following component directories: 34 35### `./runtime` 36 37The core of the runtime resides here. In it is all of the core types, core 38modules, bytecode interpreter, and template JIT. 39 40* `objects.[h|cpp]` - All object types. See 41 [object-model.md](doc/object-model.md). 42* `*-builtins.[h|cpp]` - Basic functionality of builtin types 43* `*-module.[h|cpp]` - Implementation of built-in modules and types correlated 44 to a module. 45* `interpreter.[h|cpp]` - Implementation of all opcodes. See 46 [execution-model.md](doc/execution-model.md). 47* `interpreter.[h|cpp]` - Bytecode interpreter. 48* `ic.[h|cpp]` - Inline cache implementation. 49* `interpreter-gen-x64.cpp` - Implementation of the assembly 50 interpreter and template JIT. 51* `heap.[h|cpp]` - Class that manages managed objects. 52* `heap-profiler.[h|cpp]` - Tool for dumping the heap in a Java heap format for 53 later inspection. 54* `scavenger.[h|cpp]` - Garbage collector. 55* `runtime.[h|cpp]` - The Runtime. This is where everything starts. 56 57### `./library` 58 59The Python library code resides here. In it is a Skybison-specific set of 60library files and their tests. It is meant to be overlaid on top of the CPython 61standard library so that imports fall back on standard library code. 62 63### `./capi` and `./ext` 64 65Our C-API emulation layer resides here. Since any C code that interfaces with 66Python's C-API expects `PyObject*` not to move, and the runtime has a moving 67GC, we have built a layer of handle objects and C-API functions. 68 69The structure inside this `./ext` is designed to mimic the CPython repo. For 70example, CPython defines `PyLong_FromLong` in `Objects/longobject.c`. In 71Skybison, this function should be implemented in `ext/Objects/longobject.cpp`. 72 73### `./third-party` 74 75We vendor several open-source projects for both testing and core functionality. 76They all reside here. Included in this list is a version of CPython, which we 77use for its Python and C library code. 78 79### `./util` 80 81Development tools and helper scripts for building and debugging. 82 83### `./benchmarks` 84 85Set of standard Python benchmarks with an accompanying test-runner. 86 87### `./doc` 88 89This folder contains documentation. 90 91## Other notes 92 93The repository has the name "pyro" sprinkled throughout the codebase. This is a 94holdover from an old internal codename. 95 96## License 97 98Please see [LICENSE](LICENSE).