Skip to content

Commit

Permalink
update melior to 0.13 (#350)
Browse files Browse the repository at this point in the history
* poc serialize invoke

* from

* example and fixes

* clean

* add span

* progress

* clean

* clean

* invoke arg directly to jit

* finish struct

* progress

* impl array and dict

* progress

* progress removing old execute

* fmt

* todo

* dbg

* fixes

* fix native execution result

* comment out tests that dont compile

* fix some tests

* fix

* cleanup and progress

* more cleanup

* cleanup api

* fixes

* remove old values

* remove serde and unused dep

* fix bench

* fix bench

* cleaner api

* update readme

* better error handling, more conversions, more tests

* test progress

* bitwise unit test2

* Modified: src/libfuncs/bool.rs

* start ec tests, fix ecpoint

* ec_point_from_x test

* readme

* enum tests

* more tests

* felt dict entry tests

* gas test

* progress

* more tests and fix bug related to starknet args

* starknet libfuncs tests

* u8 tests

* more tests

* port u512 tests!

* fix u8 test

* u32 tests

* u64 tests

* half way done with u128 tests

* u128 tests

* u256 tests

* felt tests

* ec and casts tests

* remove some unwraps

* remove unused

* order deps

* fix make

* fix script

* update melior to 0.13
  • Loading branch information
edg-l authored Nov 21, 2023
1 parent 6356fc4 commit dc3ee4a
Show file tree
Hide file tree
Showing 21 changed files with 302 additions and 294 deletions.
215 changes: 79 additions & 136 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ id-arena = "2.2"
itertools = "0.12"
lazy_static = "1.4"
libc = "0.2.147"
melior = { version = "0.12.2", features = ["ods-dialects"] }
melior = { version = "0.13.0", features = ["ods-dialects"] }
mlir-sys = "0.2.1"
num-bigint = "0.4.4"
num-traits = "0.2"
Expand Down
6 changes: 4 additions & 2 deletions src/libfuncs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,7 @@ where
// TODO: Allow one block to be libfunc-internal.
pub fn cond_br(
&self,
context: &'ctx Context,
condition: Value<'ctx, 'this>,
branches: [usize; 2],
results: [&[Value<'ctx, 'this>]; 2],
Expand Down Expand Up @@ -361,7 +362,7 @@ where
};

cf::cond_br(
unsafe { location.context().to_ref() },
context,
condition,
block_true,
block_false,
Expand All @@ -381,6 +382,7 @@ where
/// used later on when required.
pub fn switch(
&self,
context: &'ctx Context,
flag: Value<'ctx, 'this>,
default: (BranchTarget<'ctx, '_>, &[Value<'ctx, 'this>]),
branches: &[(i64, BranchTarget<'ctx, '_>, &[Value<'ctx, 'this>])],
Expand Down Expand Up @@ -437,7 +439,7 @@ where
}

cf::switch(
unsafe { location.context().to_ref() },
context,
&case_values,
flag,
flag.r#type(),
Expand Down
Loading

0 comments on commit dc3ee4a

Please sign in to comment.