9848795dcc
core/irrt: add exceptions and debug utils
2024-08-27 22:55:22 +08:00
d3b4c60d7f
core/irrt: comment build.rs & move irrt to nac3core/irrt
2024-08-27 22:55:22 +08:00
d9f96dab33
[core] Add codegen_unreachable
2024-08-23 13:10:55 +08:00
76016a26ad
[meta] Apply clippy suggestions
2024-08-21 13:07:57 +08:00
2cf64d8608
apply clippy comment changes
2024-08-21 11:21:10 +08:00
6d171ec284
core: Add label name and hooks to gen_for functions
2024-07-26 13:35:40 +08:00
1c56005a01
core: Reformat and modernize irrt.cpp
...
- Use anon namespace instead of static
- Use using declaration instead of typedef
- Align pointers to the type instead of the identifier
2024-07-09 13:53:50 +08:00
650f354b74
core: use C++ for irrt source
2024-07-07 14:36:10 +08:00
075536d7bd
core: Add BreakContinueHooks for gen_for_callback
2024-07-04 15:32:18 +08:00
0744b938b8
core: fix __nac3_ndarray_calc_size crash due to incorrect typing
2024-07-03 13:03:14 +08:00
8168692cc3
apply cargo fmt
2024-06-12 14:45:03 +08:00
a176c3eb70
core/irrt: Change handle_slice_indices to instead take length of object
...
So that all other array-like datatypes (e.g. ndarray) can also take
advantage of it.
2024-06-03 16:40:05 +08:00
b6ff75dcaf
core/irrt: Add support for calculating partial size of NDArray
2024-06-03 16:40:05 +08:00
5dfcc63978
core/classes: Take reference of indexes
2024-04-16 17:20:24 +08:00
87bc34f7ec
core: Implement calculations for broadcasting ndarrays
2024-04-03 00:07:31 +08:00
5ba8601b39
core: Remove ArrayValue variants of functions
...
These will be lowered and optimized away later anyways, and we have
ArrayLikeAccessor now.
2024-04-01 16:48:25 +08:00
26a01b14d5
core: Use more typed slices in APIs
2024-04-01 16:48:25 +08:00
789bfb5a26
core: Fix index-based operations not returning i32
2024-04-01 16:46:45 +08:00
f0da9c0283
core: Add ArrayLikeValue
...
For exposing LLVM values that can be accessed like an array.
2024-03-22 15:51:06 +08:00
2c4bf3ce59
core: Allow unsized CodeGenerator to be passed to some codegen functions
...
Enables codegen_callback to call these codegen functions as well.
2024-03-22 15:07:28 +08:00
c8866b1534
core/classes: Rename get_* functions to remove prefix
...
As suggested by Rust API Guidelines.
2024-03-21 15:46:10 +08:00
a94927a11d
core: Update __builtin_assume expressions
...
No dimension size should be 0.
2024-03-07 14:59:13 +08:00
3d2abf73c8
core: Replace ndarray_init_dims IRRT impl with IR impl
...
Implementation of that function in IR allows for more flexibility in
terms of different integer type widths.
2024-03-07 14:59:13 +08:00
49de81ef1e
core: Apply clippy suggestions
2024-02-23 15:41:06 +08:00
8492503af2
core: Update cargo dependencies
2024-02-23 15:41:04 +08:00
976a9512c1
core: Add const variants to NDArray element getters
2024-02-19 16:56:21 +08:00
1eacaf9afa
core: Fix IRRT argument order to ndarray_flatten_index
2024-02-19 16:37:13 +08:00
8c7e44098a
core: Fix IRRT implementation of ndarray_flatten_index
2024-02-19 16:37:13 +08:00
8470915809
core: Add NDArrayValue and helper functions
2024-01-25 15:51:39 +08:00
5ee08b585f
core: Add ListValue and helper functions
2024-01-25 15:51:39 +08:00
f1581299fc
core: Minor changes to IRRT
...
Add missing documentation, remove redundant lifetime variables, and fix
typos.
2024-01-25 15:50:53 +08:00
140f8f8a08
core: Implement most ndarray-creation functions
2023-12-22 16:29:55 +08:00
27fcf8926e
core: Implement ndarray constructor and numpy.empty
2023-12-22 16:29:54 +08:00
02933753ca
core: Apply clippy pedantic changes
2023-12-11 15:16:23 +08:00
d304afd333
meta: Apply clippy suggested changes
2023-12-11 15:16:23 +08:00
5182453bd9
meta: Remove redundant path prefixes
2023-12-11 15:16:23 +08:00
c93ad152d7
core: Codegen for ellipsis expression as NotImplemented
...
A lot of refactoring was performed, specifically with relaxing
expression codegen to return Option in case where ellipsis are used
within a subexpression.
2023-12-08 18:00:51 +08:00
08a5050f9a
core: Implement non-trivial builtin functions using IRRT
2023-11-06 12:57:23 +08:00
60ad100fbb
core: Implement and expose {isinf,isnan}
2023-11-01 18:03:29 +08:00
6dfc43c8b0
core: Add name to build_gep_and_load
2023-09-22 17:16:29 +08:00
ee1ee4ab3b
core: Replace deprecated _ExtInt with _BitInt
2023-09-22 17:16:29 +08:00
c1c45373a6
update dependencies
2023-01-12 19:31:03 +08:00
0e0871bc38
nac3core, artiq: to_basic_value_enum takes an argument indicating the expected type
2022-04-10 01:28:22 +08:00
c29cbf6ddd
nac3core: add bound check for list slice
2022-04-05 18:21:46 +08:00
718b076e50
irrt: use __builtin_alloca
2022-03-22 15:41:25 +08:00
79c469301a
basic unsigned integer support
2022-03-08 13:34:02 +08:00
323d77a455
nac3artiq: improve error message for out of range error
2022-02-28 23:09:14 +08:00
f97f93d92c
applied rustfmt and clippy auto fix
2022-02-21 18:27:46 +08:00
d9cb506f6a
nac3core: refactored for better error messages
2022-02-21 18:24:19 +08:00
6f9f455152
nac3core: list slice irrt use one function to handle var size
2022-02-07 02:09:50 +08:00