Skip to content

Commit a40b01a

Browse files
committed
evm: Modular Messaging
1 parent 3f56da6 commit a40b01a

File tree

1 file changed

+80
-0
lines changed

1 file changed

+80
-0
lines changed

evm/NOTES.md

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
# Notes on changes made in this integration branch
2+
3+
This integration branch is PR #21.
4+
5+
## Branches
6+
7+
Note that the indentation indicates branch dependencies.
8+
9+
- **evm_TransceiverRegistry_split** (PR #22) - This branch splits transceiver admin into a separate contract.
10+
- **evm/add_MsgManager** (PR #23) - Creates `MsgManagerBase` and `MsgManager` and makes `NttManager` inherit from `MsgManagerBase`.
11+
- **evm/add_SharedWormholeTransceiver** (PR #25) - Adds a shareable transceiver.
12+
13+
## The change that wasn't made
14+
15+
It is unfortunate that `token` and `mode` exist in `ManagerBase` rather than `NttManager`.
16+
I tried moving them, but that increases the size of `NttManagerNoRateLimiting` considerably.
17+
I'm not sure why that is, or how to avoid it, so I did not pursue that change at this time.
18+
However, some of the other changes also cause that increase, so maybe we can go back and
19+
move those fields later for free.
20+
21+
## Contract Sizes
22+
23+
### Before we started
24+
25+
```bash
26+
evm (main)$ forge build --sizes --via-ir --skip test
27+
28+
╭-----------------------------------------+------------------+-------------------+--------------------+---------------------╮
29+
| Contract | Runtime Size (B) | Initcode Size (B) | Runtime Margin (B) | Initcode Margin (B) |
30+
+===========================================================================================================================+
31+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
32+
| NttManager | 24,066 | 25,673 | 510 | 23,479 |
33+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
34+
| NttManagerNoRateLimiting | 17,141 | 18,557 | 7,435 | 30,595 |
35+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
36+
37+
```
38+
39+
### After moving token and mode (the change that wasn't made)
40+
41+
```bash
42+
evm (main)$ forge build --sizes --via-ir --skip test
43+
44+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
45+
| NttManager | 24,066 | 25,676 | 510 | 23,476 |
46+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
47+
| NttManagerNoRateLimiting | 18,788 | 20,281 | 5,788 | 28,871 |
48+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
49+
50+
```
51+
52+
## Creating TransceiverRegistryAdmin
53+
54+
```bash
55+
evm (main)$ forge build --sizes --via-ir --skip test
56+
57+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
58+
| NttManager | 23,220 | 26,937 | 1,356 | 22,215 |
59+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
60+
| NttManagerNoRateLimiting | 16,254 | 19,713 | 8,322 | 29,439 |
61+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
62+
63+
```
64+
65+
## Creating MsgManagerBase
66+
67+
```bash
68+
evm (main)$ forge build --sizes --via-ir --skip test
69+
70+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
71+
| NttManager | 24,076 | 25,719 | 500 | 23,433 |
72+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
73+
| NttManagerNoRateLimiting | 18,496 | 19,949 | 6,080 | 29,203 |
74+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
75+
| MsgManager | 12,540 | 13,745 | 12,036 | 35,407 |
76+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
77+
| MsgManagerWithExecutor | 13,145 | 14,400 | 11,431 | 34,752 |
78+
|-----------------------------------------+------------------+-------------------+--------------------+---------------------|
79+
80+
```

0 commit comments

Comments
 (0)