Commit Graph

1772 Commits

Author SHA1 Message Date
Jakub Sztandera
19ed695811
Fix TestInteropBH
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 20:37:35 +02:00
Yusef Napora
566a99240d allow overriding drand config 2020-06-23 13:33:18 -04:00
Jakub Sztandera
156a14eeeb
Integrate Poisson Sortition into chain sync
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:59:44 +02:00
Jakub Sztandera
97088e3109
Add golden test for exp function
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:33:10 +02:00
Jakub Sztandera
2b597fb780
Add tests for lambda
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:24:02 +02:00
Jakub Sztandera
efeaa9b6ad
Fix lint warnings
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:24:02 +02:00
Jakub Sztandera
d7f710806b
Implement golden tests for Poisson distribution
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:24:02 +02:00
Jakub Sztandera
d92362f96e
Add comments about algorithm
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:24:02 +02:00
Jakub Sztandera
8fea872345
Refactor poisson to struct for easier testing
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:24:02 +02:00
Jakub Sztandera
84c0b50aa1
Rename fxToD
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:24:01 +02:00
Jakub Sztandera
f523b17a35
Improve performance of ComputeWinCount
As it turns out `big.Int#Mul` doesn't like it when you reuse input as
output.

```
name         old time/op    new time/op    delta
WinCounts-8    4.56µs ± 1%    3.90µs ± 2%  -14.44%  (p=0.000 n=9+10)

name         old alloc/op   new alloc/op   delta
WinCounts-8    3.50kB ± 0%    1.15kB ± 0%  -67.23%  (p=0.000 n=10+10)

name         old allocs/op  new allocs/op  delta
WinCounts-8      45.0 ± 0%      24.0 ± 0%  -46.67%  (p=0.000 n=10+10)
```

Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:24:01 +02:00
Jakub Sztandera
ee5639aad9
Initial implementation of Poisson Sortition
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-23 16:24:01 +02:00
Łukasz Magiera
9e70e95242 sync: Correctly pass blocks to ValidateBlock 2020-06-23 14:10:47 +02:00
whyrusleeping
b71f771acb run block validation for tipsets in parallel 2020-06-22 16:09:05 -07:00
laser
5e77b5da9f bump from 3 to 4 digits in format-string
Fixes #1993
2020-06-19 08:51:06 -07:00
Jakub Sztandera
b91e7a9860
Update to specs actors with ChargeGas interface
Based on `lotus-0.6.1-chargegas` in specs-actors.

Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-17 20:00:30 +02:00
Łukasz Magiera
bdcb1e3592
Merge pull request #2029 from filecoin-project/feat/gas-delta-output
add some smartness to bench analyze gas output
2020-06-17 18:44:10 +02:00
Łukasz Magiera
6bff52483b
Merge pull request #1973 from filecoin-project/feat/drand-upd
Update to new drand
2020-06-16 15:30:40 +02:00
Jakub Sztandera
fd6c8769dd
Update to new drand
WIP

Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-16 14:46:30 +02:00
Łukasz Magiera
ab4c11c096 Merge remote-tracking branch 'origin/master' into next 2020-06-16 12:04:29 +02:00
Aayush Rajasekaran
d8a517f992 Syncer::InformNewHead can quickly fail if height is impossibly large 2020-06-16 00:51:00 -04:00
Aayush Rajasekaran
aa513d920e
Merge pull request #1705 from hayeah/cache-tipset-validation-progress
Cache tipset validation progress
2020-06-16 00:14:11 -04:00
Aayush Rajasekaran
a9abf3ceb2 extract the fake Wpost used for testing 2020-06-15 21:02:53 -04:00
Aayush Rajasekaran
ed3b2716af Don't verify ElectionPostVRF when insecure validation enabled 2020-06-15 21:02:25 -04:00
Jeromy
f8c4b64782 improve chain import analyze output, add some rough virtual gas charges 2020-06-15 16:05:29 -07:00
Łukasz Magiera
0230362d33
Merge pull request #2025 from filecoin-project/deps/specs-actors-v0.6
specs-actors v0.6
2020-06-15 21:30:37 +02:00
Jakub Sztandera
8039701f9e
Use extra field in gastrace
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-15 19:52:04 +02:00
Łukasz Magiera
907364ce67 Update deps, fix more tests 2020-06-15 18:30:49 +02:00
Jakub Sztandera
18cf7b046e
Merge pull request #2024 from filecoin-project/feat/virtual-gas
Add virtual gas
2020-06-15 18:27:24 +02:00
Jakub Sztandera
2a78ebabd9
Use HashVerify
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-15 17:39:16 +02:00
Jakub Sztandera
a23a87a17f
Add virtual gas
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-15 16:18:05 +02:00
Łukasz Magiera
7296ce7287 Merge remote-tracking branch 'origin/next' into feat/merge-master 2020-06-15 14:40:29 +02:00
Łukasz Magiera
70c8f7b1ee Merge remote-tracking branch 'origin/master' into feat/merge-master 2020-06-15 14:38:38 +02:00
Howard Yeh
c822816f8e Cache tipset validation progress 2020-06-14 18:41:17 +08:00
Ignacio Hagopian
82c6be14f4
unchecked errs
Signed-off-by: Ignacio Hagopian <jsign.uy@gmail.com>
2020-06-12 22:34:00 -03:00
Łukasz Magiera
fb4ad043dd
Merge pull request #2011 from filecoin-project/feat/more-callers
Expose more callers, ellipsis unimportant ones
2020-06-13 01:55:26 +02:00
Jakub Sztandera
91ea039077
Change ellipsis, more accurate timing
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-12 20:46:04 +02:00
Łukasz Magiera
8e025db656
Merge pull request #2014 from filecoin-project/fix/chain-reorgs-race
fix a potential race with chain reorgs notifees.
2020-06-12 20:35:16 +02:00
Raúl Kripalani
4e9293ba04 fix a potential race with chain reorgs notifees. 2020-06-12 19:18:23 +01:00
Jakub Sztandera
8ad2b3c3d9
Removed commented out code
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-12 18:58:55 +02:00
Jakub Sztandera
cd69e57a33
Expose more callers, ellipsis unimportant ones
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-12 18:49:29 +02:00
Jakub Sztandera
071ddf6563
Add aggregate number, add number of bytes for storage calls
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-11 22:25:24 +02:00
Jakub Sztandera
c90d35869b
Add gas tracing
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-11 21:59:39 +02:00
Jakub Sztandera
6acc9a62f8
Split gas internally into compute gas and storage gas
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-11 20:37:14 +02:00
Łukasz Magiera
c8046f4597 Merge branch 'next' of github.com:filecoin-project/go-lotus into next 2020-06-11 18:24:51 +02:00
Jakub Sztandera
491f080a37
Merge remote-tracking branch 'origin/master' into feat/merge-master
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-11 17:59:27 +02:00
waynewyang
8354bd91db fix:the condition of time-offset mining fault 2020-06-11 23:52:44 +08:00
Łukasz Magiera
c9a845d3aa Merge remote-tracking branch 'origin/master' into next 2020-06-11 16:29:26 +02:00
Jakub Sztandera
c3f23ddce8
Refactor ExecutionResult to ExecutionTrace
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-11 15:53:47 +02:00
Łukasz Magiera
8b308972a4 chainstore index: Drop wrong check 2020-06-11 15:43:24 +02:00
Jeromy
ac1048fcd7 test a few more cases 2020-06-11 12:31:32 +02:00
Jeromy
14ea847ef6 fix chain index seeking through long ranges of null rounds 2020-06-11 12:31:32 +02:00
Lucas Molas
dc112a5a00 Lotus architecture notes (#1768)
Co-authored-by: Aayush Rajasekaran <arajasek94@gmail.com>
2020-06-11 12:31:32 +02:00
Jeromy
512270593b clean up some of the more spammy logs 2020-06-11 12:31:29 +02:00
Mike Greenberg
2cd6347a13 Express block validation, cpu/mem usage via OpenCensus 2020-06-11 12:31:04 +02:00
Jeromy
1aff04faab test a few more cases 2020-06-10 22:17:29 -07:00
Jeromy
295c0861c4 fix chain index seeking through long ranges of null rounds 2020-06-10 22:15:46 -07:00
Lucas Molas
469eef8231
Lotus architecture notes (#1768)
Co-authored-by: Aayush Rajasekaran <arajasek94@gmail.com>
2020-06-09 20:17:28 -03:00
Jeromy
686c543778 clean up some of the more spammy logs 2020-06-09 12:49:31 -07:00
Mike Greenberg
ae83ca6893 Express block validation, cpu/mem usage via OpenCensus 2020-06-08 14:15:01 -04:00
Łukasz Magiera
3b56288a5e Merge remote-tracking branch 'origin/master' into next 2020-06-08 18:29:36 +02:00
Aayush Rajasekaran
49b27da426 Add delete functionality to the wallet 2020-06-07 19:36:01 -04:00
Whyrusleeping
366359803a
Merge pull request #1903 from filecoin-project/feat/reuse-get-tipset-by-height
reuse GetTipsetByHeight in GetRandomness
2020-06-05 16:06:28 -07:00
Łukasz Magiera
163c2b2544 Merge remote-tracking branch 'origin/master' into next 2020-06-06 00:58:24 +02:00
Jeromy
73d928751d disallow sourcing randomness from future epochs 2020-06-05 15:12:13 -07:00
Łukasz Magiera
3f81ff3507 Update specs-actors 2020-06-05 22:06:11 +02:00
Jeromy
51f1712564 add a simple semaphore to batch verify seals 2020-06-05 10:47:49 -07:00
Jakub Sztandera
7bee5b3abc
Merge remote-tracking branch 'origin/master' into next
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-05 00:33:43 +02:00
Aayush Rajasekaran
656b285195 Bugfix: Begin walkback when lookback target's height is too low 2020-06-04 18:17:54 -04:00
whyrusleeping
86083531c6 a couple bugfixes 2020-06-04 18:17:54 -04:00
Jeromy
c01f70105f implement chain index to make lookbacks faster 2020-06-04 18:17:54 -04:00
Łukasz Magiera
f9f0d86ddf
Merge pull request #1913 from acruikshank/feat/1853-confirmations-in-StateWaitMsg2
Add confidence and timeout to message wait
2020-06-04 23:23:15 +02:00
acruikshank
ce33074626 go fmt 2020-06-03 22:30:09 -04:00
Jeromy
cd817906b2 handle sourcing randomness from a future block 2020-06-03 18:30:43 -07:00
acruikshank
04f0130530 remove timeout 2020-06-03 17:42:06 -04:00
acruikshank
5574e4f11b add confidence and timeout to message wait 2020-06-03 15:38:37 -04:00
Aayush Rajasekaran
4b01b666f6 Bugfix: searchback for a message should stop if we reach sender nonce of 0 2020-06-03 14:08:05 -04:00
Jeromy
2fdcf5347b reuse GetTipsetByHeight in GetRandomness 2020-06-02 17:35:23 -07:00
Jakub Sztandera
673a972fe9
Merge remote-tracking branch 'origin/master' into next
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-02 22:49:27 +02:00
Jeromy
9b867a221a add subcall timing to compute state output 2020-06-02 12:53:24 -07:00
Jakub Sztandera
22851df145
Undo change in events_test
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-02 18:46:43 +02:00
Jakub Sztandera
96ade5f2dd
Cleanup more lint warnings
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-02 18:38:41 +02:00
Jakub Sztandera
5605aae269
Fix even more lint warnings
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-06-02 16:29:39 +02:00
Łukasz Magiera
c73326e96d fsrepo: Use LevelDB for metadata datastore 2020-06-01 20:13:07 +02:00
Aayush Rajasekaran
7dd25c3ac5 Correctly handle transfers with sender = receiver 2020-05-29 12:15:41 -04:00
Jakub Sztandera
241c3fa673
Merge pull request #1869 from filecoin-project/feat/drand-pubsub
Add pubsub support to drand beacon
2020-05-29 18:06:38 +02:00
Łukasz Magiera
785eeb1eee
Merge pull request #1850 from filecoin-project/chore/lint
Cleanup many lint warnings
2020-05-29 18:06:06 +02:00
Jakub Sztandera
30d82ba962
Explicity Watch for randomness
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-05-29 17:55:24 +02:00
Jakub Sztandera
71eb41b9aa
Add pubsub support to drand beacon
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-05-29 17:55:17 +02:00
Jeromy
e2a554c2e6 update specs actors to version with batch porep verification 2020-05-28 13:19:18 -07:00
frrist
9f8ecb0ac4 update chain-validation
- has new syscalls
2020-05-28 22:11:49 +02:00
frrist
be1bbe88b0 update chain-val syscalls interface 2020-05-28 22:11:49 +02:00
Jakub Sztandera
d6615b6286
Cleanup many lint warnings
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-05-27 22:53:20 +02:00
Jakub Sztandera
4604b60fb1
Remove drand on miner side, MinerGetBaseInfo provides the same info
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-05-27 20:24:26 +02:00
Jakub Sztandera
3f9cde28fc
Update go-log, reduce drand entry log level, add TAG env for dev scripts
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-05-27 16:19:21 +02:00
Jakub Sztandera
218b2b82c1
Update drand chain info
Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-05-27 14:09:04 +02:00
Jakub Sztandera
b06b0147a9
Switch to new drand client
This is a preview of a change to new drand client.

Signed-off-by: Jakub Sztandera <kubuxu@protocol.ai>
2020-05-27 13:52:33 +02:00
frrist
8ce6921b18 update chain-validation
- has new syscalls
2020-05-26 10:51:19 -07:00
frrist
c8f28103f3 update chain-val syscalls interface 2020-05-26 10:49:39 -07:00
Łukasz Magiera
9089aadbbf
Merge pull request #1821 from filecoin-project/deps/update-ffi
update to latest ffi
2020-05-26 19:34:02 +02:00
Jeromy
646800b8a8 update to latest ffi 2020-05-22 09:26:14 -07:00
vyzo
cc98117df2 log block validation time 2020-05-22 17:21:37 +03:00
Łukasz Magiera
ae60001dcc post: Handle Recovering sectors 2020-05-20 18:41:20 +02:00
frrist
9165f14693 feedback: fatal errors in vm.transfer 2020-05-18 12:00:52 -07:00
frrist
9305eca97c don't ignore transfer error in delete actor 2020-05-18 12:00:52 -07:00
frrist
0c2e4e2d4f return correct exitcodes from vm transfer 2020-05-18 12:00:52 -07:00
Łukasz Magiera
59725b3af3
Merge pull request #1784 from filecoin-project/feat/update-serialization-vectors
update serialization vectors
2020-05-18 20:34:44 +02:00
Jeromy
e6f3b79b23 update serialization vectors 2020-05-18 11:02:34 -07:00
Aayush Rajasekaran
5220a61fc5 Add an interop test for block header serialisation 2020-05-16 17:27:04 -04:00
Łukasz Magiera
5c73602d24
Merge pull request #1757 from filecoin-project/feat/faster-mpool-add
cache signatures, and dont check them in a lock
2020-05-15 20:27:31 +02:00
Whyrusleeping
70657e35ba
Merge pull request #1708 from filecoin-project/feat/block-validator
Improved pubsub block validator
2020-05-15 11:26:26 -07:00
Jeromy
13fc3f2f54 remove stress test (not really a real test) 2020-05-15 11:00:13 -07:00
Jeromy
33ec4d332b cache signatures, and dont check them in a lock 2020-05-15 10:56:38 -07:00
Łukasz Magiera
b90666b293 miner: optimize SelectMessages 2020-05-15 19:30:31 +02:00
Jeromy
88fa9726cc use chainmsg type instead of unsigned message for gas price checking 2020-05-14 12:44:26 -07:00
Jeromy
881b0517b1 reuse logic between message selection and validation 2020-05-14 12:29:11 -07:00
Aayush Rajasekaran
2e74e1d2ae Don't assert params must be empty for Methodnum = 0 2020-05-14 15:10:07 -04:00
vyzo
81bc159b3e cache successful block signature validation 2020-05-14 20:48:40 +03:00
vyzo
50e05ae1ba use sigs.CheckBlockSignature 2020-05-14 20:48:40 +03:00
vyzo
432c69c616 update message validator to provide rejection signal 2020-05-14 20:48:40 +03:00
vyzo
e714294273 initialize map 2020-05-14 20:48:19 +03:00
vyzo
c3a144bcb6 flesh out signature validation logic 2020-05-14 20:48:19 +03:00
vyzo
dd86a289ce cache miner worker keys 2020-05-14 20:48:19 +03:00
vyzo
6e0dac06f4 utility to retrieve miner worker key from the chain 2020-05-14 20:48:19 +03:00
vyzo
5bd0e92068 remove source flagging from bogus CID blocks
it's ineffective.
2020-05-14 20:48:19 +03:00
Jeromy
b5cb1fe1e0 some minor cleanup of data verification for preseals 2020-05-13 21:00:32 -07:00
Jeromy
50fae56baf Verify data for presealed data 2020-05-13 19:35:44 -07:00
Jeromy
a9689d8345 set verifreg root key 2020-05-13 17:04:08 -07:00
Łukasz Magiera
4e13d284b7 events: Fix revert+apply of msg execution, but not the message 2020-05-14 00:48:36 +02:00
hannahhoward
bbd2fbc434 test(events): add test to demo issue 2020-05-13 12:10:56 -07:00
Jeromy
1d8c8b9a8e check gas limits on messages more places 2020-05-12 22:36:43 -07:00
Łukasz Magiera
4c64f0ca11 sync: enforce message gas limits 2020-05-13 03:36:56 +02:00
Aayush Rajasekaran
aec168e05f Update specs-actors, re-enable full chain validation 2020-05-12 19:52:33 -04:00
Whyrusleeping
686c92ba02
Merge pull request #1713 from filecoin-project/feat/hack-reward-initial-value
hack in an initial value for LastPerEpochReward for the genesis block
2020-05-12 16:39:48 -07:00
Jeromy
141c77e17e hack in an initial value for LastPerEpochReward for the genesis block 2020-05-12 16:32:54 -07:00
frrist
5726c4bd30 construct cron actor state correctly 2020-05-12 16:12:28 -07:00
Łukasz Magiera
9597e4c501 Merge pull request #1675 from filecoin-project/frrist/puppet-actor
update chain-validation and add puppet actor
2020-05-12 20:20:00 +02:00
Aayush Rajasekaran
46fb5f8602 update CV, skip nested sends test 2020-05-12 14:14:00 -04:00
Łukasz Magiera
ba389598ee Cleanup build package 2020-05-12 19:59:28 +02:00
Łukasz Magiera
741cfb7f00 Merge branch 'feat/specs-actors-v0.5' into frrist/puppet-actor 2020-05-12 19:04:04 +02:00
Łukasz Magiera
6056a52978 Update specs-actors to pre v0.5 2020-05-12 18:58:43 +02:00
Łukasz Magiera
4ea021d151 Merge pull request #1701 from filecoin-project/asr/syncvalidity
Message validation changes
2020-05-12 13:48:33 +02:00
Łukasz Magiera
6712560779 fix import ordering 2020-05-12 13:48:09 +02:00
Aayush Rajasekaran
6bf2dcd97c Message validation changes 2020-05-11 21:54:44 -04:00
Łukasz Magiera
ec83b9cf7c Fix tests post specs-actors update 2020-05-11 23:26:33 +02:00
frrist
f73366630f add puppet actor to vm invoker in driver 2020-05-11 11:48:55 -07:00
Łukasz Magiera
e4cb28a310 Merge pull request #1694 from filecoin-project/fix/nil-protections
add some simple sanity checking to incoming blocks in the syncer
2020-05-08 20:26:50 +02:00
Jeromy
da73b62074 that doesnt belong there, really 2020-05-08 11:18:01 -07:00
Jeromy
d415aa779c also check bls aggregate signature nilness 2020-05-08 11:07:57 -07:00
Jeromy
f8c15e2d2d more checks in sync 2020-05-08 11:06:47 -07:00