archon.audit.report
100.0
1,000,000 free RPC requestsJust a wallet, via x402.
Start buildingFor agent 97 on Mantle Mainnet · 2026-06-16
https://archonaudit.xyz/app/proofs
{
"chain": {
"name": "Mantle Mainnet",
"chainId": 5000
},
"report": {
"id": "04fa0b40-6c11-4553-8d8d-898c445c4de3",
"scope": {
"pragma": "^0.8.24",
"network": "mantle-mainnet",
"lineCount": 802,
"protocols": [
"mETH",
"cmETH",
"USDY",
"Aave V3",
"Merchant Moe",
"Agni"
],
"sourceKind": "paste",
"aiReasoning": {
"hits": 98,
"total": 98,
"misses": 0,
"batches": 0,
"skipped": 0,
"provider": "tokenhub",
"timeoutMs": 75000,
"fallbackCount": 0,
"providersUsed": []
},
"reducedMode": null,
"solcVersion": "0.8.24",
"gasOptimizer": {
"pricing": {
"mode": "calibrated-receipts",
"pricedAt": "2026-06-16T15:04:23.464Z",
"l2GasPriceWei": "50000100000",
"deployDataFeeMnt": "0",
"deployDataFeeWei": "0",
"calldataZeroBytes": 0,
"calibrationErrorPct": 0,
"calldataGasEstimate": 0,
"calldataNonZeroBytes": 0,
"creationBytecodeBytes": 0
},
"daPricing": {
"model": {
"mode": "calibrated-receipts",
"samples": [
{
"txHash": "0x82d99588e5f1bff33d618743025d598445493032637de25844a67aa8e88088ef",
"l1FeeWei": "699231354481640",
"l1GasUsed": "2530",
"zeroBytes": 135,
"l1GasPrice": "538782662",
"totalBytes": 228,
"blobGasUsed": "63200",
"blockNumber": "96205628",
"nonZeroBytes": 93,
"l1BlobBaseFee": "330004069609410902",
"l1BaseFeeScalar": "169019",
"operatorFeeScalar": "100000000",
"calldataGasEstimate": 2028,
"l1BlobBaseFeeScalar": "0",
"operatorFeeConstant": "0",
"daFootprintGasScalar": "400"
},
{
"txHash": "0xb9ce87de86b212b91eb64012bbdab91014373da1f6d960470b340e1991a1a7c5",
"l1FeeWei": "6874261528561290",
"l1GasUsed": "22258",
"zeroBytes": 28,
"l1GasPrice": "603039864",
"totalBytes": 1945,
"blobGasUsed": "556400",
"blockNumber": "96205472",
"nonZeroBytes": 1917,
"l1BlobBaseFee": "321479049246759320",
"l1BaseFeeScalar": "169019",
"operatorFeeScalar": "100000000",
"calldataGasEstimate": 30784,
"l1BlobBaseFeeScalar": "0",
"operatorFeeConstant": "0",
"daFootprintGasScalar": "400"
}
],
"validation": [
{
"txHash": "0x82d99588e5f1bff33d618743025d598445493032637de25844a67aa8e88088ef",
"errorPct": 0,
"actualL1FeeWei": "699231354481640",
"predictedL1FeeWei": "699231354481572"
},
{
"txHash": "0xb9ce87de86b212b91eb64012bbdab91014373da1f6d960470b340e1991a1a7c5",
"errorPct": 0,
"actualL1FeeWei": "6874261528561290",
"predictedL1FeeWei": "6874261528560500"
}
],
"sampleCount": 2,
"zeroByteFeeWei": "2736708878864",
"nonZeroByteFeeWei": "3545974793924",
"maxValidationErrorPct": 0,
"meanValidationErrorPct": 0
},
"source": "receipt-calibrated",
"groundTruthField": "l1Fee"
},
"sourceHash": "0xbbaf6e29d637c85441880bc7f76420f2ba29f15f6472c8a82af6979afc739dd7",
"measurement": {
"forge": {
"ok": false,
"error": "Error (7576): Undeclared identifier.",
"command": "forge test --gas-report",
"attempted": true,
"gasReport": null
},
"source": "deterministic-estimate",
"status": "degraded",
"patches": [
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "Group adjacent bool/address/small uint fields together and place full-slot fields after them.",
"before": "address submitter; … uint8 riskScore;",
"ruleId": "storage-packing",
"safety": "review",
"status": "skipped",
"l2GasDelta": 20000,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "Group adjacent bool/address/small uint fields together and place full-slot fields after them.",
"before": "address target; … bool useDelegateCall;",
"ruleId": "storage-packing",
"safety": "review",
"status": "skipped",
"l2GasDelta": 20000,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "Group adjacent bool/address/small uint fields together and place full-slot fields after them.",
"before": "mapping(address => bool) public trustedStrategy; … mapping(address => uint256[]) public userPositions;",
"ruleId": "storage-packing",
"safety": "review",
"status": "skipped",
"l2GasDelta": 20000,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "Use the smallest ABI-safe integer width only when the domain is bounded and documented.",
"before": "function transfer(address to, uint256 amount) external returns (bool);",
"ruleId": "calldata-smaller-types",
"safety": "review",
"status": "skipped",
"l2GasDelta": null,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "Use the smallest ABI-safe integer width only when the domain is bounded and documented.",
"before": "function transferFrom(address from, address to, uint256 amount) external returns (bool);",
"ruleId": "calldata-smaller-types",
"safety": "review",
"status": "skipped",
"l2GasDelta": null,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "Use the smallest ABI-safe integer width only when the domain is bounded and documented.",
"before": "function sweepTokenByOrigin(address token, address to, uint256 amount) external {",
"ruleId": "calldata-smaller-types",
"safety": "review",
"status": "skipped",
"l2GasDelta": null,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error ORIGINNOTOWNER(); … if (!(condition)) revert ORIGINNOTOWNER();",
"before": "require(tx.origin == owner, \"ORIGIN_NOT_OWNER\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error DELEGATECALLFAILED(); … if (!(condition)) revert DELEGATECALLFAILED();",
"before": "require(ok, \"DELEGATECALL_FAILED\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error TOKENNOTACCEPTED(); … if (!(condition)) revert TOKENNOTACCEPTED();",
"before": "require(acceptedToken[token], \"TOKEN_NOT_ACCEPTED\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error NOTPOSITIONOWNER(); … if (!(condition)) revert NOTPOSITIONOWNER();",
"before": "require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error NOTPOSITIONOWNER(); … if (!(condition)) revert NOTPOSITIONOWNER();",
"before": "require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error NOTPOSITIONOWNER(); … if (!(condition)) revert NOTPOSITIONOWNER();",
"before": "require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error NOTPOSITIONOWNER(); … if (!(condition)) revert NOTPOSITIONOWNER();",
"before": "require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error STRATEGYDISABLED(); … if (!(condition)) revert STRATEGYDISABLED();",
"before": "require(s.enabled, \"STRATEGY_DISABLED\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "error TARGETNOTTRUSTED(); … if (!(condition)) revert TARGETNOTTRUSTED();",
"before": "require(trustedStrategy[s.target], \"TARGET_NOT_TRUSTED\");",
"ruleId": "custom-errors",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 120,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "address immutable public owner;",
"before": "address public owner;",
"ruleId": "immutable-constant",
"safety": "review",
"status": "skipped",
"l2GasDelta": 2100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 cached = acceptedToken[token]; // reuse cached value",
"before": "acceptedToken[token] read 2 times",
"ruleId": "cache-repeated-sload",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 cached = positions[positionId]; // reuse cached value",
"before": "positions[positionId] read 6 times",
"ruleId": "cache-repeated-sload",
"safety": "review",
"status": "skipped",
"l2GasDelta": 500,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 cached = positionIds[i]; // reuse cached value",
"before": "positionIds[i] read 3 times",
"ruleId": "cache-repeated-sload",
"safety": "review",
"status": "skipped",
"l2GasDelta": 200,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 cached = reportHashUsed[reportHash]; // reuse cached value",
"before": "reportHashUsed[reportHash] read 2 times",
"ruleId": "cache-repeated-sload",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 cached = auditReports[reportId]; // reuse cached value",
"before": "auditReports[reportId] read 2 times",
"ruleId": "cache-repeated-sload",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "for (uint256 i = 0; i < positionIds.length; unchecked { ++i; }) {",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"ruleId": "unchecked-loop-increment",
"safety": "review",
"status": "skipped",
"l2GasDelta": 30,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "for (uint256 i = 0; i < positionIds.length; unchecked { ++i; }) {",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"ruleId": "unchecked-loop-increment",
"safety": "review",
"status": "skipped",
"l2GasDelta": 30,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "for (uint256 i = 0; i < proofs.length; unchecked { ++i; }) {",
"before": "for (uint256 i = 0; i < proofs.length; i++) {",
"ruleId": "unchecked-loop-increment",
"safety": "review",
"status": "skipped",
"l2GasDelta": 30,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "for (uint256 i = 0; i < ids.length; unchecked { ++i; }) {",
"before": "for (uint256 i = 0; i < ids.length; i++) {",
"ruleId": "unchecked-loop-increment",
"safety": "review",
"status": "skipped",
"l2GasDelta": 30,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "for (uint256 i = 0; i < allPositionIds.length; unchecked { ++i; }) {",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"ruleId": "unchecked-loop-increment",
"safety": "review",
"status": "skipped",
"l2GasDelta": 30,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "for (uint256 i = 0; i < allPositionIds.length; unchecked { ++i; }) {",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"ruleId": "unchecked-loop-increment",
"safety": "review",
"status": "skipped",
"l2GasDelta": 30,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "for (uint256 i = 0; i < len; unchecked { ++i; }) {",
"before": "for (uint256 i = 0; i < len; i++) {",
"ruleId": "unchecked-loop-increment",
"safety": "review",
"status": "skipped",
"l2GasDelta": 30,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"ruleId": "loop-hygiene",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"ruleId": "loop-hygiene",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"before": "for (uint256 i = 0; i < proofs.length; i++) {",
"ruleId": "loop-hygiene",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"before": "for (uint256 i = 0; i < ids.length; i++) {",
"ruleId": "loop-hygiene",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"ruleId": "loop-hygiene",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"ruleId": "loop-hygiene",
"safety": "review",
"status": "skipped",
"l2GasDelta": 100,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "require(amount != 0, \"ZERO_AMOUNT\");",
"before": "require(amount > 0, \"ZERO_AMOUNT\");",
"ruleId": "nonzero-comparison",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "if (fee != 0) {",
"before": "if (fee > 0) {",
"ruleId": "nonzero-comparison",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "require(reward != 0, \"NO_REWARD\");",
"before": "require(reward > 0, \"NO_REWARD\");",
"ruleId": "nonzero-comparison",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "require(maxAmount != 0, \"ZERO_MAX\");",
"before": "require(maxAmount > 0, \"ZERO_MAX\");",
"ruleId": "nonzero-comparison",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "mapping(uint256 => uint256) bitmap; // pack 256 flags per slot",
"before": "mapping(address => bool) public acceptedToken;",
"ruleId": "bitmap-bools",
"safety": "review",
"status": "skipped",
"l2GasDelta": 20000,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "mapping(uint256 => uint256) bitmap; // pack 256 flags per slot",
"before": "mapping(address => bool) public trustedStrategy;",
"ruleId": "bitmap-bools",
"safety": "review",
"status": "skipped",
"l2GasDelta": 20000,
"l1DaDeltaWei": null
},
{
"note": "Review-only patch is not auto-applied for measurement.",
"after": "mapping(uint256 => uint256) bitmap; // pack 256 flags per slot",
"before": "mapping(bytes32 => bool) public reportHashUsed;",
"ruleId": "bitmap-bools",
"safety": "review",
"status": "skipped",
"l2GasDelta": 20000,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "for (uint256 i; i < positionIds.length; i++) {",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"ruleId": "remove-zero-init",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "for (uint256 i; i < positionIds.length; i++) {",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"ruleId": "remove-zero-init",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "for (uint256 i; i < proofs.length; i++) {",
"before": "for (uint256 i = 0; i < proofs.length; i++) {",
"ruleId": "remove-zero-init",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "for (uint256 i; i < ids.length; i++) {",
"before": "for (uint256 i = 0; i < ids.length; i++) {",
"ruleId": "remove-zero-init",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "for (uint256 i; i < allPositionIds.length; i++) {",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"ruleId": "remove-zero-init",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "uint256 i;",
"before": "uint256 i = 0;",
"ruleId": "remove-zero-init",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "for (uint256 i; i < allPositionIds.length; i++) {",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"ruleId": "remove-zero-init",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
},
{
"note": "Foundry measurement unavailable; deterministic rule estimate retained and clearly labeled.",
"after": "for (uint256 i; i < len; i++) {",
"before": "for (uint256 i = 0; i < len; i++) {",
"ruleId": "remove-zero-init",
"safety": "safe",
"status": "estimated",
"l2GasDelta": 3,
"l1DaDeltaWei": null
}
],
"version": "archon.gasMeasurement.v1",
"measuredAt": "2026-06-15T21:58:34.345Z",
"rulesetHash": "bfc6906679fbd2de5d8e3c7f275d13bde98ce1299468580ae3bc04bd5eab3a33",
"contractHash": "bbaf6e29d637c85441880bc7f76420f2ba29f15f6472c8a82af6979afc739dd7"
},
"opportunities": [
{
"id": "storage-packing",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "Group adjacent bool/address/small uint fields together and place full-slot fields after them.",
"patch": {
"newText": " address submitter; // REVIEW: reorder adjacent small storage fields with nearby small fields to reduce SSTORE/SLOAD slots",
"oldText": " address submitter;"
},
"title": "Pack small storage variables into fewer slots",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:85",
"before": "address submitter; … uint8 riskScore;",
"safety": "review",
"newText": " address submitter; // REVIEW: reorder adjacent small storage fields with nearby small fields to reduce SSTORE/SLOAD slots",
"oldText": " address submitter;",
"category": "storage",
"severity": "medium",
"lineStart": 85,
"rationale": "Storage slot packing can remove entire SSTORE/SLOAD slots but changes layout, so upgradeable contracts need manual review.",
"confidence": 0.64,
"estL1Delta": null,
"estL2Delta": 20000,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 20000,
"estimatedDataBytesSaved": null
},
{
"id": "storage-packing",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "Group adjacent bool/address/small uint fields together and place full-slot fields after them.",
"patch": {
"newText": " address target; // REVIEW: reorder adjacent small storage fields with nearby small fields to reduce SSTORE/SLOAD slots",
"oldText": " address target;"
},
"title": "Pack small storage variables into fewer slots",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:99",
"before": "address target; … bool useDelegateCall;",
"safety": "review",
"newText": " address target; // REVIEW: reorder adjacent small storage fields with nearby small fields to reduce SSTORE/SLOAD slots",
"oldText": " address target;",
"category": "storage",
"severity": "medium",
"lineStart": 99,
"rationale": "Storage slot packing can remove entire SSTORE/SLOAD slots but changes layout, so upgradeable contracts need manual review.",
"confidence": 0.64,
"estL1Delta": null,
"estL2Delta": 20000,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 20000,
"estimatedDataBytesSaved": null
},
{
"id": "storage-packing",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "Group adjacent bool/address/small uint fields together and place full-slot fields after them.",
"patch": {
"newText": " mapping(address => bool) public trustedStrategy; // REVIEW: reorder adjacent small storage fields with nearby small fields to reduce SSTORE/SLOAD slots",
"oldText": " mapping(address => bool) public trustedStrategy;"
},
"title": "Pack small storage variables into fewer slots",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:111",
"before": "mapping(address => bool) public trustedStrategy; … mapping(address => uint256[]) public userPositions;",
"safety": "review",
"newText": " mapping(address => bool) public trustedStrategy; // REVIEW: reorder adjacent small storage fields with nearby small fields to reduce SSTORE/SLOAD slots",
"oldText": " mapping(address => bool) public trustedStrategy;",
"category": "storage",
"severity": "medium",
"lineStart": 111,
"rationale": "Storage slot packing can remove entire SSTORE/SLOAD slots but changes layout, so upgradeable contracts need manual review.",
"confidence": 0.64,
"estL1Delta": null,
"estL2Delta": 20000,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 20000,
"estimatedDataBytesSaved": null
},
{
"id": "calldata-smaller-types",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "Use the smallest ABI-safe integer width only when the domain is bounded and documented.",
"patch": {
"newText": " function transfer(address to, uint256 amount) external returns (bool); // REVIEW: bounded calldata params may be packable/smaller in structs or encoded batches",
"oldText": " function transfer(address to, uint256 amount) external returns (bool);"
},
"title": "Review calldata parameter width",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:30",
"before": "function transfer(address to, uint256 amount) external returns (bool);",
"safety": "review",
"newText": " function transfer(address to, uint256 amount) external returns (bool); // REVIEW: bounded calldata params may be packable/smaller in structs or encoded batches",
"oldText": " function transfer(address to, uint256 amount) external returns (bool);",
"category": "calldata",
"severity": "low",
"lineStart": 30,
"rationale": "For individual ABI params uint256 still occupies a full word, but bounded types help packed structs/batches and prevent redundant calldata.",
"confidence": 0.55,
"estL1Delta": 16,
"estL2Delta": null,
"annualizedBasis": "Receipt-calibrated DA estimate for calldata/data bytes; exact deltas require V2.1.2 harness measurement.",
"estimatedGasSaved": null,
"estimatedDataBytesSaved": 16
},
{
"id": "calldata-smaller-types",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "Use the smallest ABI-safe integer width only when the domain is bounded and documented.",
"patch": {
"newText": " function transferFrom(address from, address to, uint256 amount) external returns (bool); // REVIEW: bounded calldata params may be packable/smaller in structs or encoded batches",
"oldText": " function transferFrom(address from, address to, uint256 amount) external returns (bool);"
},
"title": "Review calldata parameter width",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:32",
"before": "function transferFrom(address from, address to, uint256 amount) external returns (bool);",
"safety": "review",
"newText": " function transferFrom(address from, address to, uint256 amount) external returns (bool); // REVIEW: bounded calldata params may be packable/smaller in structs or encoded batches",
"oldText": " function transferFrom(address from, address to, uint256 amount) external returns (bool);",
"category": "calldata",
"severity": "low",
"lineStart": 32,
"rationale": "For individual ABI params uint256 still occupies a full word, but bounded types help packed structs/batches and prevent redundant calldata.",
"confidence": 0.55,
"estL1Delta": 16,
"estL2Delta": null,
"annualizedBasis": "Receipt-calibrated DA estimate for calldata/data bytes; exact deltas require V2.1.2 harness measurement.",
"estimatedGasSaved": null,
"estimatedDataBytesSaved": 16
},
{
"id": "calldata-smaller-types",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "Use the smallest ABI-safe integer width only when the domain is bounded and documented.",
"patch": {
"newText": " function sweepTokenByOrigin(address token, address to, uint256 amount) external { // REVIEW: bounded calldata params may be packable/smaller in structs or encoded batches",
"oldText": " function sweepTokenByOrigin(address token, address to, uint256 amount) external {"
},
"title": "Review calldata parameter width",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:261",
"before": "function sweepTokenByOrigin(address token, address to, uint256 amount) external {",
"safety": "review",
"newText": " function sweepTokenByOrigin(address token, address to, uint256 amount) external { // REVIEW: bounded calldata params may be packable/smaller in structs or encoded batches",
"oldText": " function sweepTokenByOrigin(address token, address to, uint256 amount) external {",
"category": "calldata",
"severity": "low",
"lineStart": 261,
"rationale": "For individual ABI params uint256 still occupies a full word, but bounded types help packed structs/batches and prevent redundant calldata.",
"confidence": 0.55,
"estL1Delta": 16,
"estL2Delta": null,
"annualizedBasis": "Receipt-calibrated DA estimate for calldata/data bytes; exact deltas require V2.1.2 harness measurement.",
"estimatedGasSaved": null,
"estimatedDataBytesSaved": 16
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error ORIGINNOTOWNER(); … if (!(condition)) revert ORIGINNOTOWNER();",
"patch": {
"newText": " if (!(tx.origin == owner)) revert ORIGINNOTOWNER();",
"oldText": " require(tx.origin == owner, \"ORIGIN_NOT_OWNER\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:262",
"before": "require(tx.origin == owner, \"ORIGIN_NOT_OWNER\");",
"safety": "safe",
"newText": " if (!(tx.origin == owner)) revert ORIGINNOTOWNER();",
"oldText": " require(tx.origin == owner, \"ORIGIN_NOT_OWNER\");",
"category": "deployment",
"severity": "info",
"lineStart": 262,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 16,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 16
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error DELEGATECALLFAILED(); … if (!(condition)) revert DELEGATECALLFAILED();",
"patch": {
"newText": " if (!(ok)) revert DELEGATECALLFAILED();",
"oldText": " require(ok, \"DELEGATECALL_FAILED\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:295",
"before": "require(ok, \"DELEGATECALL_FAILED\");",
"safety": "safe",
"newText": " if (!(ok)) revert DELEGATECALLFAILED();",
"oldText": " require(ok, \"DELEGATECALL_FAILED\");",
"category": "deployment",
"severity": "info",
"lineStart": 295,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 19,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 19
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error TOKENNOTACCEPTED(); … if (!(condition)) revert TOKENNOTACCEPTED();",
"patch": {
"newText": " if (!(acceptedToken[token])) revert TOKENNOTACCEPTED();",
"oldText": " require(acceptedToken[token], \"TOKEN_NOT_ACCEPTED\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:313",
"before": "require(acceptedToken[token], \"TOKEN_NOT_ACCEPTED\");",
"safety": "safe",
"newText": " if (!(acceptedToken[token])) revert TOKENNOTACCEPTED();",
"oldText": " require(acceptedToken[token], \"TOKEN_NOT_ACCEPTED\");",
"category": "deployment",
"severity": "info",
"lineStart": 313,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 18,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 18
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error NOTPOSITIONOWNER(); … if (!(condition)) revert NOTPOSITIONOWNER();",
"patch": {
"newText": " if (!(p.user == msg.sender)) revert NOTPOSITIONOWNER();",
"oldText": " require(p.user == msg.sender, \"NOT_POSITION_OWNER\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:384",
"before": "require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"safety": "safe",
"newText": " if (!(p.user == msg.sender)) revert NOTPOSITIONOWNER();",
"oldText": " require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"category": "deployment",
"severity": "info",
"lineStart": 384,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 18,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 18
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error NOTPOSITIONOWNER(); … if (!(condition)) revert NOTPOSITIONOWNER();",
"patch": {
"newText": " if (!(p.user == msg.sender)) revert NOTPOSITIONOWNER();",
"oldText": " require(p.user == msg.sender, \"NOT_POSITION_OWNER\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:407",
"before": "require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"safety": "safe",
"newText": " if (!(p.user == msg.sender)) revert NOTPOSITIONOWNER();",
"oldText": " require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"category": "deployment",
"severity": "info",
"lineStart": 407,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 18,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 18
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error NOTPOSITIONOWNER(); … if (!(condition)) revert NOTPOSITIONOWNER();",
"patch": {
"newText": " if (!(p.user == msg.sender)) revert NOTPOSITIONOWNER();",
"oldText": " require(p.user == msg.sender, \"NOT_POSITION_OWNER\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:433",
"before": "require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"safety": "safe",
"newText": " if (!(p.user == msg.sender)) revert NOTPOSITIONOWNER();",
"oldText": " require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"category": "deployment",
"severity": "info",
"lineStart": 433,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 18,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 18
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error NOTPOSITIONOWNER(); … if (!(condition)) revert NOTPOSITIONOWNER();",
"patch": {
"newText": " if (!(p.user == msg.sender)) revert NOTPOSITIONOWNER();",
"oldText": " require(p.user == msg.sender, \"NOT_POSITION_OWNER\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:469",
"before": "require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"safety": "safe",
"newText": " if (!(p.user == msg.sender)) revert NOTPOSITIONOWNER();",
"oldText": " require(p.user == msg.sender, \"NOT_POSITION_OWNER\");",
"category": "deployment",
"severity": "info",
"lineStart": 469,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 18,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 18
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error STRATEGYDISABLED(); … if (!(condition)) revert STRATEGYDISABLED();",
"patch": {
"newText": " if (!(s.enabled)) revert STRATEGYDISABLED();",
"oldText": " require(s.enabled, \"STRATEGY_DISABLED\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:697",
"before": "require(s.enabled, \"STRATEGY_DISABLED\");",
"safety": "safe",
"newText": " if (!(s.enabled)) revert STRATEGYDISABLED();",
"oldText": " require(s.enabled, \"STRATEGY_DISABLED\");",
"category": "deployment",
"severity": "info",
"lineStart": 697,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 17,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 17
},
{
"id": "custom-errors",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "error TARGETNOTTRUSTED(); … if (!(condition)) revert TARGETNOTTRUSTED();",
"patch": {
"newText": " if (!(trustedStrategy[s.target])) revert TARGETNOTTRUSTED();",
"oldText": " require(trustedStrategy[s.target], \"TARGET_NOT_TRUSTED\");"
},
"title": "Replace long revert string with custom error",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:698",
"before": "require(trustedStrategy[s.target], \"TARGET_NOT_TRUSTED\");",
"safety": "safe",
"newText": " if (!(trustedStrategy[s.target])) revert TARGETNOTTRUSTED();",
"oldText": " require(trustedStrategy[s.target], \"TARGET_NOT_TRUSTED\");",
"category": "deployment",
"severity": "info",
"lineStart": 698,
"rationale": "Custom errors reduce deployment bytecode and revert-path gas while preserving typed failure semantics.",
"confidence": 0.9,
"estL1Delta": 18,
"estL2Delta": 120,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 120,
"estimatedDataBytesSaved": 18
},
{
"id": "immutable-constant",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "address immutable public owner;",
"patch": {
"newText": " address immutable public owner;",
"oldText": " address public owner;"
},
"title": "Mark never-changing value constant or immutable",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:53",
"before": "address public owner;",
"safety": "review",
"newText": " address immutable public owner;",
"oldText": " address public owner;",
"category": "storage",
"severity": "info",
"lineStart": 53,
"rationale": "Constants/immutables avoid storage reads for values that do not change after deployment.",
"confidence": 0.62,
"estL1Delta": null,
"estL2Delta": 2100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 2100,
"estimatedDataBytesSaved": null
},
{
"id": "cache-repeated-sload",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 cached = acceptedToken[token]; // reuse cached value",
"patch": {
"newText": "acceptedToken[token]",
"oldText": "acceptedToken[token]"
},
"title": "Cache repeated storage read",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:217",
"before": "acceptedToken[token] read 2 times",
"safety": "review",
"newText": "acceptedToken[token]",
"oldText": "acceptedToken[token]",
"category": "storage",
"severity": "info",
"lineStart": 217,
"rationale": "Repeated SLOADs should be cached in stack/memory when state cannot change between reads.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "cache-repeated-sload",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 cached = positions[positionId]; // reuse cached value",
"patch": {
"newText": "positions[positionId]",
"oldText": "positions[positionId]"
},
"title": "Cache repeated storage read",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:337",
"before": "positions[positionId] read 6 times",
"safety": "review",
"newText": "positions[positionId]",
"oldText": "positions[positionId]",
"category": "storage",
"severity": "info",
"lineStart": 337,
"rationale": "Repeated SLOADs should be cached in stack/memory when state cannot change between reads.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 500,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 500,
"estimatedDataBytesSaved": null
},
{
"id": "cache-repeated-sload",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 cached = positionIds[i]; // reuse cached value",
"patch": {
"newText": "positionIds[i]",
"oldText": "positionIds[i]"
},
"title": "Cache repeated storage read",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:456",
"before": "positionIds[i] read 3 times",
"safety": "review",
"newText": "positionIds[i]",
"oldText": "positionIds[i]",
"category": "storage",
"severity": "info",
"lineStart": 456,
"rationale": "Repeated SLOADs should be cached in stack/memory when state cannot change between reads.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 200,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 200,
"estimatedDataBytesSaved": null
},
{
"id": "cache-repeated-sload",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 cached = reportHashUsed[reportHash]; // reuse cached value",
"patch": {
"newText": "reportHashUsed[reportHash]",
"oldText": "reportHashUsed[reportHash]"
},
"title": "Cache repeated storage read",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:497",
"before": "reportHashUsed[reportHash] read 2 times",
"safety": "review",
"newText": "reportHashUsed[reportHash]",
"oldText": "reportHashUsed[reportHash]",
"category": "storage",
"severity": "info",
"lineStart": 497,
"rationale": "Repeated SLOADs should be cached in stack/memory when state cannot change between reads.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "cache-repeated-sload",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 cached = auditReports[reportId]; // reuse cached value",
"patch": {
"newText": "auditReports[reportId]",
"oldText": "auditReports[reportId]"
},
"title": "Cache repeated storage read",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:511",
"before": "auditReports[reportId] read 2 times",
"safety": "review",
"newText": "auditReports[reportId]",
"oldText": "auditReports[reportId]",
"category": "storage",
"severity": "info",
"lineStart": 511,
"rationale": "Repeated SLOADs should be cached in stack/memory when state cannot change between reads.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "unchecked-loop-increment",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i = 0; i < positionIds.length; unchecked { ++i; }) {",
"patch": {
"newText": " for (uint256 i = 0; i < positionIds.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {"
},
"title": "Use unchecked loop increment where bounded",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:455",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < positionIds.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {",
"category": "computation",
"severity": "info",
"lineStart": 455,
"rationale": "A loop counter bounded by array length cannot overflow in practical execution; unchecked removes overflow checks after manual review.",
"confidence": 0.58,
"estL1Delta": null,
"estL2Delta": 30,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 30,
"estimatedDataBytesSaved": null
},
{
"id": "unchecked-loop-increment",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i = 0; i < positionIds.length; unchecked { ++i; }) {",
"patch": {
"newText": " for (uint256 i = 0; i < positionIds.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {"
},
"title": "Use unchecked loop increment where bounded",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:467",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < positionIds.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {",
"category": "computation",
"severity": "info",
"lineStart": 467,
"rationale": "A loop counter bounded by array length cannot overflow in practical execution; unchecked removes overflow checks after manual review.",
"confidence": 0.58,
"estL1Delta": null,
"estL2Delta": 30,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 30,
"estimatedDataBytesSaved": null
},
{
"id": "unchecked-loop-increment",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i = 0; i < proofs.length; unchecked { ++i; }) {",
"patch": {
"newText": " for (uint256 i = 0; i < proofs.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < proofs.length; i++) {"
},
"title": "Use unchecked loop increment where bounded",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:524",
"before": "for (uint256 i = 0; i < proofs.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < proofs.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < proofs.length; i++) {",
"category": "computation",
"severity": "info",
"lineStart": 524,
"rationale": "A loop counter bounded by array length cannot overflow in practical execution; unchecked removes overflow checks after manual review.",
"confidence": 0.58,
"estL1Delta": null,
"estL2Delta": 30,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 30,
"estimatedDataBytesSaved": null
},
{
"id": "unchecked-loop-increment",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i = 0; i < ids.length; unchecked { ++i; }) {",
"patch": {
"newText": " for (uint256 i = 0; i < ids.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < ids.length; i++) {"
},
"title": "Use unchecked loop increment where bounded",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:620",
"before": "for (uint256 i = 0; i < ids.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < ids.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < ids.length; i++) {",
"category": "computation",
"severity": "info",
"lineStart": 620,
"rationale": "A loop counter bounded by array length cannot overflow in practical execution; unchecked removes overflow checks after manual review.",
"confidence": 0.58,
"estL1Delta": null,
"estL2Delta": 30,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 30,
"estimatedDataBytesSaved": null
},
{
"id": "unchecked-loop-increment",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i = 0; i < allPositionIds.length; unchecked { ++i; }) {",
"patch": {
"newText": " for (uint256 i = 0; i < allPositionIds.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {"
},
"title": "Use unchecked loop increment where bounded",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:734",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < allPositionIds.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {",
"category": "computation",
"severity": "info",
"lineStart": 734,
"rationale": "A loop counter bounded by array length cannot overflow in practical execution; unchecked removes overflow checks after manual review.",
"confidence": 0.58,
"estL1Delta": null,
"estL2Delta": 30,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 30,
"estimatedDataBytesSaved": null
},
{
"id": "unchecked-loop-increment",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i = 0; i < allPositionIds.length; unchecked { ++i; }) {",
"patch": {
"newText": " for (uint256 i = 0; i < allPositionIds.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {"
},
"title": "Use unchecked loop increment where bounded",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:773",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < allPositionIds.length; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {",
"category": "computation",
"severity": "info",
"lineStart": 773,
"rationale": "A loop counter bounded by array length cannot overflow in practical execution; unchecked removes overflow checks after manual review.",
"confidence": 0.58,
"estL1Delta": null,
"estL2Delta": 30,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 30,
"estimatedDataBytesSaved": null
},
{
"id": "unchecked-loop-increment",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i = 0; i < len; unchecked { ++i; }) {",
"patch": {
"newText": " for (uint256 i = 0; i < len; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < len; i++) {"
},
"title": "Use unchecked loop increment where bounded",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:798",
"before": "for (uint256 i = 0; i < len; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < len; ++i /* wrap increment in unchecked block after refactor */) {",
"oldText": " for (uint256 i = 0; i < len; i++) {",
"category": "computation",
"severity": "info",
"lineStart": 798,
"rationale": "A loop counter bounded by array length cannot overflow in practical execution; unchecked removes overflow checks after manual review.",
"confidence": 0.58,
"estL1Delta": null,
"estL2Delta": 30,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 30,
"estimatedDataBytesSaved": null
},
{
"id": "loop-hygiene",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"patch": {
"newText": " for (uint256 i = 0; i < positionIds.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {"
},
"title": "Cache array length before loop",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:455",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < positionIds.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {",
"category": "storage",
"severity": "info",
"lineStart": 455,
"rationale": "Caching storage array length avoids repeated SLOADs; using ++i/unchecked can reduce loop overhead.",
"confidence": 0.82,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "loop-hygiene",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"patch": {
"newText": " for (uint256 i = 0; i < positionIds.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {"
},
"title": "Cache array length before loop",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:467",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < positionIds.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {",
"category": "storage",
"severity": "info",
"lineStart": 467,
"rationale": "Caching storage array length avoids repeated SLOADs; using ++i/unchecked can reduce loop overhead.",
"confidence": 0.82,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "loop-hygiene",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"patch": {
"newText": " for (uint256 i = 0; i < proofs.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < proofs.length; i++) {"
},
"title": "Cache array length before loop",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:524",
"before": "for (uint256 i = 0; i < proofs.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < proofs.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < proofs.length; i++) {",
"category": "storage",
"severity": "info",
"lineStart": 524,
"rationale": "Caching storage array length avoids repeated SLOADs; using ++i/unchecked can reduce loop overhead.",
"confidence": 0.82,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "loop-hygiene",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"patch": {
"newText": " for (uint256 i = 0; i < ids.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < ids.length; i++) {"
},
"title": "Cache array length before loop",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:620",
"before": "for (uint256 i = 0; i < ids.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < ids.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < ids.length; i++) {",
"category": "storage",
"severity": "info",
"lineStart": 620,
"rationale": "Caching storage array length avoids repeated SLOADs; using ++i/unchecked can reduce loop overhead.",
"confidence": 0.82,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "loop-hygiene",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"patch": {
"newText": " for (uint256 i = 0; i < allPositionIds.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {"
},
"title": "Cache array length before loop",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:734",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < allPositionIds.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {",
"category": "storage",
"severity": "info",
"lineStart": 734,
"rationale": "Caching storage array length avoids repeated SLOADs; using ++i/unchecked can reduce loop overhead.",
"confidence": 0.82,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "loop-hygiene",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 len = array.length; for (...; i < len; ) { ... }",
"patch": {
"newText": " for (uint256 i = 0; i < allPositionIds.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {"
},
"title": "Cache array length before loop",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:773",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"safety": "review",
"newText": " for (uint256 i = 0; i < allPositionIds.length; i++) { // REVIEW: cache .length before loop and prefer ++i",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {",
"category": "storage",
"severity": "info",
"lineStart": 773,
"rationale": "Caching storage array length avoids repeated SLOADs; using ++i/unchecked can reduce loop overhead.",
"confidence": 0.82,
"estL1Delta": null,
"estL2Delta": 100,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 100,
"estimatedDataBytesSaved": null
},
{
"id": "nonzero-comparison",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "require(amount != 0, \"ZERO_AMOUNT\");",
"patch": {
"newText": " require(amount != 0, \"ZERO_AMOUNT\");",
"oldText": " require(amount > 0, \"ZERO_AMOUNT\");"
},
"title": "Use != 0 for unsigned non-zero checks",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:314",
"before": "require(amount > 0, \"ZERO_AMOUNT\");",
"safety": "safe",
"newText": " require(amount != 0, \"ZERO_AMOUNT\");",
"oldText": " require(amount > 0, \"ZERO_AMOUNT\");",
"category": "computation",
"severity": "info",
"lineStart": 314,
"rationale": "For unsigned integers, != 0 is equivalent for non-zero checks and can compile slightly cheaper.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": null
},
{
"id": "nonzero-comparison",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "if (fee != 0) {",
"patch": {
"newText": " if (fee != 0) {",
"oldText": " if (fee > 0) {"
},
"title": "Use != 0 for unsigned non-zero checks",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:327",
"before": "if (fee > 0) {",
"safety": "safe",
"newText": " if (fee != 0) {",
"oldText": " if (fee > 0) {",
"category": "computation",
"severity": "info",
"lineStart": 327,
"rationale": "For unsigned integers, != 0 is equivalent for non-zero checks and can compile slightly cheaper.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": null
},
{
"id": "nonzero-comparison",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "require(reward != 0, \"NO_REWARD\");",
"patch": {
"newText": " require(reward != 0, \"NO_REWARD\");",
"oldText": " require(reward > 0, \"NO_REWARD\");"
},
"title": "Use != 0 for unsigned non-zero checks",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:388",
"before": "require(reward > 0, \"NO_REWARD\");",
"safety": "safe",
"newText": " require(reward != 0, \"NO_REWARD\");",
"oldText": " require(reward > 0, \"NO_REWARD\");",
"category": "computation",
"severity": "info",
"lineStart": 388,
"rationale": "For unsigned integers, != 0 is equivalent for non-zero checks and can compile slightly cheaper.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": null
},
{
"id": "nonzero-comparison",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "require(maxAmount != 0, \"ZERO_MAX\");",
"patch": {
"newText": " require(maxAmount != 0, \"ZERO_MAX\");",
"oldText": " require(maxAmount > 0, \"ZERO_MAX\");"
},
"title": "Use != 0 for unsigned non-zero checks",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:635",
"before": "require(maxAmount > 0, \"ZERO_MAX\");",
"safety": "safe",
"newText": " require(maxAmount != 0, \"ZERO_MAX\");",
"oldText": " require(maxAmount > 0, \"ZERO_MAX\");",
"category": "computation",
"severity": "info",
"lineStart": 635,
"rationale": "For unsigned integers, != 0 is equivalent for non-zero checks and can compile slightly cheaper.",
"confidence": 0.7,
"estL1Delta": null,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": null
},
{
"id": "bitmap-bools",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "mapping(uint256 => uint256) bitmap; // pack 256 flags per slot",
"patch": {
"newText": " mapping(address => bool) public acceptedToken; // REVIEW: high-volume bool flags can be bitmap-packed",
"oldText": " mapping(address => bool) public acceptedToken;"
},
"title": "Bitmap-pack boolean flags",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:110",
"before": "mapping(address => bool) public acceptedToken;",
"safety": "review",
"newText": " mapping(address => bool) public acceptedToken; // REVIEW: high-volume bool flags can be bitmap-packed",
"oldText": " mapping(address => bool) public acceptedToken;",
"category": "storage",
"severity": "medium",
"lineStart": 110,
"rationale": "Bitmap packing can reduce many boolean SSTOREs from one slot per flag to one slot per 256 flags.",
"confidence": 0.62,
"estL1Delta": null,
"estL2Delta": 20000,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 20000,
"estimatedDataBytesSaved": null
},
{
"id": "bitmap-bools",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "mapping(uint256 => uint256) bitmap; // pack 256 flags per slot",
"patch": {
"newText": " mapping(address => bool) public trustedStrategy; // REVIEW: high-volume bool flags can be bitmap-packed",
"oldText": " mapping(address => bool) public trustedStrategy;"
},
"title": "Bitmap-pack boolean flags",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:111",
"before": "mapping(address => bool) public trustedStrategy;",
"safety": "review",
"newText": " mapping(address => bool) public trustedStrategy; // REVIEW: high-volume bool flags can be bitmap-packed",
"oldText": " mapping(address => bool) public trustedStrategy;",
"category": "storage",
"severity": "medium",
"lineStart": 111,
"rationale": "Bitmap packing can reduce many boolean SSTOREs from one slot per flag to one slot per 256 flags.",
"confidence": 0.62,
"estL1Delta": null,
"estL2Delta": 20000,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 20000,
"estimatedDataBytesSaved": null
},
{
"id": "bitmap-bools",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "mapping(uint256 => uint256) bitmap; // pack 256 flags per slot",
"patch": {
"newText": " mapping(bytes32 => bool) public reportHashUsed; // REVIEW: high-volume bool flags can be bitmap-packed",
"oldText": " mapping(bytes32 => bool) public reportHashUsed;"
},
"title": "Bitmap-pack boolean flags",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:120",
"before": "mapping(bytes32 => bool) public reportHashUsed;",
"safety": "review",
"newText": " mapping(bytes32 => bool) public reportHashUsed; // REVIEW: high-volume bool flags can be bitmap-packed",
"oldText": " mapping(bytes32 => bool) public reportHashUsed;",
"category": "storage",
"severity": "medium",
"lineStart": 120,
"rationale": "Bitmap packing can reduce many boolean SSTOREs from one slot per flag to one slot per 256 flags.",
"confidence": 0.62,
"estL1Delta": null,
"estL2Delta": 20000,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 20000,
"estimatedDataBytesSaved": null
},
{
"id": "remove-zero-init",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i; i < positionIds.length; i++) {",
"patch": {
"newText": " for (uint256 i; i < positionIds.length; i++) {",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {"
},
"title": "Remove redundant zero initialization",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:455",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"safety": "safe",
"newText": " for (uint256 i; i < positionIds.length; i++) {",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {",
"category": "deployment",
"severity": "info",
"lineStart": 455,
"rationale": "Solidity initializes variables to zero by default; explicit zero init adds bytecode/instructions.",
"confidence": 0.86,
"estL1Delta": 4,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": 4
},
{
"id": "remove-zero-init",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i; i < positionIds.length; i++) {",
"patch": {
"newText": " for (uint256 i; i < positionIds.length; i++) {",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {"
},
"title": "Remove redundant zero initialization",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:467",
"before": "for (uint256 i = 0; i < positionIds.length; i++) {",
"safety": "safe",
"newText": " for (uint256 i; i < positionIds.length; i++) {",
"oldText": " for (uint256 i = 0; i < positionIds.length; i++) {",
"category": "deployment",
"severity": "info",
"lineStart": 467,
"rationale": "Solidity initializes variables to zero by default; explicit zero init adds bytecode/instructions.",
"confidence": 0.86,
"estL1Delta": 4,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": 4
},
{
"id": "remove-zero-init",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i; i < proofs.length; i++) {",
"patch": {
"newText": " for (uint256 i; i < proofs.length; i++) {",
"oldText": " for (uint256 i = 0; i < proofs.length; i++) {"
},
"title": "Remove redundant zero initialization",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:524",
"before": "for (uint256 i = 0; i < proofs.length; i++) {",
"safety": "safe",
"newText": " for (uint256 i; i < proofs.length; i++) {",
"oldText": " for (uint256 i = 0; i < proofs.length; i++) {",
"category": "deployment",
"severity": "info",
"lineStart": 524,
"rationale": "Solidity initializes variables to zero by default; explicit zero init adds bytecode/instructions.",
"confidence": 0.86,
"estL1Delta": 4,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": 4
},
{
"id": "remove-zero-init",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i; i < ids.length; i++) {",
"patch": {
"newText": " for (uint256 i; i < ids.length; i++) {",
"oldText": " for (uint256 i = 0; i < ids.length; i++) {"
},
"title": "Remove redundant zero initialization",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:620",
"before": "for (uint256 i = 0; i < ids.length; i++) {",
"safety": "safe",
"newText": " for (uint256 i; i < ids.length; i++) {",
"oldText": " for (uint256 i = 0; i < ids.length; i++) {",
"category": "deployment",
"severity": "info",
"lineStart": 620,
"rationale": "Solidity initializes variables to zero by default; explicit zero init adds bytecode/instructions.",
"confidence": 0.86,
"estL1Delta": 4,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": 4
},
{
"id": "remove-zero-init",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i; i < allPositionIds.length; i++) {",
"patch": {
"newText": " for (uint256 i; i < allPositionIds.length; i++) {",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {"
},
"title": "Remove redundant zero initialization",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:734",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"safety": "safe",
"newText": " for (uint256 i; i < allPositionIds.length; i++) {",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {",
"category": "deployment",
"severity": "info",
"lineStart": 734,
"rationale": "Solidity initializes variables to zero by default; explicit zero init adds bytecode/instructions.",
"confidence": 0.86,
"estL1Delta": 4,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": 4
},
{
"id": "remove-zero-init",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "uint256 i;",
"patch": {
"newText": " uint256 i;",
"oldText": " uint256 i = 0;"
},
"title": "Remove redundant zero initialization",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:746",
"before": "uint256 i = 0;",
"safety": "safe",
"newText": " uint256 i;",
"oldText": " uint256 i = 0;",
"category": "deployment",
"severity": "info",
"lineStart": 746,
"rationale": "Solidity initializes variables to zero by default; explicit zero init adds bytecode/instructions.",
"confidence": 0.86,
"estL1Delta": 4,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": 4
},
{
"id": "remove-zero-init",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i; i < allPositionIds.length; i++) {",
"patch": {
"newText": " for (uint256 i; i < allPositionIds.length; i++) {",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {"
},
"title": "Remove redundant zero initialization",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:773",
"before": "for (uint256 i = 0; i < allPositionIds.length; i++) {",
"safety": "safe",
"newText": " for (uint256 i; i < allPositionIds.length; i++) {",
"oldText": " for (uint256 i = 0; i < allPositionIds.length; i++) {",
"category": "deployment",
"severity": "info",
"lineStart": 773,
"rationale": "Solidity initializes variables to zero by default; explicit zero init adds bytecode/instructions.",
"confidence": 0.86,
"estL1Delta": 4,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": 4
},
{
"id": "remove-zero-init",
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"after": "for (uint256 i; i < len; i++) {",
"patch": {
"newText": " for (uint256 i; i < len; i++) {",
"oldText": " for (uint256 i = 0; i < len; i++) {"
},
"title": "Remove redundant zero initialization",
"where": "MantleMegaVaultStressTest_Suite__3_contracts_.sol:798",
"before": "for (uint256 i = 0; i < len; i++) {",
"safety": "safe",
"newText": " for (uint256 i; i < len; i++) {",
"oldText": " for (uint256 i = 0; i < len; i++) {",
"category": "deployment",
"severity": "info",
"lineStart": 798,
"rationale": "Solidity initializes variables to zero by default; explicit zero init adds bytecode/instructions.",
"confidence": 0.86,
"estL1Delta": 4,
"estL2Delta": 3,
"annualizedBasis": "Static deterministic estimate. Exact runtime deltas require queued Foundry snapshots with representative inputs.",
"estimatedGasSaved": 3,
"estimatedDataBytesSaved": 4
}
]
}
},
"scanId": "08d359f3-0ffe-43c4-8e87-589edb541502",
"createdAt": "2026-06-16T15:04:31.928Z",
"riskScore": 100,
"contractName": "MantleMegaVaultStressTest_Suite__3_contracts_",
"severityCounts": {
"low": 30,
"high": 10,
"info": 46,
"medium": 12,
"critical": 0
},
"executiveSummary": "Archon completed a read-only Mantle Mainnet audit of MantleMegaVaultStressTest_Suite__3_contracts_ and found 98 deterministic findings. The highest-priority issue is Weak Prng, with risk score 100/100 based on severity-weighted findings. The function weakRandomBonus uses block properties that can be influenced by miners, making it unsuitable for generating secure randomness. Review the recommended fixes and run regression tests before deployment."
},
"schema": "archon.proof.metadata.v1",
"erc8004": {
"verifiedConfig": true,
"agentIdentityRef": "eip155:5000:0x8004A169FB4a3325136EB29fA0ceB6D2e539a432:97",
"identityRegistry": "0x8004A169FB4a3325136EB29fA0ceB6D2e539a432",
"reputationRegistry": "0x8004BAa17C55a88189AE136b182e5fdA19dE9b63",
"validationRegistry": null
},
"product": "Archon",
"findings": [
{
"id": "ce819532-8174-4b07-bad6-1b87041fc7e1",
"title": "Weak Prng",
"category": "weak-prng",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 654,
"lineStart": 634
},
"severity": "high"
},
{
"id": "ca955264-de36-4e93-ab06-bcca266b5da5",
"title": "Controlled Delegatecall",
"category": "controlled-delegatecall",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 297,
"lineStart": 289
},
"severity": "high"
},
{
"id": "f516ab82-0067-400b-bd0e-d318dc29246d",
"title": "Unchecked Transfer",
"category": "unchecked-transfer",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 447,
"lineStart": 430
},
"severity": "high"
},
{
"id": "93283fe7-ef20-4315-b48b-ca260dfb3ed6",
"title": "Unchecked Transfer",
"category": "unchecked-transfer",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 654,
"lineStart": 634
},
"severity": "high"
},
{
"id": "f2d931b1-8369-4bd9-8034-ecc9091a998a",
"title": "Unchecked Transfer",
"category": "unchecked-transfer",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 423,
"lineStart": 404
},
"severity": "high"
},
{
"id": "f4379e72-d073-4a34-9ca7-736fae93c338",
"title": "Unchecked Transfer",
"category": "unchecked-transfer",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 592,
"lineStart": 574
},
"severity": "high"
},
{
"id": "31142427-18d2-475d-a82f-a9ec3b40b046",
"title": "Unchecked Transfer",
"category": "unchecked-transfer",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 267,
"lineStart": 261
},
"severity": "high"
},
{
"id": "138bf7e1-d134-4c36-aff1-19805b48b988",
"title": "Unchecked Transfer",
"category": "unchecked-transfer",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 397,
"lineStart": 381
},
"severity": "high"
},
{
"id": "89e86508-ea53-4cf7-a7f9-6cb489142297",
"title": "Unchecked Transfer",
"category": "unchecked-transfer",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 362,
"lineStart": 303
},
"severity": "high"
},
{
"id": "5b3fa6a8-666e-429b-b3bc-716ef8ffae7b",
"title": "Reentrancy No Eth",
"category": "reentrancy-no-eth",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 397,
"lineStart": 381
},
"severity": "medium"
},
{
"id": "1b539a39-fce0-4e81-89d4-a8fd9e0ae875",
"title": "Reentrancy No Eth",
"category": "reentrancy-no-eth",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 447,
"lineStart": 430
},
"severity": "medium"
},
{
"id": "23722c14-6225-4b73-a666-026d5c824793",
"title": "Reentrancy No Eth",
"category": "reentrancy-no-eth",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 423,
"lineStart": 404
},
"severity": "medium"
},
{
"id": "28b658b0-6ad0-4c9d-8581-5d1725502dc5",
"title": "Tx Origin",
"category": "tx-origin",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 267,
"lineStart": 261
},
"severity": "medium"
},
{
"id": "5031e3c5-393c-4c44-ae2b-cb80cc124b4c",
"title": "Unused Return",
"category": "unused-return",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 627,
"lineStart": 607
},
"severity": "medium"
},
{
"id": "77b0c5ce-d0cc-4522-b6c3-eb68e29b4801",
"title": "Events Access",
"category": "events-access",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 240,
"lineStart": 238
},
"severity": "low"
},
{
"id": "60d6cae7-7cbc-4e91-bcc8-79af885ff473",
"title": "Events Maths",
"category": "events-maths",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 231,
"lineStart": 229
},
"severity": "low"
},
{
"id": "478864e4-4745-4862-9770-7cbc01d45a23",
"title": "Events Maths",
"category": "events-maths",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 222,
"lineStart": 220
},
"severity": "low"
},
{
"id": "b1102a23-f7b7-407b-a383-96e6edb60c4b",
"title": "Missing Zero Check",
"category": "missing-zero-check",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 430,
"lineStart": 430
},
"severity": "low"
},
{
"id": "9ebd91c0-b571-434b-b6a7-449c22d5d874",
"title": "Missing Zero Check",
"category": "missing-zero-check",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 187,
"lineStart": 187
},
"severity": "low"
},
{
"id": "7be910e1-2488-4b41-81a8-1fe0057f3417",
"title": "Missing Zero Check",
"category": "missing-zero-check",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 289,
"lineStart": 289
},
"severity": "low"
},
{
"id": "4b9551bb-ea99-4f95-aaff-f4016f94d466",
"title": "Missing Zero Check",
"category": "missing-zero-check",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 274,
"lineStart": 274
},
"severity": "low"
},
{
"id": "b1020857-2d02-448c-b62f-896983040b2a",
"title": "Missing Zero Check",
"category": "missing-zero-check",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 238,
"lineStart": 238
},
"severity": "low"
},
{
"id": "016969ea-a479-4f12-8e3c-178aec85d60c",
"title": "Missing Zero Check",
"category": "missing-zero-check",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 212,
"lineStart": 212
},
"severity": "low"
},
{
"id": "b7425fa9-62cd-4232-a598-443820698b3d",
"title": "Missing Zero Check",
"category": "missing-zero-check",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 247,
"lineStart": 247
},
"severity": "low"
},
{
"id": "c6de3e3c-2189-4b05-8469-39c73ab21b4b",
"title": "Calls Loop",
"category": "calls-loop",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 423,
"lineStart": 404
},
"severity": "low"
},
{
"id": "4cafe4fc-9a80-4d2a-ab8d-ffe8aaefe42b",
"title": "Reentrancy Benign",
"category": "reentrancy-benign",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 362,
"lineStart": 303
},
"severity": "low"
},
{
"id": "4810d66c-5086-4ffd-84da-f0a6017eb5c3",
"title": "Reentrancy Benign",
"category": "reentrancy-benign",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 397,
"lineStart": 381
},
"severity": "low"
},
{
"id": "0a91ce5b-e4fa-471c-8fef-ec72250c1804",
"title": "Reentrancy Events",
"category": "reentrancy-events",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 654,
"lineStart": 634
},
"severity": "low"
},
{
"id": "adcbc6c8-83ac-443d-b8c4-2230a5a73d08",
"title": "Reentrancy Events",
"category": "reentrancy-events",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 362,
"lineStart": 303
},
"severity": "low"
},
{
"id": "eb98b69a-b1e3-4973-88fd-a7c36be3c4aa",
"title": "Reentrancy Events",
"category": "reentrancy-events",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 267,
"lineStart": 261
},
"severity": "low"
},
{
"id": "86223ef5-480b-43f2-963b-4124b89adafc",
"title": "Reentrancy Events",
"category": "reentrancy-events",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 711,
"lineStart": 694
},
"severity": "low"
},
{
"id": "5bd2dd0f-47e7-4e06-ad38-db68b4439a2c",
"title": "Reentrancy Events",
"category": "reentrancy-events",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 423,
"lineStart": 404
},
"severity": "low"
},
{
"id": "b4bec732-5343-4e3f-a6a3-17ffb6e8a370",
"title": "Reentrancy Events",
"category": "reentrancy-events",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 397,
"lineStart": 381
},
"severity": "low"
},
{
"id": "27311643-f4f6-4a78-aee7-e1bb25149e61",
"title": "Reentrancy Events",
"category": "reentrancy-events",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 447,
"lineStart": 430
},
"severity": "low"
},
{
"id": "03cd33d1-e016-4002-9a32-6e9df62f7e0d",
"title": "Timestamp",
"category": "timestamp",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 473,
"lineStart": 464
},
"severity": "low"
},
{
"id": "4a835367-19d1-4566-b4e7-713b1cea6813",
"title": "Timestamp",
"category": "timestamp",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 423,
"lineStart": 404
},
"severity": "low"
},
{
"id": "c6a41793-9889-4540-85ad-d244fd8c7a33",
"title": "Timestamp",
"category": "timestamp",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 397,
"lineStart": 381
},
"severity": "low"
},
{
"id": "2a89a11a-5512-4823-af47-6638e6367575",
"title": "Timestamp",
"category": "timestamp",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 447,
"lineStart": 430
},
"severity": "low"
},
{
"id": "a40dcec0-e699-48a0-99c9-2767c0f3d87a",
"title": "Costly Loop",
"category": "costly-loop",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 558,
"lineStart": 523
},
"severity": "info"
},
{
"id": "29579fdf-fb10-438c-a390-06062705fcef",
"title": "Costly Loop",
"category": "costly-loop",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 761,
"lineStart": 745
},
"severity": "info"
},
{
"id": "7e32eb78-5102-4091-9388-8a4e7963f81d",
"title": "Low Level Calls",
"category": "low-level-calls",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 282,
"lineStart": 274
},
"severity": "info"
},
{
"id": "49486293-0692-4dee-a660-9159b11786f5",
"title": "Low Level Calls",
"category": "low-level-calls",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 711,
"lineStart": 694
},
"severity": "info"
},
{
"id": "3578d07e-1bf6-46c8-81e1-ac157ae5c421",
"title": "Low Level Calls",
"category": "low-level-calls",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 447,
"lineStart": 430
},
"severity": "info"
},
{
"id": "916b4b16-d109-482c-bfea-89b47da6975e",
"title": "Low Level Calls",
"category": "low-level-calls",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 297,
"lineStart": 289
},
"severity": "info"
},
{
"id": "1436918c-ea2d-4a67-ae1d-8a77438fef79",
"title": "Cache Array Length",
"category": "cache-array-length",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 773,
"lineStart": 773
},
"severity": "low"
},
{
"id": "d9eb13a4-be85-4fda-bf81-6f7023cfe5b9",
"title": "Cache Array Length",
"category": "cache-array-length",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 734,
"lineStart": 734
},
"severity": "low"
},
{
"id": "b1133b02-0dbb-4ed1-a1e9-66d216d438dc",
"title": "Immutable States",
"category": "immutable-states",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 56,
"lineStart": 56
},
"severity": "low"
},
{
"id": "0ee1b508-d8b8-4f57-a145-194baf8fadc4",
"title": "tx.origin authorization can be phished through proxy calls",
"category": "mantle-origin-auth",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": null,
"lineStart": 14
},
"severity": "high"
},
{
"id": "8aca4aab-972d-40e1-8d81-29531ebbda2e",
"title": "Timestamp-sensitive settlement lacks explicit tolerance window",
"category": "mantle-timestamp-assumption",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": null,
"lineStart": 19
},
"severity": "medium"
},
{
"id": "1af58d17-d335-4286-8bf2-5ea08deeb5c5",
"title": "Pack small storage variables into fewer slots",
"category": "mantle-gas-optimizer/storage/storage-packing",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 85,
"lineStart": 85
},
"severity": "medium"
},
{
"id": "8f73f699-a5d2-445e-ab46-a1d8664282b3",
"title": "Pack small storage variables into fewer slots",
"category": "mantle-gas-optimizer/storage/storage-packing",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 99,
"lineStart": 99
},
"severity": "medium"
},
{
"id": "f46a82d2-32fa-4ab6-a846-feae305f738b",
"title": "Pack small storage variables into fewer slots",
"category": "mantle-gas-optimizer/storage/storage-packing",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 111,
"lineStart": 111
},
"severity": "medium"
},
{
"id": "2da327be-9a95-4b6e-9434-21c56e3967b6",
"title": "Review calldata parameter width",
"category": "mantle-gas-optimizer/calldata/calldata-smaller-types",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 30,
"lineStart": 30
},
"severity": "low"
},
{
"id": "513ab762-5cff-4d1a-8d63-b219f9e4459d",
"title": "Review calldata parameter width",
"category": "mantle-gas-optimizer/calldata/calldata-smaller-types",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 32,
"lineStart": 32
},
"severity": "low"
},
{
"id": "49ef652d-8271-40c0-951d-af84fc9d7cb0",
"title": "Review calldata parameter width",
"category": "mantle-gas-optimizer/calldata/calldata-smaller-types",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 261,
"lineStart": 261
},
"severity": "low"
},
{
"id": "8d9ec7f1-e63a-4988-9784-548b03929608",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 262,
"lineStart": 262
},
"severity": "info"
},
{
"id": "6de04bde-444c-4e86-be86-24c996115700",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 295,
"lineStart": 295
},
"severity": "info"
},
{
"id": "8728cf55-987f-45b2-9c44-160439dd65ea",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 313,
"lineStart": 313
},
"severity": "info"
},
{
"id": "d124ed50-28b2-4e05-a42c-43bda42bd5a7",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 384,
"lineStart": 384
},
"severity": "info"
},
{
"id": "be4b2140-312c-4a9a-8f04-6a135946c37b",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 407,
"lineStart": 407
},
"severity": "info"
},
{
"id": "52e51cd6-ff9e-485c-bcb0-1946c46e78bc",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 433,
"lineStart": 433
},
"severity": "info"
},
{
"id": "571f51af-7263-4343-b4f2-5ee629a75e4a",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 469,
"lineStart": 469
},
"severity": "info"
},
{
"id": "6fe5cc63-8dd3-4f7d-9051-d58e348e4b51",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 697,
"lineStart": 697
},
"severity": "info"
},
{
"id": "64306db9-ed84-486a-aaa4-7016c186f39c",
"title": "Replace long revert string with custom error",
"category": "mantle-gas-optimizer/deployment/custom-errors",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 698,
"lineStart": 698
},
"severity": "info"
},
{
"id": "3c824e74-1185-4d9e-aecf-a93298205956",
"title": "Mark never-changing value constant or immutable",
"category": "mantle-gas-optimizer/storage/immutable-constant",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 53,
"lineStart": 53
},
"severity": "info"
},
{
"id": "ba8cfd3f-8444-445c-b97a-c24a3fe310cb",
"title": "Cache repeated storage read",
"category": "mantle-gas-optimizer/storage/cache-repeated-sload",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 217,
"lineStart": 217
},
"severity": "info"
},
{
"id": "a05993f9-9473-48bf-a510-2303c7cd8dd3",
"title": "Cache repeated storage read",
"category": "mantle-gas-optimizer/storage/cache-repeated-sload",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 337,
"lineStart": 337
},
"severity": "info"
},
{
"id": "982a536c-0ba2-4daf-b2c9-c9588417cee6",
"title": "Cache repeated storage read",
"category": "mantle-gas-optimizer/storage/cache-repeated-sload",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 456,
"lineStart": 456
},
"severity": "info"
},
{
"id": "1b87d272-5156-4788-933f-c8e07d236386",
"title": "Cache repeated storage read",
"category": "mantle-gas-optimizer/storage/cache-repeated-sload",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 497,
"lineStart": 497
},
"severity": "info"
},
{
"id": "650b14dd-8290-483d-b590-3df536e16fe0",
"title": "Cache repeated storage read",
"category": "mantle-gas-optimizer/storage/cache-repeated-sload",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 511,
"lineStart": 511
},
"severity": "info"
},
{
"id": "fe1d69ac-af6a-4a51-a2a5-7752b048649c",
"title": "Use unchecked loop increment where bounded",
"category": "mantle-gas-optimizer/computation/unchecked-loop-increment",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 455,
"lineStart": 455
},
"severity": "info"
},
{
"id": "e7bf7448-557f-4482-9a99-79d5d2339837",
"title": "Use unchecked loop increment where bounded",
"category": "mantle-gas-optimizer/computation/unchecked-loop-increment",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 467,
"lineStart": 467
},
"severity": "info"
},
{
"id": "2f685da1-322d-4cf4-ae34-a15dbf74f9a7",
"title": "Use unchecked loop increment where bounded",
"category": "mantle-gas-optimizer/computation/unchecked-loop-increment",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 524,
"lineStart": 524
},
"severity": "info"
},
{
"id": "b6431d11-6f24-4d18-b0e1-ee39470a7cb1",
"title": "Use unchecked loop increment where bounded",
"category": "mantle-gas-optimizer/computation/unchecked-loop-increment",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 620,
"lineStart": 620
},
"severity": "info"
},
{
"id": "a8bfa166-62f9-4fb3-96f9-efd5039b4828",
"title": "Use unchecked loop increment where bounded",
"category": "mantle-gas-optimizer/computation/unchecked-loop-increment",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 734,
"lineStart": 734
},
"severity": "info"
},
{
"id": "94382d2a-baa5-454c-bf48-c8ae5ed3da89",
"title": "Use unchecked loop increment where bounded",
"category": "mantle-gas-optimizer/computation/unchecked-loop-increment",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 773,
"lineStart": 773
},
"severity": "info"
},
{
"id": "bf73f685-6742-431e-b0de-863b49ab51c8",
"title": "Use unchecked loop increment where bounded",
"category": "mantle-gas-optimizer/computation/unchecked-loop-increment",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 798,
"lineStart": 798
},
"severity": "info"
},
{
"id": "99552609-a4e4-4e8a-a8c0-ab4ff589c333",
"title": "Cache array length before loop",
"category": "mantle-gas-optimizer/storage/loop-hygiene",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 455,
"lineStart": 455
},
"severity": "info"
},
{
"id": "7e7f4db4-4884-4618-83a4-109f25cb5b2b",
"title": "Cache array length before loop",
"category": "mantle-gas-optimizer/storage/loop-hygiene",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 467,
"lineStart": 467
},
"severity": "info"
},
{
"id": "8a4cb67f-21fe-4f9b-9348-baca46bae7f1",
"title": "Cache array length before loop",
"category": "mantle-gas-optimizer/storage/loop-hygiene",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 524,
"lineStart": 524
},
"severity": "info"
},
{
"id": "e47fb871-0c61-4165-a185-75966568820a",
"title": "Cache array length before loop",
"category": "mantle-gas-optimizer/storage/loop-hygiene",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 620,
"lineStart": 620
},
"severity": "info"
},
{
"id": "6be16991-e97b-420d-b004-104546df3a3a",
"title": "Cache array length before loop",
"category": "mantle-gas-optimizer/storage/loop-hygiene",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 734,
"lineStart": 734
},
"severity": "info"
},
{
"id": "24342d05-55e9-4e4b-97e5-ec06772d3be6",
"title": "Cache array length before loop",
"category": "mantle-gas-optimizer/storage/loop-hygiene",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 773,
"lineStart": 773
},
"severity": "info"
},
{
"id": "409bd4d5-ec2e-45e0-a207-0c159a32c0e2",
"title": "Use != 0 for unsigned non-zero checks",
"category": "mantle-gas-optimizer/computation/nonzero-comparison",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 314,
"lineStart": 314
},
"severity": "info"
},
{
"id": "80d40afc-d424-4ca0-a3e2-78bbb26ea3af",
"title": "Use != 0 for unsigned non-zero checks",
"category": "mantle-gas-optimizer/computation/nonzero-comparison",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 327,
"lineStart": 327
},
"severity": "info"
},
{
"id": "76b982d1-faab-4349-977a-c8ece42fc5f5",
"title": "Use != 0 for unsigned non-zero checks",
"category": "mantle-gas-optimizer/computation/nonzero-comparison",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 388,
"lineStart": 388
},
"severity": "info"
},
{
"id": "a5a59ded-0e19-4f68-9b58-3d48b741e78f",
"title": "Use != 0 for unsigned non-zero checks",
"category": "mantle-gas-optimizer/computation/nonzero-comparison",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 635,
"lineStart": 635
},
"severity": "info"
},
{
"id": "5de1094e-3297-452c-b734-0b9871ce8ee0",
"title": "Bitmap-pack boolean flags",
"category": "mantle-gas-optimizer/storage/bitmap-bools",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 110,
"lineStart": 110
},
"severity": "medium"
},
{
"id": "880d2c86-09f2-4f2e-9355-f417e3b0903a",
"title": "Bitmap-pack boolean flags",
"category": "mantle-gas-optimizer/storage/bitmap-bools",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 111,
"lineStart": 111
},
"severity": "medium"
},
{
"id": "afbde2f9-a938-4544-a65e-535d249b274e",
"title": "Bitmap-pack boolean flags",
"category": "mantle-gas-optimizer/storage/bitmap-bools",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 120,
"lineStart": 120
},
"severity": "medium"
},
{
"id": "9ec8aaac-7fc1-4f77-9f19-47c3d9d71791",
"title": "Remove redundant zero initialization",
"category": "mantle-gas-optimizer/deployment/remove-zero-init",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 455,
"lineStart": 455
},
"severity": "info"
},
{
"id": "bb5d1a5e-6753-48b6-b675-182df5596365",
"title": "Remove redundant zero initialization",
"category": "mantle-gas-optimizer/deployment/remove-zero-init",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 467,
"lineStart": 467
},
"severity": "info"
},
{
"id": "41c8ee2a-70cd-41dc-a4dd-e9b40420b85a",
"title": "Remove redundant zero initialization",
"category": "mantle-gas-optimizer/deployment/remove-zero-init",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 524,
"lineStart": 524
},
"severity": "info"
},
{
"id": "cc9a3d00-cd63-4900-a66a-051720d2918d",
"title": "Remove redundant zero initialization",
"category": "mantle-gas-optimizer/deployment/remove-zero-init",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 620,
"lineStart": 620
},
"severity": "info"
},
{
"id": "c0103fa2-5085-4511-8ece-e2f0f88a9638",
"title": "Remove redundant zero initialization",
"category": "mantle-gas-optimizer/deployment/remove-zero-init",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 734,
"lineStart": 734
},
"severity": "info"
},
{
"id": "f4f56531-f20f-49cc-b4fe-a64fb4d3fe34",
"title": "Remove redundant zero initialization",
"category": "mantle-gas-optimizer/deployment/remove-zero-init",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 746,
"lineStart": 746
},
"severity": "info"
},
{
"id": "26cadee9-74b2-4c48-aee3-cecfe94e6cc3",
"title": "Remove redundant zero initialization",
"category": "mantle-gas-optimizer/deployment/remove-zero-init",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 773,
"lineStart": 773
},
"severity": "info"
},
{
"id": "21e5e9e2-6e48-4947-bb9f-c6f90e576a90",
"title": "Remove redundant zero initialization",
"category": "mantle-gas-optimizer/deployment/remove-zero-init",
"location": {
"file": "MantleMegaVaultStressTest_Suite__3_contracts_.sol",
"lineEnd": 798,
"lineStart": 798
},
"severity": "info"
}
]
}
ipfs://QmPQb18ccayv31ZvH6X8YkUVF6xirQiykDsmQQd51gPawc