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

Continued re-design of paranoid mode (now called Runtime Type Check) #15437

Merged
merged 3 commits into from
Dec 2, 2024

Conversation

ziaptos
Copy link
Contributor

@ziaptos ziaptos commented Dec 2, 2024

Moving towards static implementation of the paranoid mode switch, allowing for compiler optimizations.

How Has This Been Tested?

Existing tests

Key Areas to Review

Make sure the end to end functionality is NOT changed.

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 Dec 2, 2024

@@ -29,6 +29,12 @@ pub(crate) trait RuntimeTypeCheck {
ty_cache: &mut FrameTypeCache,
instruction: &Bytecode,
) -> PartialVMResult<()>;

/// Pranoid check that operand and type stacks have the same size
Copy link

Choose a reason for hiding this comment

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

Typo in docstring: Pranoid -> Paranoid. This maintains consistency with terminology used throughout the codebase.

Spotted by Graphite Reviewer

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

@@ -29,6 +29,12 @@ pub(crate) trait RuntimeTypeCheck {
ty_cache: &mut FrameTypeCache,
instruction: &Bytecode,
) -> PartialVMResult<()>;

/// Paranoid check that operand and type stacks have the same size
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: .s in the end of docstrings

@ziaptos ziaptos enabled auto-merge (squash) December 2, 2024 14:02

This comment has been minimized.

This comment has been minimized.

This comment has been minimized.

Copy link
Contributor

github-actions bot commented Dec 2, 2024

✅ Forge suite framework_upgrade success on 010570d3b7aa20889fb5ad0e5b23800aa33f5634 ==> b3eb0afc5706df06bcc884f4048edd0423b08a26

Compatibility test results for 010570d3b7aa20889fb5ad0e5b23800aa33f5634 ==> b3eb0afc5706df06bcc884f4048edd0423b08a26 (PR)
Upgrade the nodes to version: b3eb0afc5706df06bcc884f4048edd0423b08a26
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 1411.23 txn/s, submitted: 1413.99 txn/s, failed submission: 2.76 txn/s, expired: 2.76 txn/s, latency: 2243.84 ms, (p50: 1800 ms, p70: 2100, p90: 4200 ms, p99: 5700 ms), latency samples: 122840
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 1316.19 txn/s, submitted: 1318.61 txn/s, failed submission: 2.42 txn/s, expired: 2.42 txn/s, latency: 2263.29 ms, (p50: 1800 ms, p70: 2400, p90: 4200 ms, p99: 6000 ms), latency samples: 119440
5. check swarm health
Compatibility test for 010570d3b7aa20889fb5ad0e5b23800aa33f5634 ==> b3eb0afc5706df06bcc884f4048edd0423b08a26 passed
Upgrade the remaining nodes to version: b3eb0afc5706df06bcc884f4048edd0423b08a26
framework_upgrade::framework-upgrade::full-framework-upgrade : committed: 1302.42 txn/s, submitted: 1306.22 txn/s, failed submission: 3.80 txn/s, expired: 3.80 txn/s, latency: 2289.77 ms, (p50: 1800 ms, p70: 2400, p90: 3900 ms, p99: 6300 ms), latency samples: 116640
Test Ok

Copy link
Contributor

github-actions bot commented Dec 2, 2024

✅ Forge suite compat success on 010570d3b7aa20889fb5ad0e5b23800aa33f5634 ==> b3eb0afc5706df06bcc884f4048edd0423b08a26

Compatibility test results for 010570d3b7aa20889fb5ad0e5b23800aa33f5634 ==> b3eb0afc5706df06bcc884f4048edd0423b08a26 (PR)
1. Check liveness of validators at old version: 010570d3b7aa20889fb5ad0e5b23800aa33f5634
compatibility::simple-validator-upgrade::liveness-check : committed: 13949.53 txn/s, latency: 2478.95 ms, (p50: 1900 ms, p70: 2100, p90: 3900 ms, p99: 9700 ms), latency samples: 537600
2. Upgrading first Validator to new version: b3eb0afc5706df06bcc884f4048edd0423b08a26
compatibility::simple-validator-upgrade::single-validator-upgrading : committed: 6503.13 txn/s, latency: 4312.04 ms, (p50: 4900 ms, p70: 5200, p90: 5300 ms, p99: 5400 ms), latency samples: 118200
compatibility::simple-validator-upgrade::single-validator-upgrade : committed: 6678.93 txn/s, latency: 4843.99 ms, (p50: 5300 ms, p70: 5400, p90: 6500 ms, p99: 6700 ms), latency samples: 222520
3. Upgrading rest of first batch to new version: b3eb0afc5706df06bcc884f4048edd0423b08a26
compatibility::simple-validator-upgrade::half-validator-upgrading : committed: 7283.16 txn/s, latency: 3838.71 ms, (p50: 4100 ms, p70: 4300, p90: 5200 ms, p99: 5500 ms), latency samples: 133220
compatibility::simple-validator-upgrade::half-validator-upgrade : committed: 7332.54 txn/s, latency: 4395.63 ms, (p50: 4600 ms, p70: 4700, p90: 6000 ms, p99: 6300 ms), latency samples: 245740
4. upgrading second batch to new version: b3eb0afc5706df06bcc884f4048edd0423b08a26
compatibility::simple-validator-upgrade::rest-validator-upgrading : committed: 10230.95 txn/s, latency: 2762.53 ms, (p50: 2800 ms, p70: 3300, p90: 3700 ms, p99: 3800 ms), latency samples: 179620
compatibility::simple-validator-upgrade::rest-validator-upgrade : committed: 10183.81 txn/s, latency: 3108.36 ms, (p50: 2800 ms, p70: 3600, p90: 4800 ms, p99: 5500 ms), latency samples: 333900
5. check swarm health
Compatibility test for 010570d3b7aa20889fb5ad0e5b23800aa33f5634 ==> b3eb0afc5706df06bcc884f4048edd0423b08a26 passed
Test Ok

This comment has been minimized.

Copy link
Contributor

github-actions bot commented Dec 2, 2024

✅ Forge suite realistic_env_max_load success on b3eb0afc5706df06bcc884f4048edd0423b08a26

two traffics test: inner traffic : committed: 13982.53 txn/s, latency: 2840.15 ms, (p50: 2700 ms, p70: 2700, p90: 3000 ms, p99: 4800 ms), latency samples: 5316460
two traffics test : committed: 100.07 txn/s, latency: 1974.71 ms, (p50: 1400 ms, p70: 2000, p90: 2200 ms, p99: 19400 ms), latency samples: 1820
Latency breakdown for phase 0: ["MempoolToBlockCreation: max: 2.251, avg: 1.267", "ConsensusProposalToOrdered: max: 0.319, avg: 0.294", "ConsensusOrderedToCommit: max: 0.382, avg: 0.370", "ConsensusProposalToCommit: max: 0.674, avg: 0.663"]
Max non-epoch-change gap was: 0 rounds at version 0 (avg 0.00) [limit 4], 0.90s no progress at version 2251175 (avg 0.20s) [limit 15].
Max epoch-change gap was: 0 rounds at version 0 (avg 0.00) [limit 4], 15.80s no progress at version 2251173 (avg 15.80s) [limit 16].
Test Ok

@ziaptos ziaptos merged commit 94e548c into main Dec 2, 2024
68 of 88 checks passed
@ziaptos ziaptos deleted the zi/new-type/small-runtime-check-refactor branch December 2, 2024 19:51
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