Commit Graph

556 Commits

Author SHA1 Message Date
microproofs 1075be1b71
Minor fix to optimization to actually detect vars that are just forced builtins 2025-01-17 11:34:41 +07:00
microproofs 91b6e6da31
Oops left a todo 2025-01-16 09:33:59 +07:00
microproofs ade50dd462
Clippy fix 2025-01-15 18:28:41 +07:00
microproofs a9bedda5ed
Update script context handler to do less work with only fallback. Also optimize wrapped builtins too. 2025-01-15 18:27:43 +07:00
microproofs 6d2e38851e
Push down functions that aren't dependent on the group in front. 2025-01-12 00:39:04 +07:00
microproofs 09ddec6b41
New optimization to split independent lam function applications to enable case constr to optimize further 2025-01-11 19:09:00 +07:00
microproofs d559e384ec
Handle case where write_bits is used without being applied 2025-01-11 19:08:43 +07:00
microproofs e437d70ae2
Clippy fix 2025-01-11 19:08:42 +07:00
microproofs a3a3185e5e
Conformance tests should be using NamedDebruijn comparisons not name. Also no inline remover needs to run separately from other uplc transformations 2025-01-11 19:08:42 +07:00
microproofs f7f68fbafc
Add writeBits back in and use the optimizer to utilize the list conversion 2025-01-11 19:08:42 +07:00
microproofs 19d0ec23cf
Oops did wrong comparison check on number of consecutive applies 2025-01-11 19:08:42 +07:00
microproofs 7462f1d52f
DecodeUtf8 is not error safe 2025-01-11 19:08:42 +07:00
microproofs 2c214186b6
Make sure clean up doesn't add case and constr to comp time eval. Also had fun with test_1 mint script context validator 2025-01-11 19:08:42 +07:00
microproofs 33392f1532
Add case constr for applies greater than 2 optimization 2025-01-11 19:08:41 +07:00
microproofs c1ed0dcbb5
Remove some prints and switch an uneeded isize to usize since it can't be negative 2025-01-11 19:08:41 +07:00
microproofs 19b4b9df0f
Inline now handles (if cond then body else error) patterns.
This allows conditions like ```expect x == 1``` to match performance with ```x == 1 && ...```

Also change builtins forcing to accommodate the new case-constr apply optimization
2025-01-11 19:08:41 +07:00
microproofs c130796f49
Forgot this so I was reminded when trying to deserialize Bullet 2025-01-11 19:06:43 +07:00
rvcas 3e2ca757cd
fix: remove unwrap which is causing panics closes #1073 2024-12-25 23:14:18 -05:00
microproofs 463b88413e
feat: new builtins constr_index and constr_fields for alternative fast ways to take apart Data 2024-12-13 14:15:19 +07:00
microproofs ebc7d89d5d
Comment out ExpModInteger since it's not live on testnets yet 2024-12-08 14:29:58 +07:00
KtorZ 1105dbf3c6
enable new builtins (*with gotcha)
We still need to adjust the writeBits one to work around its list<int> argument.
2024-12-07 15:43:38 +01:00
microproofs ddc58b9a65
Cargo fmt fix 2024-12-07 12:30:14 +07:00
microproofs 4d7a24234b
Clippy fix 2024-12-07 12:27:35 +07:00
microproofs 5f1f37919f
Passing conformance tests 2024-12-07 12:23:22 +07:00
microproofs a1804863dc
Remaining builtin 2024-12-06 12:17:48 +07:00
microproofs b507992172
Clippy fix 2024-12-06 11:43:05 +07:00
microproofs 86951ef19a
One last builtin to do. Also switch to using bitvec for faster and more accurate shifting 2024-12-06 11:33:45 +07:00
microproofs 91d4ecc350
Unused import 2024-12-05 11:03:42 +07:00
microproofs 9867de38b6
A few more left to finish 2024-12-05 11:03:41 +07:00
microproofs c3b6bc5bff
Implementation of a few more of the new builtins 2024-12-05 11:03:41 +07:00
microproofs 5cf3275793
Detect difference in cost model length to maintain compatability with mainnet and testnet 2024-12-05 11:03:41 +07:00
microproofs 4839273449
Continue working on new builtin cost model updates 2024-12-05 11:03:41 +07:00
microproofs befbb6ec18
Start adding implementation for new builtins 2024-12-05 11:03:41 +07:00
hade 49aa5e01a0
feat: update change#2 costmodels 2024-12-05 11:03:41 +07:00
Kasey 86ec3b2924
Fix: issue crash in code gen with incorrect column length in decision trees (#1069)
* Fix: Deeply nested assignments would offset the new columns count calculation. Now we track relevant columns and their path to ensure each row has wildcards if they don't contain the relevant column

* Add test plus clippy fix

* Clippy fix

* New version clippy fix
2024-12-05 11:02:19 +07:00
KtorZ a9675fedc6
Fix deserialization of SerializedProgram into wrong Plutus version wrappers. 2024-12-03 22:22:11 +01:00
Simon Gellis 6f1477cef7 Allow tildes in identifier names 2024-11-25 16:20:35 -05:00
KtorZ b5047d623a
Update to pallas=0.31.0 2024-11-19 14:53:36 +01:00
Kasey 4ea6fdffe8
Aiken UPLC Optimization overhaul (#1052)
* Refactor and structuring optimizations to be less computationally heavy

* Forgot to commit the new file containing the optimization do over

* Point to correct functions in shrinker2

* Split out inline_constr_ops since it adds in builtins that can then be swept up by the builtin force reduction

* Fix: issue where identity reducer was always returning true

* Forward inlining on lambdas produces better results. This is due to a forward pass being able to apply an argument that may have no_inline at the top where as vice-versa would reduce the arg first.

* Clippy and test fixes

* Clear no_inlines when inlining a function

* Convert shrinker2 to replace shrinker and update tests
2024-11-13 15:08:36 -05:00
KtorZ 93d0191489
Fix latest clippy warnings. 2024-10-25 11:27:28 +02:00
KtorZ 365b3bf5bf
Remove dead-code and clarify note. 2024-10-19 11:00:46 +02:00
microproofs 53685dd1d5
Update cost model to properly calculate integer_to_bytearray
Also fix conformance tests to match plutus
2024-10-18 13:07:51 -04:00
microproofs 9dd3ead3df
IntegerToByteString takes in the second param itself 2024-10-17 20:01:01 -04:00
Kasey d5f8d3ab78
Cost model fixes with tests (#1030)
* Finish V1 corrections and fixes to initialize cost model

* Finish V2 corrections to be inline with mainnet today
2024-09-29 22:55:18 -04:00
microproofs e8cf43d7ec
Format fix 2024-09-20 13:52:09 -04:00
microproofs eb37ed0da5
Clippy fix 2024-09-20 13:47:56 -04:00
microproofs 4f1de2d3b5
Add test for flat error when encoding bls constant 2024-09-20 13:41:58 -04:00
microproofs fa2aa0a3e8
When we find bls constants in UPLC convert them to their a hoisted compressed form with an uncompress call 2024-09-20 12:31:36 -04:00
Matthias Benkort 7155b4e45d
Merge pull request #1023 from solidsnakedev/main
Add wrap constructor to V1/V2 StakeCredential
2024-09-20 14:47:08 +02:00
microproofs 43182721f5
Update PlutusV1 cost model 2024-09-19 10:36:36 -04:00