Skip to content

[mlir] Update tests after reworking deep copy and clearing procedures - #159

Merged
PavelKopyl merged 1 commit into
mainfrom
kpv-outline-copy
Aug 8, 2026
Merged

[mlir] Update tests after reworking deep copy and clearing procedures#159
PavelKopyl merged 1 commit into
mainfrom
kpv-outline-copy

Conversation

@PavelKopyl

@PavelKopyl PavelKopyl commented Jul 15, 2026

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the MLIR codegen lit FileCheck tests to match recent changes in deep-copy and storage-clearing logic, including updated control-flow structure and loop metadata in the printed MLIR.

Changes:

  • Add new regression tests for free-function recursive-struct deep-copy and large static-array clearing (both init-MLIR and EVM MLIR pipelines).
  • Refresh expected MLIR output across multiple existing EVM tests to reflect new CFG shapes (new/basic-block renumbering) and loop unroll/annotation metadata.
  • Introduce/expect new helper routines in emitted MLIR (e.g., string copy/tail-clearing helpers) where the lowering now factors out logic.

Reviewed changes

Copilot reviewed 31 out of 40 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
test/lit/mlirCodegen/free-function-recursive-struct.sol New init-MLIR test for copying a recursive struct from storage to memory.
test/lit/mlirCodegen/EVM/free-function-recursive-struct.sol New EVM-MLIR version of the free-function recursive-struct copy test.
test/lit/mlirCodegen/clear-large-static-array.sol New init-MLIR test for clearing a large static storage array.
test/lit/mlirCodegen/EVM/clear-large-static-array.sol New EVM-MLIR test for clearing a large static storage array.
test/lit/mlirCodegen/EVM/storage-packed-shrink.sol Updates expected CFG targets/basic blocks in shrink logic.
test/lit/mlirCodegen/EVM/storage-array.sol Updates loop structure and adds loop annotation metadata expectations.
test/lit/mlirCodegen/EVM/recursive-struct-packed.sol Updates clearing/copying loop CFG and adds loop annotation metadata expectations.
test/lit/mlirCodegen/EVM/recursive-struct-mapping.sol Updates clear-storage lowering expectations (looped clearing) and loop metadata.
test/lit/mlirCodegen/EVM/recursive-struct-delete.sol Updates delete/clear-storage lowering expectations and loop metadata.
test/lit/mlirCodegen/EVM/recursive-struct-copy.sol Updates clear/copy lowering expectations and loop metadata.
test/lit/mlirCodegen/EVM/mapping.sol Updates location IDs and expects a new helper for copying string data from storage to memory.
test/lit/mlirCodegen/EVM/delete.sol Updates multiple delete/clear paths to loop-based clearing with loop annotation metadata.
test/lit/mlirCodegen/EVM/chained-assign.sol Updates clearing/copy sequences and adds loop annotation metadata expectations.
test/lit/mlirCodegen/EVM/array-pop-fixed-scalar.sol Updates pop/clear sequences to loop-based clearing and adds loop metadata.
test/lit/mlirCodegen/EVM/array-pop-dyn.sol Adds expected helpers for string tail clearing and updates pop/clear CFG + loop metadata.
test/lit/mlirCodegen/EVM/array-copy-packed.sol Updates clearing/copy CFG and loop structure expectations.
test/lit/mlirCodegen/EVM/array_pop_packed.sol Updates packed-pop clearing CFG to loop-based structure and adds loop metadata.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread test/lit/mlirCodegen/clear-large-static-array.sol
Comment thread test/lit/mlirCodegen/EVM/clear-large-static-array.sol Outdated
Comment thread test/lit/mlirCodegen/free-function-recursive-struct.sol Outdated
Comment thread test/lit/mlirCodegen/EVM/free-function-recursive-struct.sol Outdated
@PavelKopyl
PavelKopyl force-pushed the kpv-recursive-structs branch 2 times, most recently from 9108da7 to 8ed6ead Compare July 23, 2026 22:40
Base automatically changed from kpv-recursive-structs to main July 23, 2026 23:03
@PavelKopyl
PavelKopyl requested a review from Copilot August 6, 2026 16:30

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 28 out of 39 changed files in this pull request and generated 2 comments.

Comment thread test/lit/mlirCodegen/EVM/chained-assign.sol Outdated
Comment thread test/lit/mlirCodegen/EVM/array-copy-packed.sol Outdated
@PavelKopyl
PavelKopyl requested a review from abinavpp August 7, 2026 00:05

@abinavpp abinavpp left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thank you!

@PavelKopyl
PavelKopyl merged commit 1d48cfb into main Aug 8, 2026
2 checks passed
@PavelKopyl
PavelKopyl deleted the kpv-outline-copy branch August 8, 2026 00:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants