forked from M-Labs/nac3
nac3embedded -> nac3artiq, README cleanup
This commit is contained in:
parent
64404bba20
commit
316db42940
|
@ -421,6 +421,17 @@ dependencies = [
|
|||
"autocfg",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "nac3artiq"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"inkwell",
|
||||
"nac3core",
|
||||
"parking_lot",
|
||||
"pyo3",
|
||||
"rustpython-parser",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "nac3core"
|
||||
version = "0.1.0"
|
||||
|
@ -437,17 +448,6 @@ dependencies = [
|
|||
"test-case",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "nac3embedded"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"inkwell",
|
||||
"nac3core",
|
||||
"parking_lot",
|
||||
"pyo3",
|
||||
"rustpython-parser",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "nac3standalone"
|
||||
version = "0.1.0"
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
members = [
|
||||
"nac3core",
|
||||
"nac3standalone",
|
||||
"nac3embedded",
|
||||
"nac3artiq",
|
||||
]
|
||||
|
||||
[profile.release]
|
||||
|
|
36
README.md
36
README.md
|
@ -1,34 +1,20 @@
|
|||
# nac3 compiler
|
||||
# NAC3 compiler
|
||||
|
||||
This repository contains:
|
||||
- nac3core: Core compiler library, containing type-checking, static analysis (in
|
||||
the future) and code generation.
|
||||
- nac3embedded: Integration with CPython runtime.
|
||||
- nac3standalone: Standalone compiler tool.
|
||||
- nac3core: Core compiler library, containing type-checking and code
|
||||
generation.
|
||||
- nac3artiq: Integration with ARTIQ and implementation of ARTIQ-specific
|
||||
extensions to the core language.
|
||||
- nac3standalone: Standalone compiler tool (core language only).
|
||||
|
||||
The core compiler would know nothing about symbol resolution, host variables
|
||||
etc. The nac3embedded/nac3standalone library would provide (implement) the
|
||||
The core compiler knows nothing about symbol resolution, host variables
|
||||
etc. nac3artiq and nac3standalone provide (implement) the
|
||||
symbol resolver to the core compiler for resolving the type and value for
|
||||
unknown symbols. The core compiler would only type check classes and functions
|
||||
requested by the nac3embedded/nac3standalone lib (the API should allow the
|
||||
unknown symbols. The core compiler only type checks classes and functions
|
||||
requested by nac3artiq/nac3standalone (the API should allow the
|
||||
caller to specify which methods should be compiled). After type checking, the
|
||||
compiler would analyse the set of functions/classes that are used and perform
|
||||
compiler analyses the set of functions/classes that are used and performs
|
||||
code generation.
|
||||
|
||||
value could be integer values, boolean values, bytes (for memcpy), function ID
|
||||
(full name + concrete type)
|
||||
|
||||
## Current Plan
|
||||
|
||||
Type checking:
|
||||
|
||||
- [x] Basic interface for symbol resolver.
|
||||
- [x] Track location information in context object (for diagnostics).
|
||||
- [ ] Refactor old expression and statement type inference code. (anto)
|
||||
- [ ] Error diagnostics utilities. (pca)
|
||||
- [ ] Move tests to external files, write scripts for testing. (pca)
|
||||
- [ ] Implement function type checking (instantiate bounded type parameters),
|
||||
loop unrolling, type inference for lists with virtual objects. (pca)
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
[package]
|
||||
name = "nac3embedded"
|
||||
name = "nac3artiq"
|
||||
version = "0.1.0"
|
||||
authors = ["M-Labs"]
|
||||
edition = "2018"
|
||||
|
||||
[lib]
|
||||
name = "nac3embedded"
|
||||
name = "nac3artiq"
|
||||
crate-type = ["cdylib"]
|
||||
|
||||
[dependencies]
|
|
@ -1,13 +1,13 @@
|
|||
from inspect import isclass
|
||||
from functools import wraps
|
||||
|
||||
import nac3embedded
|
||||
import nac3artiq
|
||||
|
||||
|
||||
__all__ = ["extern", "kernel"]
|
||||
|
||||
|
||||
nac3 = nac3embedded.NAC3()
|
||||
nac3 = nac3artiq.NAC3()
|
||||
allow_object_registration = True
|
||||
|
||||
|
|
@ -197,7 +197,7 @@ impl Nac3 {
|
|||
}
|
||||
|
||||
#[pymodule]
|
||||
fn nac3embedded(_py: Python, m: &PyModule) -> PyResult<()> {
|
||||
fn nac3artiq(_py: Python, m: &PyModule) -> PyResult<()> {
|
||||
Target::initialize_all(&InitializationConfig::default());
|
||||
m.add_class::<Nac3>()?;
|
||||
Ok(())
|
|
@ -1 +0,0 @@
|
|||
../target/release/libnac3embedded.so
|
Loading…
Reference in New Issue