Steven Allen
141c020b4e
fix: remove pointless panic
...
Technically, the block validator caught this panic. But it's pointless
because we have a _real_ mechanism to return the validation reason,
which we should have been using.
In general, panicing like this is a very bad idea because it's
non-obvious and, in this case, completely undocumented.
2023-04-18 15:44:56 -07:00
Jorropo
fe42d974a2
chore: all: migrate from go-libipfs to boxo
...
github.com/ipfs/libipfs/blocks was unmigrated to github.com/ipfs/go-block-format due to compatibility issues with the rest of the IPLD stack.
2023-04-18 17:22:18 +02:00
Steven Allen
e945c0d6f2
fix: check for nil bcastDict ( #10646 )
...
Also hold the lock when checking the length of the blocks in the
bcastDict.
2023-04-17 20:17:10 -07:00
Steven Allen
3f74840b67
test: events: fix race when recording tipsets ( #10665 )
...
fixes #10664
2023-04-13 17:20:34 -07:00
Aayush
ae84f335cc
feat: pubsub: treat ErrGasFeeCapTooLow as ignore, not reject
2023-04-11 10:26:43 -04:00
vyzo
dd6720c61b
message data
2023-04-11 16:19:59 +03:00
vyzo
e358b3b358
add real world timing test for selection
2023-04-11 16:19:50 +03:00
vyzo
b4e2e871dc
prune excess messages before selection
2023-04-11 13:12:05 +03:00
Aayush
7710a57fa3
fix: include extra messages in ComputeState InvocResult output
2023-04-05 15:25:57 -04:00
Jiaying Wang
522388820a
Merge pull request #10552 from filecoin-project/asr/optimize-blockmsgsfortipset
...
feat: chainstore: optimize BlockMsgsForTipset
2023-04-04 13:53:23 -04:00
vyzo
bf666a3f7e
Merge pull request #10551 from filecoin-project/vyzo/feat/exec-lanes
...
feat: VM Execution Lanes
2023-03-30 22:19:11 +03:00
Aayush Rajasekaran
139bde3771
Merge pull request #10561 from filecoin-project/mikers/messagepoolRWMutexes
...
perf: message pool: change locks to RWMutexes for performance
2023-03-30 12:47:44 -04:00
vyzo
d71b528253
reorg initialization code for better readability, remove unused import
2023-03-30 18:15:13 +03:00
vyzo
7b4e68249a
add comment about Signal unsoundness
2023-03-30 18:13:08 +03:00
vyzo
54a80a8a97
revert dead code
2023-03-30 18:11:44 +03:00
Aayush Rajasekaran
8b2208fd9a
Merge pull request #9858 from adlrocha/adlrocha/consistent-bcast
...
feat:networking: (Synchronous) Consistent Broadcast for Filecoin EC
2023-03-30 09:32:09 -04:00
adlrocha
682ddf6ffa
Update chain/sub/bcast/consistent.go
...
Co-authored-by: Aayush Rajasekaran <arajasek94@gmail.com>
2023-03-30 12:38:00 +02:00
Jiaying Wang
caa6dd9c41
Merge pull request #10594 from filecoin-project/phi/v1210-rc2
...
build: release: v1.21.0-rc2
2023-03-29 15:59:56 -04:00
Aayush
66fc6dc3e5
refactor: stop using deprecated io/ioutil
2023-03-29 15:40:49 -04:00
Aayush
a724a713da
refactor: stop using deprecated io/ioutil
2023-03-29 15:38:46 -04:00
Aayush
3120852eb9
feat: supply: only grab genesis msig locks for writes
2023-03-29 14:26:15 -04:00
Aayush
24381411f2
feat: supply: drop genesis market locked funds
2023-03-29 14:26:08 -04:00
Mikers
06294351fa
perf: eth: gas estimate set applyTsMessages false ( #10546 )
...
* have gas estimate call callInternal with applyTsMessages = false and other calls with applyTsMessages=true for gas caclulation optimization
* set applyTsMessages = true in CallWithGas call in shed
* update test with new callwithgas api optimization for eth call
* Update chain/stmgr/call.go
Co-authored-by: Łukasz Magiera <magik6k@users.noreply.github.com>
* env flag LOTUS_SKIP_APPLY_TS_MESSAGE_CALL_WITH_GAS must be 1 in order to have applyTsMessages change
* env flag LOTUS_SKIP_APPLY_TS_MESSAGE_CALL_WITH_GAS must be 1 in order to have applyTsMessages change
* make sure that even if we arent apply ts messages we grab ts messages from the particular user who is requesting gas estimation
---------
Co-authored-by: Jiaying Wang <42981373+jennijuju@users.noreply.github.com>
Co-authored-by: Łukasz Magiera <magik6k@users.noreply.github.com>
Co-authored-by: Ubuntu <ubuntu@ip-10-0-4-29.us-east-2.compute.internal>
2023-03-29 14:25:40 -04:00
Friðrik Ásmundsson
36913db0cd
Merge pull request #10587 from filecoin-project/10583-enable-index-for-statewaitformessage
...
feat: Use MessageIndex in WaitForMessage
2023-03-29 18:38:39 +02:00
Mikers
41ea5a6f63
Update chain/messagepool/messagepool.go
...
Co-authored-by: Aayush Rajasekaran <arajasek94@gmail.com>
2023-03-29 05:44:25 -10:00
Fridrik Asmundsson
2c98a187dd
Use defaultExecTraceCacheSize in case env cannot be parsed
2023-03-29 17:30:00 +02:00
vyzo
52d70d563a
fix tests
2023-03-29 16:46:37 +03:00
vyzo
4184ce9c75
refactor execution lanes: hide the lock
2023-03-29 16:45:45 +03:00
Fridrik Asmundsson
f44fa5d96f
Use MessageIndex in WaitForMessage
2023-03-29 13:35:27 +02:00
Fridrik Asmundsson
8aa4917741
Fix bug in searchForIndexedMsg which always returns an error
2023-03-29 13:18:26 +02:00
Fridrik Asmundsson
17505a0022
Make execution trace configurable via env variable
...
We want to make the execution trace cache size configurable as SPs
may want to disable it while exchanges may want to crank it up.
We were also are going with intuition for this value, so having
ability to change it without a new build would help.
Fixes: https://github.com/filecoin-project/lotus/issues/10584
2023-03-29 11:53:43 +02:00
Mike Seiler
3477f7ce57
use LRU cache for keyCache to make threadsafe, also have (high) upper bounds on size of cache
2023-03-28 13:14:33 -10:00
Mike Seiler
89b217ee21
move write lock to before verifyMsg
2023-03-28 12:35:09 -10:00
Mike Seiler
2fa95a09be
clean up cache logic in addTs / fix a bug where the loop was incorrectly releasing the lock 2x
2023-03-28 11:14:13 -10:00
Aayush Rajasekaran
4b2e74a6df
Merge pull request #10535 from hsanjuan/filcryo-v1.20.0-branch
...
Fix: export-range: Ignore ipld Blocks not found in Receipts.
2023-03-28 16:01:11 -04:00
Aayush Rajasekaran
687f0c070f
Merge pull request #10556 from filecoin-project/10537-populate-index-after-snapshot
...
feat: populate the index on snapshot import
2023-03-28 11:41:43 -04:00
Fridrik Asmundsson
ecd13079e7
Address review comments
2023-03-28 17:08:53 +02:00
vyzo
71650cd8a4
rename newVM to makeVM for a happy yushie
2023-03-28 18:05:00 +03:00
vyzo
b27121612e
rename confusing variable
2023-03-28 18:03:55 +03:00
vyzo
b2b78e9dfa
Update chain/vm/execution.go
...
Co-authored-by: Aayush Rajasekaran <arajasek94@gmail.com>
2023-03-28 17:56:35 +03:00
Alfonso de la Rocha
b7c297c537
Merge branch 'master' into adlrocha/consistent-bcast
2023-03-28 16:55:06 +02:00
Alfonso de la Rocha
1a771e4310
include a deeper gc round
2023-03-28 16:52:32 +02:00
vyzo
dcd9869842
make gen
2023-03-28 16:58:09 +03:00
Hector Sanjuan
39b27e709e
export-range: use debug log instead of warn for not found receipt events
2023-03-28 15:05:43 +02:00
Fridrik Asmundsson
2e45f6f778
Dont do locking using defer
2023-03-28 12:36:57 +02:00
Fridrik Asmundsson
f84f8a831a
Use TipSetKey as key in cache and return copies
2023-03-28 12:36:57 +02:00
Fridrik Asmundsson
1ea7e05cde
feat: Add small cache to execution traces
...
This PR adds a small cache to calls to ExecutionTrace which helps
improve performance for node operators like exchanges and block
explorers.
If items is in cache calls to this function will be 2-3x faster.
Fixes: https://github.com/filecoin-project/lotus/issues/10504
2023-03-28 12:36:52 +02:00
Mikers
831f8a499d
repub needs Lock not RLock
2023-03-28 08:40:41 +00:00
Alfonso de la Rocha
df82a8240e
add comments
2023-03-28 10:33:26 +02:00
Mikers
e9d2223025
disallow infinite loop, since in testing this only runs once
2023-03-28 08:11:23 +00:00
Mikers
ad81cd18c2
cache the tipset nonce calculation before holding the write lock, and also verify that the the calculation is cached after grabbing the write lock. if it is not cached, give up the lock, calculate, and then grab the write lock again
2023-03-28 08:11:00 +00:00
Alfonso de la Rocha
92f6d3e468
global locking strategy for blockInfo map
2023-03-28 10:01:43 +02:00
Fridrik Asmundsson
90171c8bab
Addressing lint errors
2023-03-25 11:17:54 +00:00
Mike Seiler
6f440a6420
change highly contented message pool locks to RWMutexes for performance
2023-03-24 15:49:02 -10:00
Fridrik Asmundsson
b8137f6b4d
Delete existing message index when loading from snapshot
2023-03-24 16:45:33 +00:00
Fridrik Asmundsson
48c57d394b
Improve performance when populating message indax
2023-03-24 15:36:31 +00:00
vyzo
08134552a4
address review comments
2023-03-24 15:48:58 +02:00
vyzo
4b590e2102
add vm execution metrics
2023-03-24 15:16:22 +02:00
Fridrik Asmundsson
59640a8b22
Populate the index on snapshot import
...
Fixes: https://github.com/filecoin-project/lotus/issues/10537
2023-03-24 11:41:27 +00:00
Mikers
41fce94db4
perf: eth: gas estimate set applyTsMessages false ( #10546 )
...
* have gas estimate call callInternal with applyTsMessages = false and other calls with applyTsMessages=true for gas caclulation optimization
* set applyTsMessages = true in CallWithGas call in shed
* update test with new callwithgas api optimization for eth call
* Update chain/stmgr/call.go
Co-authored-by: Łukasz Magiera <magik6k@users.noreply.github.com>
* env flag LOTUS_SKIP_APPLY_TS_MESSAGE_CALL_WITH_GAS must be 1 in order to have applyTsMessages change
* env flag LOTUS_SKIP_APPLY_TS_MESSAGE_CALL_WITH_GAS must be 1 in order to have applyTsMessages change
* make sure that even if we arent apply ts messages we grab ts messages from the particular user who is requesting gas estimation
---------
Co-authored-by: Jiaying Wang <42981373+jennijuju@users.noreply.github.com>
Co-authored-by: Łukasz Magiera <magik6k@users.noreply.github.com>
Co-authored-by: Ubuntu <ubuntu@ip-10-0-4-29.us-east-2.compute.internal>
2023-03-23 18:27:01 -04:00
Aayush
bc87017ea5
feat: supply: only grab genesis msig locks for writes
2023-03-23 17:04:59 -04:00
Aayush
dcdd1bc214
feat: supply: drop genesis market locked funds
2023-03-23 15:56:59 -04:00
vyzo
f11a7f8940
fix incorrect deferred vm release
2023-03-23 19:51:23 +02:00
vyzo
317a87d669
add some sanity checks for execution concurrency parameters
2023-03-23 18:52:37 +02:00
Aayush
b1669235f7
feat: chainstore: optimize BlockMsgsForTipset
2023-03-23 11:57:43 -04:00
vyzo
2a0660447a
make token.Done idempotent
2023-03-23 17:38:36 +02:00
vyzo
2bb89d9c30
call Executor.Done where appropriate in stmgr uses
2023-03-23 17:34:59 +02:00
vyzo
ee6c0f8570
only call Atoi on non empty strings
2023-03-23 17:28:08 +02:00
vyzo
7362556c02
update VM interface references to use the executor, and call Done where appropriate
2023-03-23 17:17:46 +02:00
vyzo
6550abdfcc
introduce execution lanes
2023-03-23 16:53:50 +02:00
vyzo
8abe0ea608
Merge pull request #10452 from filecoin-project/vyzo/feat/chain/msgindex
...
feat:chain: Message Index
2023-03-22 17:02:34 +02:00
Hector Sanjuan
6942020253
Ignore blockstore.Get errors when the top-level-task is Receipts
2023-03-21 21:25:50 +01:00
Alfonso de la Rocha
90c2f9dbe2
minor fix
2023-03-16 17:17:59 +01:00
Alfonso de la Rocha
8d260d7478
address review
2023-03-16 17:03:25 +01:00
vyzo
883bbf8701
add sanity check in SearchForIndexedMsg call site
...
Check that receipt is non nil, and the message was indeed found.
2023-03-16 17:51:28 +02:00
vyzo
3710768910
add TODO for WaitForMessage to use the index
2023-03-16 17:45:16 +02:00
vyzo
ef2f2b0f89
reword funny comment
2023-03-16 17:43:56 +02:00
vyzo
9c087cc52c
second error variable name to avoid confusing they yushie.
2023-03-16 17:42:09 +02:00
vyzo
1e7f5c6a1e
shut down the index if there is an error during head processing
2023-03-16 17:41:06 +02:00
vyzo
ff22a46253
complain if head change processing is building backlog
2023-03-16 17:38:46 +02:00
vyzo
90c4763e00
fix typos
2023-03-16 17:33:12 +02:00
vyzo
8bceaadda8
chain errors in searchForIndexedMsg
2023-03-16 17:32:06 +02:00
vyzo
91fccc421a
add ON CONFLICT REPLACE clause in messages
2023-03-16 17:25:20 +02:00
adlrocha
f59c246c7a
Update chain/sub/bcast/consistent.go
...
Co-authored-by: Aayush Rajasekaran <arajasek94@gmail.com>
2023-03-16 16:09:45 +01:00
Hector Sanjuan
4b8442d8b9
Chain export: record epoch for every task.
2023-03-16 15:31:58 +01:00
Hector Sanjuan
a3900caeb0
Improve logging by carrying some more information in tasks
2023-03-16 13:38:40 +01:00
Łukasz Magiera
7e414ac390
Merge remote-tracking branch 'origin/master' into feat/go-data-transfer-v2
2023-03-15 11:37:53 +01:00
Łukasz Magiera
162e07fc95
Merge pull request #10470 from filecoin-project/feat/applyblock-timing-log
...
feat: consensus: log ApplyBlock timing/gas stats
2023-03-14 15:25:31 +01:00
Łukasz Magiera
27e3c0b89f
fix: stmgr: don't attempt to lookup genesis state ( #10472 )
...
* fix: stmgr: don't attempt to lookup genesis state
* stmgr: More correct fix for genesis state compute
2023-03-14 06:45:23 -07:00
Łukasz Magiera
51c6b64c91
feat: consensus: log ApplyBlock timing/gas stats
2023-03-14 13:58:36 +01:00
Steven Allen
dcb49dc8ee
refactor: update cache to the new generic version ( #10463 )
...
- Adds type safety.
- Reduces allocations.
- Fixes the drand cache (was storing by value, but retrieving by pointer)
2023-03-13 15:29:09 -07:00
vyzo
5ade40cbac
increase coalesce delays for test to deflake on CI
2023-03-13 17:27:12 +02:00
vyzo
47646cbd69
add optimization TODO comment
2023-03-13 15:19:07 +02:00
vyzo
1970792445
fix bug in searchForIndexedMsg
...
Need to use and return the execution tipset
2023-03-13 14:56:00 +02:00
vyzo
4b1a405002
basic msgindex itest
2023-03-13 14:55:26 +02:00
vyzo
05cb2428c1
add confidence check for indexed message epoch
2023-03-13 12:33:19 +02:00
vyzo
5e011d536b
enhance comment about lookup cid semantics
2023-03-13 12:14:30 +02:00
vyzo
a11032b10a
adjust coalescer delays
2023-03-13 11:44:10 +02:00
vyzo
bda7ef52da
log rollback errors
2023-03-13 11:41:46 +02:00
vyzo
b90cfff0aa
wire in lifecycle context
2023-03-13 10:42:48 +02:00