Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Compiler-v2] run move_pr.sh -2 in CI #15200

Merged
merged 4 commits into from
Nov 15, 2024
Merged

Conversation

rahxephon89
Copy link
Contributor

@rahxephon89 rahxephon89 commented Nov 5, 2024

Description

This PR adds execution of the script move_pr.sh -2 to CI.

close #13750

How Has This Been Tested?

Key Areas to Review

  1. need to check updated docs and exp files;
  2. whether the script execution is flaky.

Type of Change

  • New feature
  • Bug fix
  • Breaking change
  • Performance improvement
  • Refactoring
  • Dependency update
  • Documentation update
  • Tests

Which Components or Systems Does This Change Impact?

  • Validator Node
  • Full Node (API, Indexer, etc.)
  • Move/Aptos Virtual Machine
  • Aptos Framework
  • Aptos CLI/SDK
  • Developer Infrastructure
  • Move Compiler
  • Other (specify)

Checklist

  • I have read and followed the CONTRIBUTING doc
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I identified and added all stakeholders and component owners affected by this change as reviewers
  • I tested both happy and unhappy path of the functionality
  • I have made corresponding changes to the documentation

Copy link

trunk-io bot commented Nov 5, 2024

⏱️ 2h 51m total CI duration on this PR
Job Cumulative Duration Recent Runs
rust-move-tests 31m 🟩
rust-move-tests 29m 🟩
rust-move-tests 24m 🟥
rust-move-tests 23m 🟩
forge-framework-upgrade-test / forge 22m 🟥🟥
rust-move-tests 18m 🟥
rust-cargo-deny 9m 🟩🟩🟩🟩🟩
check-dynamic-deps 5m 🟩🟩🟩🟩🟩
check 4m 🟩
general-lints 2m 🟩🟩🟩🟩🟩
semgrep/ci 2m 🟩🟩🟩🟩🟩
file_change_determinator 51s 🟩🟩🟩🟩🟩
permission-check 14s 🟩🟩🟩🟩🟩
permission-check 11s 🟩🟩🟩🟩🟩

settingsfeedbackdocs ⋅ learn more about trunk.io

@rahxephon89 rahxephon89 force-pushed the teng/update-v2-move-pr branch 2 times, most recently from 47ae154 to 60d6d51 Compare November 6, 2024 04:20
@rahxephon89 rahxephon89 changed the title [WIP][Compiler-v2] update by running move_pr.sh -i2 [Compiler-v2] update by running move_pr.sh -i2 Nov 6, 2024
@rahxephon89 rahxephon89 changed the title [Compiler-v2] update by running move_pr.sh -i2 [Compiler-v2] run move_pr.sh -i2 in CI Nov 6, 2024
@rahxephon89 rahxephon89 marked this pull request as ready for review November 6, 2024 05:25
@rahxephon89 rahxephon89 force-pushed the teng/update-v2-move-pr branch 2 times, most recently from 2179d26 to 2da6849 Compare November 13, 2024 20:39
Copy link
Contributor

@brmataptos brmataptos left a comment

Choose a reason for hiding this comment

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

I have some slight concerns that using both -i and -2 in the same run leads to more limited exercise of framework compilation with MOVE_COMPILER_V2 enabled, since we don't do a cargo clean between the two runs. Just FYI.

Copy link
Contributor

@brmataptos brmataptos left a comment

Choose a reason for hiding this comment

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

Something is better than nothing.

@rahxephon89
Copy link
Contributor Author

I have some slight concerns that using both -i and -2 in the same run leads to more limited exercise of framework compilation with MOVE_COMPILER_V2 enabled, since we don't do a cargo clean between the two runs. Just FYI.

Any suggestion on how to set the flag, e.g, just using -2? @brmataptos

Copy link
Contributor

If I really want clean results, I use 2 runs, one with -i, one with -2. We might change the script, e.g., to run cargo clean -p aptos-framework, in between the two steps. Or maybe my fears are overblown and we can just leave it. Just something to look out for.

- name: Run Aptos Move tests with compiler V2
run: cargo x targeted-compiler-v2-tests -vv --release --profile ci --locked --no-fail-fast
# Run move_pr.sh -i2
- name: Run move_pr.sh with V2 flag
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
- name: Run move_pr.sh with V2 flag
- name: Run move_pr.sh using both compiler v1 and v2 for integration tests

@rahxephon89 rahxephon89 changed the title [Compiler-v2] run move_pr.sh -i2 in CI [Compiler-v2] run move_pr.sh in CI Nov 14, 2024
@@ -12,7 +12,7 @@ module aptos_framework::aggregator_tests {
let aggregator = aggregator_factory::create_aggregator_for_test();

aggregator::add(&mut aggregator, 12);
assert!(aggregator::read(&aggregator) == 12, 0);
assert!(aggregator::read(&aggregator) != 12, 0);
Copy link

Choose a reason for hiding this comment

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

This assertion appears to be testing the wrong condition. After adding 12 to the aggregator, reading its value should yield 12. The current assertion using != will fail the correct behavior and pass the incorrect one. The assertion should be:

assert!(aggregator::read(&aggregator) == 12, 0);

Spotted by Graphite Reviewer

Is this helpful? React 👍 or 👎 to let us know.

@rahxephon89 rahxephon89 changed the title [Compiler-v2] run move_pr.sh in CI [Compiler-v2] run move_pr.sh -2 in CI Nov 14, 2024
Comment on lines +27 to +29
- name: Run move_pr.sh for integration tests with v2 compiler
shell: bash
run: third_party/move/scripts/move_pr.sh -2
Copy link

Choose a reason for hiding this comment

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

The PR description indicates that both move_pr.sh -i and move_pr.sh -2 should be run in CI, but this change only implements the -2 variant. If running both variants is still desired, consider adding a separate step for move_pr.sh -i. Otherwise, please update the PR description to match the intended implementation.

Spotted by Graphite Reviewer

Is this helpful? React 👍 or 👎 to let us know.

@rahxephon89
Copy link
Contributor Author

@vineethk @brmataptos I removed the flag -i since it is for testing compiler v1.

Copy link
Contributor

Assuming that we're testing move-compiler-v2 in some other script, sounds fine.

@rahxephon89 rahxephon89 enabled auto-merge (squash) November 14, 2024 23:08

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

Copy link
Contributor

✅ Forge suite realistic_env_max_load success on 64a75a92c46ca531d1a01a9323063b77851e1943

two traffics test: inner traffic : committed: 14258.29 txn/s, latency: 2789.85 ms, (p50: 2700 ms, p70: 2700, p90: 3000 ms, p99: 3300 ms), latency samples: 5421320
two traffics test : committed: 100.07 txn/s, latency: 1408.62 ms, (p50: 1400 ms, p70: 1400, p90: 1500 ms, p99: 1700 ms), latency samples: 1780
Latency breakdown for phase 0: ["MempoolToBlockCreation: max: 2.077, avg: 1.597", "ConsensusProposalToOrdered: max: 0.332, avg: 0.296", "ConsensusOrderedToCommit: max: 0.377, avg: 0.363", "ConsensusProposalToCommit: max: 0.671, avg: 0.659"]
Max non-epoch-change gap was: 0 rounds at version 0 (avg 0.00) [limit 4], 1.03s no progress at version 2564096 (avg 0.20s) [limit 15].
Max epoch-change gap was: 0 rounds at version 0 (avg 0.00) [limit 4], 8.50s no progress at version 2564094 (avg 8.50s) [limit 15].
Test Ok

Copy link
Contributor

✅ Forge suite framework_upgrade success on 2bb2d43037a93d883729869d65c7c6c75b028fa1 ==> 64a75a92c46ca531d1a01a9323063b77851e1943

Compatibility test results for 2bb2d43037a93d883729869d65c7c6c75b028fa1 ==> 64a75a92c46ca531d1a01a9323063b77851e1943 (PR)
Upgrade the nodes to version: 64a75a92c46ca531d1a01a9323063b77851e1943
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 1280.94 txn/s, submitted: 1283.58 txn/s, failed submission: 2.63 txn/s, expired: 2.63 txn/s, latency: 2430.28 ms, (p50: 2100 ms, p70: 2400, p90: 3900 ms, p99: 5700 ms), latency samples: 116800
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 1333.77 txn/s, submitted: 1336.22 txn/s, failed submission: 2.44 txn/s, expired: 2.44 txn/s, latency: 2274.37 ms, (p50: 2100 ms, p70: 2400, p90: 3600 ms, p99: 5400 ms), latency samples: 120080
5. check swarm health
Compatibility test for 2bb2d43037a93d883729869d65c7c6c75b028fa1 ==> 64a75a92c46ca531d1a01a9323063b77851e1943 passed
Upgrade the remaining nodes to version: 64a75a92c46ca531d1a01a9323063b77851e1943
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 1386.44 txn/s, submitted: 1388.64 txn/s, failed submission: 2.19 txn/s, expired: 2.19 txn/s, latency: 2210.92 ms, (p50: 2100 ms, p70: 2400, p90: 3300 ms, p99: 4800 ms), latency samples: 126340
Test Ok

Copy link
Contributor

✅ Forge suite compat success on 2bb2d43037a93d883729869d65c7c6c75b028fa1 ==> 64a75a92c46ca531d1a01a9323063b77851e1943

Compatibility test results for 2bb2d43037a93d883729869d65c7c6c75b028fa1 ==> 64a75a92c46ca531d1a01a9323063b77851e1943 (PR)
1. Check liveness of validators at old version: 2bb2d43037a93d883729869d65c7c6c75b028fa1
compatibility::simple-validator-upgrade::liveness-check : committed: 17451.45 txn/s, latency: 1951.86 ms, (p50: 2000 ms, p70: 2100, p90: 2200 ms, p99: 2500 ms), latency samples: 561020
2. Upgrading first Validator to new version: 64a75a92c46ca531d1a01a9323063b77851e1943
compatibility::simple-validator-upgrade::single-validator-upgrading : committed: 7342.29 txn/s, latency: 3875.41 ms, (p50: 4400 ms, p70: 4600, p90: 4700 ms, p99: 4800 ms), latency samples: 135880
compatibility::simple-validator-upgrade::single-validator-upgrade : committed: 6755.80 txn/s, latency: 4358.89 ms, (p50: 4700 ms, p70: 4700, p90: 4800 ms, p99: 5000 ms), latency samples: 251920
3. Upgrading rest of first batch to new version: 64a75a92c46ca531d1a01a9323063b77851e1943
compatibility::simple-validator-upgrade::half-validator-upgrading : committed: 7504.06 txn/s, latency: 3639.30 ms, (p50: 4100 ms, p70: 4500, p90: 5000 ms, p99: 5200 ms), latency samples: 134600
compatibility::simple-validator-upgrade::half-validator-upgrade : committed: 7789.67 txn/s, latency: 4136.39 ms, (p50: 4300 ms, p70: 4400, p90: 6100 ms, p99: 6500 ms), latency samples: 257000
4. upgrading second batch to new version: 64a75a92c46ca531d1a01a9323063b77851e1943
compatibility::simple-validator-upgrade::rest-validator-upgrading : committed: 12127.52 txn/s, latency: 2287.67 ms, (p50: 2500 ms, p70: 2600, p90: 2700 ms, p99: 2900 ms), latency samples: 214400
compatibility::simple-validator-upgrade::rest-validator-upgrade : committed: 10508.91 txn/s, latency: 2998.25 ms, (p50: 2700 ms, p70: 2800, p90: 5700 ms, p99: 7400 ms), latency samples: 369640
5. check swarm health
Compatibility test for 2bb2d43037a93d883729869d65c7c6c75b028fa1 ==> 64a75a92c46ca531d1a01a9323063b77851e1943 passed
Test Ok

@rahxephon89 rahxephon89 merged commit d7e9d70 into main Nov 15, 2024
48 checks passed
@rahxephon89 rahxephon89 deleted the teng/update-v2-move-pr branch November 15, 2024 02:17
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.

[Feature Request] run third_party/move/scripts/move_pr.sh -ti2 for any compiler change
3 participants