Commit Graph

141 Commits

Author SHA1 Message Date
Steven Allen
176275267b Merge branch 'feat/nv18' into feat/nv18-fevm 2022-11-22 10:32:26 -08:00
Steven Allen
e78d1306ee
feat: fvm: add support for looking up past tipset CIDs (#9687)
* feat: add support for generating tipset CIDs

(cherry-picked from feat/nv18-fevm)

* feat: fvm: add support for looking up past tipset CIDs

We do this by adding yet another "getter" to the VM that resolves an
epoch into a TipSetKey.

Co-authored-by: Kevin Li <ychiaoli18@users.noreply.github.com>
2022-11-22 12:41:03 -05:00
Kevin Li
6c7fd94aa7 api: ethrpc: implement eth_sendRawTransaction (#9334)
Co-authored-by: Raúl Kripalani <raul@protocol.ai>
2022-11-09 19:28:17 +02:00
Aayush
14ef069ea1 tvx: fixup VM creation 2022-11-07 17:24:15 -05:00
Steven Allen
8df5b81f24 fix: make test vector extraction work with the FVM
This also ignores the VM "Flush" option and instead, flushes
unconditionally (in the FVM):

1. In the FVM, we don't read blocks on flush (ever).
2. All _uses_ of TVX use a "proxy" blockstore that buffers writes, so
nothing should actually get flushed to lotus.
2022-11-07 16:09:44 -05:00
Geoff Stuart
94add978b0
chore: actors: Allow builtin-actors to return a map of methods (#9342)
* Allow builtin-actors to return a map of methods

* go mod

* Fix tests

* Fix tests, check carefully please
2022-09-21 10:56:58 -04:00
Geoff Stuart
642555d0fb Fix discrepancies, run fiximports 2022-09-09 21:40:15 -04:00
Aayush
0efca4d266 introduce v9 actors and nv17 2022-09-09 21:40:15 -04:00
Łukasz Magiera
08b22edd89 fix make gen 2022-08-29 16:25:30 +02:00
Aayush
474a50252b FVM: always enable tracing for user-triggered executions 2022-07-14 15:41:26 -04:00
Łukasz Magiera
05cdeb80c3 chore: remove redundant import prefixes 2022-06-15 12:06:22 +02:00
Łukasz Magiera
39cede946c chore: Fix more imports with '2' suffix 2022-06-14 21:37:54 +02:00
Łukasz Magiera
a9600b8a6f storage: Move extern/sector-storage to storage/sealer 2022-06-14 20:03:38 +02:00
Łukasz Magiera
e65fae28de chore: fix imports 2022-06-14 17:00:51 +02:00
Aayush Rajasekaran
c661d247e5
Merge pull request #8810 from filecoin-project/asr/feat-into-master
Merge nv16 changes into master
2022-06-09 16:09:35 -04:00
Aayush Rajasekaran
27eaebad7e
Merge pull request #8302 from filecoin-project/raulk/tvx-fixes
feat: conformance & tvx: support ReportConsensusFault messages
2022-06-06 23:34:16 -04:00
Aayush
c95ad7229f Revert "VM: Refactor pricelist to be based on network versions"
This reverts commit 25b2e144b8.
2022-05-30 15:25:33 -04:00
Aayush
3c8dcda094 Revert "VM: Refactor pricelist to be based on network versions"
This reverts commit 25b2e144b8.
2022-05-30 15:19:51 -04:00
Jennifer Wang
5cfedacf9f make jen 2022-05-23 15:11:46 -04:00
Aayush
8cca9b1970 Use new go-state-types accessors 2022-05-17 15:21:27 -04:00
vyzo
c35e7691bd fix conformance driver 2022-04-14 19:31:34 +03:00
Aayush
25b2e144b8 VM: Refactor pricelist to be based on network versions 2022-03-25 15:06:10 -04:00
Aayush Rajasekaran
90d78f924f
Merge pull request #8293 from filecoin-project/feat/fvm
Filecoin Virtual Machine integration
2022-03-16 15:51:56 -04:00
Darko Brdareski
79453663b3
feat: Add additional test annotations (#8272)
* Annotate api,proxy_util,blockstore_badger, policy tests

* Annotate splitstore: bsbadger / markset

* Annotate splitstore feature

* Annotate union/timed blockstore tests

* Annotate openrpc, diff_adt tests

* Annotate error,drand,events tests

* Annotate predicates_test

* Fix annotations

* Annotate tscache, gen tests

* Annotate fundmanager test

* Annotate repub and selection tests

* Annotate statetree_test

* Annotate forks_test

* Annotate searchwait_test.go

* Fix duplicated @@ symbols

* Annotate chain stmgr/store tests

* Annotate more (types) tests

* More tests annotated

* Annotate conformance chaos actor tests

* Annotate more integration tests

* Annotate journal system tests

* Annotate more tests.

* Annotate gas,head buffer behaviors

* Fix markset annotations

* doc: test annotations for the markets dagstore wrapper

* Annotate miner_api test in dagstore

* Annotate more test files

* Remove bad annotations from fsrepo

* Annotate wdpost system

* Remove bad annotations

* Renamce "conformance" to "chaos_actor" tests

* doc: stm annotations for blockheader & election proof tests

* Annotate remaining "A" tests

* annotate: stm for error_test

* memrepo_test.go

* Annotate "b" file tests

* message_test.go

* doc: stm annotate for fsrepo_test

* Annotate "c" file tests

* Annotate "D" test files

* message_test.go

* doc: stm annotate for chain, node/config & client

* docs: stm annotate node_test

* Annotate u,v,wl tests

* doc: stm annotations for various test files

* Annotate "T" test files

* doc: stm annotate for proxy_util_test & policy_test

* doc: stm annotate for various tests

* doc: final few stm annotations

* Add mempool unit tests

* Add two more memPool Add tests

* Update submodules

* Add check function tests

* Add stm annotations, refactor test helper

* Annotate api,proxy_util,blockstore_badger, policy tests

* Annotate splitstore: bsbadger / markset

solving merge conflicts

* Annotate splitstore feature

* Annotate union/timed blockstore tests

* Annotate openrpc, diff_adt tests

* Annotate error,drand,events tests

* Annotate predicates_test

* Fix annotations

* Annotate tscache, gen tests

* Annotate fundmanager test

* Annotate statetree_test

* Annotate forks_test

* Annotate searchwait_test.go

* Fix duplicated @@ symbols

* Annotate chain stmgr/store tests

* Annotate more (types) tests

* More tests annotated

* Annotate conformance chaos actor tests

* Annotate more integration tests

* Annotate journal system tests

* Annotate more tests.

* Annotate gas,head buffer behaviors

solve merge conflict

* Fix markset annotations

* Annotate miner_api test in dagstore

* Annotate more test files

* doc: test annotations for the markets dagstore wrapper

* Annotate wdpost system

* Renamce "conformance" to "chaos_actor" tests

* Annotate remaining "A" tests

* doc: stm annotations for blockheader & election proof tests

* annotate: stm for error_test

* Annotate "b" file tests

* memrepo_test.go

* Annotate "c" file tests

* message_test.go

* Annotate "D" test files

* doc: stm annotate for fsrepo_test

* Annotate u,v,wl tests

* message_test.go

* doc: stm annotate for chain, node/config & client

* docs: stm annotate node_test

* Annotate "T" test files

* doc: stm annotations for various test files

* Add mempool unit tests

solve merge conflict

* doc: stm annotate for proxy_util_test & policy_test

* doc: stm annotate for various tests

* doc: final few stm annotations

* Add two more memPool Add tests

* Update submodules

* Add check function tests

solve conflict

* Add stm annotations, refactor test helper

solve merge conflict

* Change CLI test kinds to "unit"

* Fix double merged test

* Fix ccupgrade_test merge

* Fix lint issues

* Add stm annotation to types_Test

* Test vectors submodule

* Add file annotation to burn_test

Co-authored-by: Nikola Divic <divicnikola@gmail.com>
Co-authored-by: TheMenko <themenkoprojects@gmail.com>
2022-03-16 18:37:34 +01:00
Aayush
9ea623e125 Rename the Lotus VM to LegacyVM 2022-03-15 19:40:17 -04:00
Aayush
673f558ba5 Rename vm.VMI to vm.Interface 2022-03-15 19:34:39 -04:00
Aayush
d2054e8653 FVM: support nv15 2022-03-11 17:03:34 -05:00
Raúl Kripalani
9eb8103866 tvx and conformance: use precondition state tree as the lookback tree. 2022-03-11 18:56:19 +00:00
Aayush
9bb936b75c chore: refactor: rename NewVM to NewLotusVM 2022-02-24 12:04:05 -05:00
Raúl Kripalani
1215f26a84 tvx runner: improve error reporting. 2022-01-04 17:32:57 +00:00
Raúl Kripalani
d4fa5a0f1d tvx runner: adjust gas pricing to cope with synthetic epochs. 2022-01-04 17:32:57 +00:00
Raúl Kripalani
2c3d0d826d tvx runner: use network version from variant. 2022-01-04 17:23:17 +00:00
Aayush Rajasekaran
670bd993f3 Refactor: VM: Remove the NetworkVersionGetter 2021-12-17 19:14:21 -05:00
Aayush Rajasekaran
6f6f5d79fb Refactor: State: Let Rand get network versions 2021-12-17 18:54:17 -05:00
Aayush Rajasekaran
3f4eaa99d5 Refactor: State: Rename stmgr::GetNtwkVersion to GetNetworkVersion 2021-12-17 18:43:39 -05:00
Aayush Rajasekaran
aa1b770974 Rand: Refactor so that versioning lives in StateRand 2021-12-17 13:58:53 -05:00
Łukasz Magiera
bc384c01e3 Merge remote-tracking branch 'origin/master' into deps/update-ctx-dsbs 2021-12-17 13:01:22 +01:00
vyzo
dd327f0b22 plumb more contexts 2021-12-17 11:42:09 +02:00
Aayush Rajasekaran
1f04cc1f23 VM: Circ supply should be constant per epoch 2021-12-17 00:29:55 -05:00
vyzo
b31480232b plumb contexts in conformance 2021-12-13 14:59:52 +02:00
Aayush Rajasekaran
c3c46e9097 Fix Drand fetching around null tipsets 2021-09-29 11:57:59 -04:00
Łukasz Magiera
30fccaa0bd fix lint 2021-09-02 18:45:18 +02:00
Łukasz Magiera
95b128b7bc chain: Cleanup consensus logic 2021-09-02 18:09:37 +02:00
Aarsh Shah
d7076778e2
integrate DAG store and CARv2 in deal-making (#6671)
This commit removes badger from the deal-making processes, and
moves to a new architecture with the dagstore as the cental
component on the miner-side, and CARv2s on the client-side.

Every deal that has been handed off to the sealing subsystem becomes
a shard in the dagstore. Shards are mounted via the LotusMount, which
teaches the dagstore how to load the related piece when serving
retrievals.

When the miner starts the Lotus for the first time with this patch,
we will perform a one-time migration of all active deals into the
dagstore. This is a lightweight process, and it consists simply
of registering the shards in the dagstore.

Shards are backed by the unsealed copy of the piece. This is currently
a CARv1. However, the dagstore keeps CARv2 indices for all pieces, so
when it's time to acquire a shard to serve a retrieval, the unsealed
CARv1 is joined with its index (safeguarded by the dagstore), to form
a read-only blockstore, thus taking the place of the monolithic
badger.

Data transfers have been adjusted to interface directly with CARv2 files.
On inbound transfers (client retrievals, miner storage deals), we stream
the received data into a CARv2 ReadWrite blockstore. On outbound transfers
(client storage deals, miner retrievals), we serve the data off a CARv2
ReadOnly blockstore.

Client-side imports are managed by the refactored *imports.Manager
component (when not using IPFS integration). Just like it before, we use
the go-filestore library to avoid duplicating the data from the original
file in the resulting UnixFS DAG (concretely the leaves). However, the
target of those imports are what we call "ref-CARv2s": CARv2 files placed
under the `$LOTUS_PATH/imports` directory, containing the intermediate
nodes in full, and the leaves as positional references to the original file
on disk.

Client-side retrievals are placed into CARv2 files in the location:
`$LOTUS_PATH/retrievals`.

A new set of `Dagstore*` JSON-RPC operations and `lotus-miner dagstore`
subcommands have been introduced on the miner-side to inspect and manage
the dagstore.

Despite moving to a CARv2-backed system, the IPFS integration has been
respected, and it continues to be possible to make storage deals with data
held in an IPFS node, and to perform retrievals directly into an IPFS node.

NOTE: because the "staging" and "client" Badger blockstores are no longer
used, existing imports on the client will be rendered useless. On startup,
Lotus will enumerate all imports and print WARN statements on the log for
each import that needs to be reimported. These log lines contain these
messages:

- import lacks carv2 path; import will not work; please reimport
- import has missing/broken carv2; please reimport

At the end, we will print a "sanity check completed" message indicating
the count of imports found, and how many were deemed broken.

Co-authored-by: Aarsh Shah <aarshkshah1992@gmail.com>
Co-authored-by: Dirk McCormick <dirkmdev@gmail.com>

Co-authored-by: Raúl Kripalani <raul@protocol.ai>
Co-authored-by: Dirk McCormick <dirkmdev@gmail.com>
2021-08-16 23:34:32 +01:00
Łukasz Magiera
9bd312881d VMSys doesn't belong in chainstore 2021-07-27 15:30:23 +02:00
frrist
0519c77c24 polish(stmgr): define ExecMonitor for message applicaiton callback 2021-06-07 11:03:18 -07:00
Łukasz Magiera
ffa47659a1 Merge remote-tracking branch 'origin/feat/nv13' into feat/nv13-1.11 2021-05-31 21:38:34 +02:00
Aayush Rajasekaran
21b4741e30 Fix randomness fetching around null blocks 2021-05-26 21:06:06 -04:00
Łukasz Magiera
cf96ad4fdb fix lint 2021-04-06 14:30:49 +02:00
Łukasz Magiera
eee50caaf1 Fix buildall 2021-04-05 20:12:47 +02:00