From 293d7decc4dfc3955033b763bcf4878d15571f6b Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Tue, 12 Apr 2022 23:40:13 +0200 Subject: [PATCH 1/2] feat: return failure backtraces --- fvm.go | 2 + generated/cgo_helpers.go | 134 +++++++++++++----------- generated/generated.go | 216 +++++++++++++++++++-------------------- generated/types.go | 92 +++++++++-------- rust/src/fvm/machine.rs | 7 ++ rust/src/fvm/types.rs | 4 + 6 files changed, 242 insertions(+), 213 deletions(-) diff --git a/fvm.go b/fvm.go index a35e4715..3d465d4c 100644 --- a/fvm.go +++ b/fvm.go @@ -125,6 +125,7 @@ func (f *FVM) ApplyMessage(msgBytes []byte, chainLen uint) (*ApplyRet, error) { MinerPenalty: reformBigInt(resp.PenaltyHi, resp.PenaltyLo), MinerTip: reformBigInt(resp.MinerTipHi, resp.MinerTipLo), ExecTraceBytes: copyBytes(resp.ExecTracePtr, resp.ExecTraceLen), + FailureInfo: string(copyBytes(resp.FailureInfoPtr, resp.FailureInfoLen)), }, nil } @@ -175,6 +176,7 @@ type ApplyRet struct { MinerPenalty abi.TokenAmount MinerTip abi.TokenAmount ExecTraceBytes []byte + FailureInfo string } // NOTE: We only support 64bit platforms diff --git a/generated/cgo_helpers.go b/generated/cgo_helpers.go index fa652822..c427aab0 100644 --- a/generated/cgo_helpers.go +++ b/generated/cgo_helpers.go @@ -1240,6 +1240,14 @@ func (x *FilFvmMachineExecuteResponse) PassRef() (*C.fil_FvmMachineExecuteRespon ref88f63595.exec_trace_len, cexec_trace_len_allocs = (C.size_t)(x.ExecTraceLen), cgoAllocsUnknown allocs88f63595.Borrow(cexec_trace_len_allocs) + var cfailure_info_ptr_allocs *cgoAllocMap + ref88f63595.failure_info_ptr, cfailure_info_ptr_allocs = copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&x.FailureInfoPtr))) + allocs88f63595.Borrow(cfailure_info_ptr_allocs) + + var cfailure_info_len_allocs *cgoAllocMap + ref88f63595.failure_info_len, cfailure_info_len_allocs = (C.size_t)(x.FailureInfoLen), cgoAllocsUnknown + allocs88f63595.Borrow(cfailure_info_len_allocs) + x.ref88f63595 = ref88f63595 x.allocs88f63595 = allocs88f63595 return ref88f63595, allocs88f63595 @@ -1281,6 +1289,12 @@ func (x *FilFvmMachineExecuteResponse) Deref() { // hxf95e7c8.Len = ? x.ExecTraceLen = (uint)(x.ref88f63595.exec_trace_len) + hxff2234b := (*sliceHeader)(unsafe.Pointer(&x.FailureInfoPtr)) + hxff2234b.Data = unsafe.Pointer(x.ref88f63595.failure_info_ptr) + hxff2234b.Cap = 0x7fffffff + // hxff2234b.Len = ? + + x.FailureInfoLen = (uint)(x.ref88f63595.failure_info_len) } // allocFilFvmMachineFlushResponseMemory allocates memory for type C.fil_FvmMachineFlushResponse in C. @@ -1375,10 +1389,10 @@ func (x *FilFvmMachineFlushResponse) Deref() { } x.ErrorMsg = packPCharString(x.ref9eb3b4f4.error_msg) x.StatusCode = (FCPResponseStatus)(x.ref9eb3b4f4.status_code) - hxff2234b := (*sliceHeader)(unsafe.Pointer(&x.StateRootPtr)) - hxff2234b.Data = unsafe.Pointer(x.ref9eb3b4f4.state_root_ptr) - hxff2234b.Cap = 0x7fffffff - // hxff2234b.Len = ? + hxff73280 := (*sliceHeader)(unsafe.Pointer(&x.StateRootPtr)) + hxff73280.Data = unsafe.Pointer(x.ref9eb3b4f4.state_root_ptr) + hxff73280.Cap = 0x7fffffff + // hxff73280.Len = ? x.StateRootLen = (uint)(x.ref9eb3b4f4.state_root_len) } @@ -1763,10 +1777,10 @@ func (x *FilSealPreCommitPhase1Response) Deref() { } x.ErrorMsg = packPCharString(x.ref132bbfd8.error_msg) x.StatusCode = (FCPResponseStatus)(x.ref132bbfd8.status_code) - hxff73280 := (*sliceHeader)(unsafe.Pointer(&x.SealPreCommitPhase1OutputPtr)) - hxff73280.Data = unsafe.Pointer(x.ref132bbfd8.seal_pre_commit_phase1_output_ptr) - hxff73280.Cap = 0x7fffffff - // hxff73280.Len = ? + hxfa9955c := (*sliceHeader)(unsafe.Pointer(&x.SealPreCommitPhase1OutputPtr)) + hxfa9955c.Data = unsafe.Pointer(x.ref132bbfd8.seal_pre_commit_phase1_output_ptr) + hxfa9955c.Cap = 0x7fffffff + // hxfa9955c.Len = ? x.SealPreCommitPhase1OutputLen = (uint)(x.ref132bbfd8.seal_pre_commit_phase1_output_len) } @@ -2050,10 +2064,10 @@ func (x *FilSealCommitPhase1Response) Deref() { } x.StatusCode = (FCPResponseStatus)(x.ref61ed8561.status_code) x.ErrorMsg = packPCharString(x.ref61ed8561.error_msg) - hxfa9955c := (*sliceHeader)(unsafe.Pointer(&x.SealCommitPhase1OutputPtr)) - hxfa9955c.Data = unsafe.Pointer(x.ref61ed8561.seal_commit_phase1_output_ptr) - hxfa9955c.Cap = 0x7fffffff - // hxfa9955c.Len = ? + hxfa3f05c := (*sliceHeader)(unsafe.Pointer(&x.SealCommitPhase1OutputPtr)) + hxfa3f05c.Data = unsafe.Pointer(x.ref61ed8561.seal_commit_phase1_output_ptr) + hxfa3f05c.Cap = 0x7fffffff + // hxfa3f05c.Len = ? x.SealCommitPhase1OutputLen = (uint)(x.ref61ed8561.seal_commit_phase1_output_len) } @@ -2311,10 +2325,10 @@ func (x *FilSealCommitPhase2Response) Deref() { } x.StatusCode = (FCPResponseStatus)(x.ref5860b9a4.status_code) x.ErrorMsg = packPCharString(x.ref5860b9a4.error_msg) - hxfa3f05c := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) - hxfa3f05c.Data = unsafe.Pointer(x.ref5860b9a4.proof_ptr) - hxfa3f05c.Cap = 0x7fffffff - // hxfa3f05c.Len = ? + hxf0d18b7 := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) + hxf0d18b7.Data = unsafe.Pointer(x.ref5860b9a4.proof_ptr) + hxf0d18b7.Cap = 0x7fffffff + // hxf0d18b7.Len = ? x.ProofLen = (uint)(x.ref5860b9a4.proof_len) packSFilAggregationInputs(x.CommitInputsPtr, x.ref5860b9a4.commit_inputs_ptr) @@ -2414,10 +2428,10 @@ func (x *FilAggregateProof) Deref() { x.StatusCode = (FCPResponseStatus)(x.ref22b6c4f6.status_code) x.ErrorMsg = packPCharString(x.ref22b6c4f6.error_msg) x.ProofLen = (uint)(x.ref22b6c4f6.proof_len) - hxf0d18b7 := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) - hxf0d18b7.Data = unsafe.Pointer(x.ref22b6c4f6.proof_ptr) - hxf0d18b7.Cap = 0x7fffffff - // hxf0d18b7.Len = ? + hxf2fab0d := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) + hxf2fab0d.Data = unsafe.Pointer(x.ref22b6c4f6.proof_ptr) + hxf2fab0d.Cap = 0x7fffffff + // hxf2fab0d.Len = ? } @@ -2810,10 +2824,10 @@ func (x *FilGenerateWinningPoStSectorChallenge) Deref() { } x.ErrorMsg = packPCharString(x.ref69d2a405.error_msg) x.StatusCode = (FCPResponseStatus)(x.ref69d2a405.status_code) - hxf2fab0d := (*sliceHeader)(unsafe.Pointer(&x.IdsPtr)) - hxf2fab0d.Data = unsafe.Pointer(x.ref69d2a405.ids_ptr) - hxf2fab0d.Cap = 0x7fffffff - // hxf2fab0d.Len = ? + hxf69fe70 := (*sliceHeader)(unsafe.Pointer(&x.IdsPtr)) + hxf69fe70.Data = unsafe.Pointer(x.ref69d2a405.ids_ptr) + hxf69fe70.Cap = 0x7fffffff + // hxf69fe70.Len = ? x.IdsLen = (uint)(x.ref69d2a405.ids_len) } @@ -2922,17 +2936,17 @@ func (x *FilGenerateFallbackSectorChallengesResponse) Deref() { } x.ErrorMsg = packPCharString(x.ref7047a3fa.error_msg) x.StatusCode = (FCPResponseStatus)(x.ref7047a3fa.status_code) - hxf69fe70 := (*sliceHeader)(unsafe.Pointer(&x.IdsPtr)) - hxf69fe70.Data = unsafe.Pointer(x.ref7047a3fa.ids_ptr) - hxf69fe70.Cap = 0x7fffffff - // hxf69fe70.Len = ? - - x.IdsLen = (uint)(x.ref7047a3fa.ids_len) - hxf65bf54 := (*sliceHeader)(unsafe.Pointer(&x.ChallengesPtr)) - hxf65bf54.Data = unsafe.Pointer(x.ref7047a3fa.challenges_ptr) + hxf65bf54 := (*sliceHeader)(unsafe.Pointer(&x.IdsPtr)) + hxf65bf54.Data = unsafe.Pointer(x.ref7047a3fa.ids_ptr) hxf65bf54.Cap = 0x7fffffff // hxf65bf54.Len = ? + x.IdsLen = (uint)(x.ref7047a3fa.ids_len) + hxf3b8dbd := (*sliceHeader)(unsafe.Pointer(&x.ChallengesPtr)) + hxf3b8dbd.Data = unsafe.Pointer(x.ref7047a3fa.challenges_ptr) + hxf3b8dbd.Cap = 0x7fffffff + // hxf3b8dbd.Len = ? + x.ChallengesLen = (uint)(x.ref7047a3fa.challenges_len) x.ChallengesStride = (uint)(x.ref7047a3fa.challenges_stride) } @@ -3020,10 +3034,10 @@ func (x *FilVanillaProof) Deref() { return } x.ProofLen = (uint)(x.refb3e7638c.proof_len) - hxf3b8dbd := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) - hxf3b8dbd.Data = unsafe.Pointer(x.refb3e7638c.proof_ptr) - hxf3b8dbd.Cap = 0x7fffffff - // hxf3b8dbd.Len = ? + hxf7a6dff := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) + hxf7a6dff.Data = unsafe.Pointer(x.refb3e7638c.proof_ptr) + hxf7a6dff.Cap = 0x7fffffff + // hxf7a6dff.Len = ? } @@ -3307,10 +3321,10 @@ func (x *FilPoStProof) Deref() { } x.RegisteredProof = (FilRegisteredPoStProof)(x.ref3451bfa.registered_proof) x.ProofLen = (uint)(x.ref3451bfa.proof_len) - hxf7a6dff := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) - hxf7a6dff.Data = unsafe.Pointer(x.ref3451bfa.proof_ptr) - hxf7a6dff.Cap = 0x7fffffff - // hxf7a6dff.Len = ? + hxfe48d67 := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) + hxfe48d67.Data = unsafe.Pointer(x.ref3451bfa.proof_ptr) + hxfe48d67.Cap = 0x7fffffff + // hxfe48d67.Len = ? } @@ -3744,10 +3758,10 @@ func (x *FilGenerateWindowPoStResponse) Deref() { x.ProofsLen = (uint)(x.ref2a5f3ba8.proofs_len) packSFilPoStProof(x.ProofsPtr, x.ref2a5f3ba8.proofs_ptr) x.FaultySectorsLen = (uint)(x.ref2a5f3ba8.faulty_sectors_len) - hxfe48d67 := (*sliceHeader)(unsafe.Pointer(&x.FaultySectorsPtr)) - hxfe48d67.Data = unsafe.Pointer(x.ref2a5f3ba8.faulty_sectors_ptr) - hxfe48d67.Cap = 0x7fffffff - // hxfe48d67.Len = ? + hxf4171bf := (*sliceHeader)(unsafe.Pointer(&x.FaultySectorsPtr)) + hxf4171bf.Data = unsafe.Pointer(x.ref2a5f3ba8.faulty_sectors_ptr) + hxf4171bf.Cap = 0x7fffffff + // hxf4171bf.Len = ? x.StatusCode = (FCPResponseStatus)(x.ref2a5f3ba8.status_code) } @@ -4022,10 +4036,10 @@ func (x *FilPartitionSnarkProof) Deref() { } x.RegisteredProof = (FilRegisteredPoStProof)(x.ref4de03739.registered_proof) x.ProofLen = (uint)(x.ref4de03739.proof_len) - hxf4171bf := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) - hxf4171bf.Data = unsafe.Pointer(x.ref4de03739.proof_ptr) - hxf4171bf.Cap = 0x7fffffff - // hxf4171bf.Len = ? + hxf058b18 := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) + hxf058b18.Data = unsafe.Pointer(x.ref4de03739.proof_ptr) + hxf058b18.Cap = 0x7fffffff + // hxf058b18.Len = ? } @@ -4217,10 +4231,10 @@ func (x *FilGenerateSingleWindowPoStWithVanillaResponse) Deref() { x.ErrorMsg = packPCharString(x.ref96c012c3.error_msg) x.PartitionProof = *NewFilPartitionSnarkProofRef(unsafe.Pointer(&x.ref96c012c3.partition_proof)) x.FaultySectorsLen = (uint)(x.ref96c012c3.faulty_sectors_len) - hxf058b18 := (*sliceHeader)(unsafe.Pointer(&x.FaultySectorsPtr)) - hxf058b18.Data = unsafe.Pointer(x.ref96c012c3.faulty_sectors_ptr) - hxf058b18.Cap = 0x7fffffff - // hxf058b18.Len = ? + hxff6bc57 := (*sliceHeader)(unsafe.Pointer(&x.FaultySectorsPtr)) + hxff6bc57.Data = unsafe.Pointer(x.ref96c012c3.faulty_sectors_ptr) + hxff6bc57.Cap = 0x7fffffff + // hxff6bc57.Len = ? x.StatusCode = (FCPResponseStatus)(x.ref96c012c3.status_code) } @@ -4581,10 +4595,10 @@ func (x *FilPartitionProof) Deref() { return } x.ProofLen = (uint)(x.ref566a2be6.proof_len) - hxff6bc57 := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) - hxff6bc57.Data = unsafe.Pointer(x.ref566a2be6.proof_ptr) - hxff6bc57.Cap = 0x7fffffff - // hxff6bc57.Len = ? + hxf5fa529 := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) + hxf5fa529.Data = unsafe.Pointer(x.ref566a2be6.proof_ptr) + hxf5fa529.Cap = 0x7fffffff + // hxf5fa529.Len = ? } @@ -4918,10 +4932,10 @@ func (x *FilEmptySectorUpdateProofResponse) Deref() { x.StatusCode = (FCPResponseStatus)(x.ref5c2faef.status_code) x.ErrorMsg = packPCharString(x.ref5c2faef.error_msg) x.ProofLen = (uint)(x.ref5c2faef.proof_len) - hxf5fa529 := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) - hxf5fa529.Data = unsafe.Pointer(x.ref5c2faef.proof_ptr) - hxf5fa529.Cap = 0x7fffffff - // hxf5fa529.Len = ? + hxf21690b := (*sliceHeader)(unsafe.Pointer(&x.ProofPtr)) + hxf21690b.Data = unsafe.Pointer(x.ref5c2faef.proof_ptr) + hxf21690b.Cap = 0x7fffffff + // hxf21690b.Len = ? } diff --git a/generated/generated.go b/generated/generated.go index a6cb74ab..2d674ea5 100644 --- a/generated/generated.go +++ b/generated/generated.go @@ -17,7 +17,7 @@ import ( "unsafe" ) -// FilHash function as declared in filecoin-ffi/filcrypto.h:487 +// FilHash function as declared in filecoin-ffi/filcrypto.h:489 func FilHash(messagePtr []byte, messageLen uint) *FilHashResponse { cmessagePtr, cmessagePtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&messagePtr))) cmessageLen, cmessageLenAllocMap := (C.size_t)(messageLen), cgoAllocsUnknown @@ -28,7 +28,7 @@ func FilHash(messagePtr []byte, messageLen uint) *FilHashResponse { return __v } -// FilAggregate function as declared in filecoin-ffi/filcrypto.h:499 +// FilAggregate function as declared in filecoin-ffi/filcrypto.h:501 func FilAggregate(flattenedSignaturesPtr []byte, flattenedSignaturesLen uint) *FilAggregateResponse { cflattenedSignaturesPtr, cflattenedSignaturesPtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&flattenedSignaturesPtr))) cflattenedSignaturesLen, cflattenedSignaturesLenAllocMap := (C.size_t)(flattenedSignaturesLen), cgoAllocsUnknown @@ -39,7 +39,7 @@ func FilAggregate(flattenedSignaturesPtr []byte, flattenedSignaturesLen uint) *F return __v } -// FilVerify function as declared in filecoin-ffi/filcrypto.h:513 +// FilVerify function as declared in filecoin-ffi/filcrypto.h:515 func FilVerify(signaturePtr []byte, flattenedDigestsPtr []byte, flattenedDigestsLen uint, flattenedPublicKeysPtr []byte, flattenedPublicKeysLen uint) int32 { csignaturePtr, csignaturePtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&signaturePtr))) cflattenedDigestsPtr, cflattenedDigestsPtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&flattenedDigestsPtr))) @@ -56,7 +56,7 @@ func FilVerify(signaturePtr []byte, flattenedDigestsPtr []byte, flattenedDigests return __v } -// FilHashVerify function as declared in filecoin-ffi/filcrypto.h:531 +// FilHashVerify function as declared in filecoin-ffi/filcrypto.h:533 func FilHashVerify(signaturePtr []byte, flattenedMessagesPtr []byte, flattenedMessagesLen uint, messageSizesPtr []uint, messageSizesLen uint, flattenedPublicKeysPtr []byte, flattenedPublicKeysLen uint) int32 { csignaturePtr, csignaturePtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&signaturePtr))) cflattenedMessagesPtr, cflattenedMessagesPtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&flattenedMessagesPtr))) @@ -77,14 +77,14 @@ func FilHashVerify(signaturePtr []byte, flattenedMessagesPtr []byte, flattenedMe return __v } -// FilPrivateKeyGenerate function as declared in filecoin-ffi/filcrypto.h:542 +// FilPrivateKeyGenerate function as declared in filecoin-ffi/filcrypto.h:544 func FilPrivateKeyGenerate() *FilPrivateKeyGenerateResponse { __ret := C.fil_private_key_generate() __v := NewFilPrivateKeyGenerateResponseRef(unsafe.Pointer(__ret)) return __v } -// FilPrivateKeyGenerateWithSeed function as declared in filecoin-ffi/filcrypto.h:555 +// FilPrivateKeyGenerateWithSeed function as declared in filecoin-ffi/filcrypto.h:557 func FilPrivateKeyGenerateWithSeed(rawSeed Fil32ByteArray) *FilPrivateKeyGenerateResponse { crawSeed, crawSeedAllocMap := rawSeed.PassValue() __ret := C.fil_private_key_generate_with_seed(crawSeed) @@ -93,7 +93,7 @@ func FilPrivateKeyGenerateWithSeed(rawSeed Fil32ByteArray) *FilPrivateKeyGenerat return __v } -// FilPrivateKeySign function as declared in filecoin-ffi/filcrypto.h:568 +// FilPrivateKeySign function as declared in filecoin-ffi/filcrypto.h:570 func FilPrivateKeySign(rawPrivateKeyPtr []byte, messagePtr []byte, messageLen uint) *FilPrivateKeySignResponse { crawPrivateKeyPtr, crawPrivateKeyPtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&rawPrivateKeyPtr))) cmessagePtr, cmessagePtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&messagePtr))) @@ -106,7 +106,7 @@ func FilPrivateKeySign(rawPrivateKeyPtr []byte, messagePtr []byte, messageLen ui return __v } -// FilPrivateKeyPublicKey function as declared in filecoin-ffi/filcrypto.h:581 +// FilPrivateKeyPublicKey function as declared in filecoin-ffi/filcrypto.h:583 func FilPrivateKeyPublicKey(rawPrivateKeyPtr []byte) *FilPrivateKeyPublicKeyResponse { crawPrivateKeyPtr, crawPrivateKeyPtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&rawPrivateKeyPtr))) __ret := C.fil_private_key_public_key(crawPrivateKeyPtr) @@ -115,63 +115,63 @@ func FilPrivateKeyPublicKey(rawPrivateKeyPtr []byte) *FilPrivateKeyPublicKeyResp return __v } -// FilCreateZeroSignature function as declared in filecoin-ffi/filcrypto.h:588 +// FilCreateZeroSignature function as declared in filecoin-ffi/filcrypto.h:590 func FilCreateZeroSignature() *FilZeroSignatureResponse { __ret := C.fil_create_zero_signature() __v := NewFilZeroSignatureResponseRef(unsafe.Pointer(__ret)) return __v } -// FilDropSignature function as declared in filecoin-ffi/filcrypto.h:593 +// FilDropSignature function as declared in filecoin-ffi/filcrypto.h:595 func FilDropSignature(sig []byte) { csig, csigAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&sig))) C.fil_drop_signature(csig) runtime.KeepAlive(csigAllocMap) } -// FilDestroyHashResponse function as declared in filecoin-ffi/filcrypto.h:595 +// FilDestroyHashResponse function as declared in filecoin-ffi/filcrypto.h:597 func FilDestroyHashResponse(ptr *FilHashResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_hash_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyAggregateResponse function as declared in filecoin-ffi/filcrypto.h:597 +// FilDestroyAggregateResponse function as declared in filecoin-ffi/filcrypto.h:599 func FilDestroyAggregateResponse(ptr *FilAggregateResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_aggregate_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyPrivateKeyGenerateResponse function as declared in filecoin-ffi/filcrypto.h:599 +// FilDestroyPrivateKeyGenerateResponse function as declared in filecoin-ffi/filcrypto.h:601 func FilDestroyPrivateKeyGenerateResponse(ptr *FilPrivateKeyGenerateResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_private_key_generate_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyPrivateKeySignResponse function as declared in filecoin-ffi/filcrypto.h:601 +// FilDestroyPrivateKeySignResponse function as declared in filecoin-ffi/filcrypto.h:603 func FilDestroyPrivateKeySignResponse(ptr *FilPrivateKeySignResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_private_key_sign_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyPrivateKeyPublicKeyResponse function as declared in filecoin-ffi/filcrypto.h:603 +// FilDestroyPrivateKeyPublicKeyResponse function as declared in filecoin-ffi/filcrypto.h:605 func FilDestroyPrivateKeyPublicKeyResponse(ptr *FilPrivateKeyPublicKeyResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_private_key_public_key_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyZeroSignatureResponse function as declared in filecoin-ffi/filcrypto.h:605 +// FilDestroyZeroSignatureResponse function as declared in filecoin-ffi/filcrypto.h:607 func FilDestroyZeroSignatureResponse(ptr *FilZeroSignatureResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_zero_signature_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilCreateFvmMachine function as declared in filecoin-ffi/filcrypto.h:613 +// FilCreateFvmMachine function as declared in filecoin-ffi/filcrypto.h:615 func FilCreateFvmMachine(fvmVersion FilFvmRegisteredVersion, chainEpoch uint64, baseFeeHi uint64, baseFeeLo uint64, baseCircSupplyHi uint64, baseCircSupplyLo uint64, networkVersion uint64, stateRootPtr []byte, stateRootLen uint, manifestCidPtr []byte, manifestCidLen uint, tracing bool, blockstoreId uint64, externsId uint64) *FilCreateFvmMachineResponse { cfvmVersion, cfvmVersionAllocMap := (C.enum_fil_FvmRegisteredVersion)(fvmVersion), cgoAllocsUnknown cchainEpoch, cchainEpochAllocMap := (C.uint64_t)(chainEpoch), cgoAllocsUnknown @@ -206,14 +206,14 @@ func FilCreateFvmMachine(fvmVersion FilFvmRegisteredVersion, chainEpoch uint64, return __v } -// FilDropFvmMachine function as declared in filecoin-ffi/filcrypto.h:628 +// FilDropFvmMachine function as declared in filecoin-ffi/filcrypto.h:630 func FilDropFvmMachine(executor unsafe.Pointer) { cexecutor, cexecutorAllocMap := executor, cgoAllocsUnknown C.fil_drop_fvm_machine(cexecutor) runtime.KeepAlive(cexecutorAllocMap) } -// FilFvmMachineExecuteMessage function as declared in filecoin-ffi/filcrypto.h:630 +// FilFvmMachineExecuteMessage function as declared in filecoin-ffi/filcrypto.h:632 func FilFvmMachineExecuteMessage(executor unsafe.Pointer, messagePtr []byte, messageLen uint, chainLen uint64, applyKind uint64) *FilFvmMachineExecuteResponse { cexecutor, cexecutorAllocMap := executor, cgoAllocsUnknown cmessagePtr, cmessagePtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&messagePtr))) @@ -230,7 +230,7 @@ func FilFvmMachineExecuteMessage(executor unsafe.Pointer, messagePtr []byte, mes return __v } -// FilFvmMachineFlush function as declared in filecoin-ffi/filcrypto.h:636 +// FilFvmMachineFlush function as declared in filecoin-ffi/filcrypto.h:638 func FilFvmMachineFlush(executor unsafe.Pointer) *FilFvmMachineFlushResponse { cexecutor, cexecutorAllocMap := executor, cgoAllocsUnknown __ret := C.fil_fvm_machine_flush(cexecutor) @@ -239,28 +239,28 @@ func FilFvmMachineFlush(executor unsafe.Pointer) *FilFvmMachineFlushResponse { return __v } -// FilDestroyCreateFvmMachineResponse function as declared in filecoin-ffi/filcrypto.h:638 +// FilDestroyCreateFvmMachineResponse function as declared in filecoin-ffi/filcrypto.h:640 func FilDestroyCreateFvmMachineResponse(ptr *FilCreateFvmMachineResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_create_fvm_machine_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyFvmMachineExecuteResponse function as declared in filecoin-ffi/filcrypto.h:640 +// FilDestroyFvmMachineExecuteResponse function as declared in filecoin-ffi/filcrypto.h:642 func FilDestroyFvmMachineExecuteResponse(ptr *FilFvmMachineExecuteResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_fvm_machine_execute_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyFvmMachineFlushResponse function as declared in filecoin-ffi/filcrypto.h:642 +// FilDestroyFvmMachineFlushResponse function as declared in filecoin-ffi/filcrypto.h:644 func FilDestroyFvmMachineFlushResponse(ptr *FilFvmMachineFlushResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_fvm_machine_flush_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilWriteWithAlignment function as declared in filecoin-ffi/filcrypto.h:648 +// FilWriteWithAlignment function as declared in filecoin-ffi/filcrypto.h:650 func FilWriteWithAlignment(registeredProof FilRegisteredSealProof, srcFd int32, srcSize uint64, dstFd int32, existingPieceSizesPtr []uint64, existingPieceSizesLen uint) *FilWriteWithAlignmentResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown csrcFd, csrcFdAllocMap := (C.int)(srcFd), cgoAllocsUnknown @@ -279,7 +279,7 @@ func FilWriteWithAlignment(registeredProof FilRegisteredSealProof, srcFd int32, return __v } -// FilWriteWithoutAlignment function as declared in filecoin-ffi/filcrypto.h:659 +// FilWriteWithoutAlignment function as declared in filecoin-ffi/filcrypto.h:661 func FilWriteWithoutAlignment(registeredProof FilRegisteredSealProof, srcFd int32, srcSize uint64, dstFd int32) *FilWriteWithoutAlignmentResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown csrcFd, csrcFdAllocMap := (C.int)(srcFd), cgoAllocsUnknown @@ -294,7 +294,7 @@ func FilWriteWithoutAlignment(registeredProof FilRegisteredSealProof, srcFd int3 return __v } -// FilFauxrep function as declared in filecoin-ffi/filcrypto.h:664 +// FilFauxrep function as declared in filecoin-ffi/filcrypto.h:666 func FilFauxrep(registeredProof FilRegisteredSealProof, cacheDirPath string, sealedSectorPath string) *FilFauxRepResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown cacheDirPath = safeString(cacheDirPath) @@ -311,7 +311,7 @@ func FilFauxrep(registeredProof FilRegisteredSealProof, cacheDirPath string, sea return __v } -// FilFauxrep2 function as declared in filecoin-ffi/filcrypto.h:668 +// FilFauxrep2 function as declared in filecoin-ffi/filcrypto.h:670 func FilFauxrep2(registeredProof FilRegisteredSealProof, cacheDirPath string, existingPAuxPath string) *FilFauxRepResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown cacheDirPath = safeString(cacheDirPath) @@ -328,7 +328,7 @@ func FilFauxrep2(registeredProof FilRegisteredSealProof, cacheDirPath string, ex return __v } -// FilSealPreCommitPhase1 function as declared in filecoin-ffi/filcrypto.h:676 +// FilSealPreCommitPhase1 function as declared in filecoin-ffi/filcrypto.h:678 func FilSealPreCommitPhase1(registeredProof FilRegisteredSealProof, cacheDirPath string, stagedSectorPath string, sealedSectorPath string, sectorId uint64, proverId Fil32ByteArray, ticket Fil32ByteArray, piecesPtr []FilPublicPieceInfo, piecesLen uint) *FilSealPreCommitPhase1Response { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown cacheDirPath = safeString(cacheDirPath) @@ -360,7 +360,7 @@ func FilSealPreCommitPhase1(registeredProof FilRegisteredSealProof, cacheDirPath return __v } -// FilSealPreCommitPhase2 function as declared in filecoin-ffi/filcrypto.h:690 +// FilSealPreCommitPhase2 function as declared in filecoin-ffi/filcrypto.h:692 func FilSealPreCommitPhase2(sealPreCommitPhase1OutputPtr []byte, sealPreCommitPhase1OutputLen uint, cacheDirPath string, sealedSectorPath string) *FilSealPreCommitPhase2Response { csealPreCommitPhase1OutputPtr, csealPreCommitPhase1OutputPtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&sealPreCommitPhase1OutputPtr))) csealPreCommitPhase1OutputLen, csealPreCommitPhase1OutputLenAllocMap := (C.size_t)(sealPreCommitPhase1OutputLen), cgoAllocsUnknown @@ -379,7 +379,7 @@ func FilSealPreCommitPhase2(sealPreCommitPhase1OutputPtr []byte, sealPreCommitPh return __v } -// FilSealCommitPhase1 function as declared in filecoin-ffi/filcrypto.h:699 +// FilSealCommitPhase1 function as declared in filecoin-ffi/filcrypto.h:701 func FilSealCommitPhase1(registeredProof FilRegisteredSealProof, commR Fil32ByteArray, commD Fil32ByteArray, cacheDirPath string, replicaPath string, sectorId uint64, proverId Fil32ByteArray, ticket Fil32ByteArray, seed Fil32ByteArray, piecesPtr []FilPublicPieceInfo, piecesLen uint) *FilSealCommitPhase1Response { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown ccommR, ccommRAllocMap := commR.PassValue() @@ -413,7 +413,7 @@ func FilSealCommitPhase1(registeredProof FilRegisteredSealProof, commR Fil32Byte return __v } -// FilSealCommitPhase2 function as declared in filecoin-ffi/filcrypto.h:711 +// FilSealCommitPhase2 function as declared in filecoin-ffi/filcrypto.h:713 func FilSealCommitPhase2(sealCommitPhase1OutputPtr []byte, sealCommitPhase1OutputLen uint, sectorId uint64, proverId Fil32ByteArray) *FilSealCommitPhase2Response { csealCommitPhase1OutputPtr, csealCommitPhase1OutputPtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&sealCommitPhase1OutputPtr))) csealCommitPhase1OutputLen, csealCommitPhase1OutputLenAllocMap := (C.size_t)(sealCommitPhase1OutputLen), cgoAllocsUnknown @@ -428,7 +428,7 @@ func FilSealCommitPhase2(sealCommitPhase1OutputPtr []byte, sealCommitPhase1Outpu return __v } -// FilAggregateSealProofs function as declared in filecoin-ffi/filcrypto.h:716 +// FilAggregateSealProofs function as declared in filecoin-ffi/filcrypto.h:718 func FilAggregateSealProofs(registeredProof FilRegisteredSealProof, registeredAggregation FilRegisteredAggregationProof, commRsPtr []Fil32ByteArray, commRsLen uint, seedsPtr []Fil32ByteArray, seedsLen uint, sealCommitResponsesPtr []FilSealCommitPhase2Response, sealCommitResponsesLen uint) *FilAggregateProof { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown cregisteredAggregation, cregisteredAggregationAllocMap := (C.enum_fil_RegisteredAggregationProof)(registeredAggregation), cgoAllocsUnknown @@ -454,7 +454,7 @@ func FilAggregateSealProofs(registeredProof FilRegisteredSealProof, registeredAg return __v } -// FilVerifyAggregateSealProof function as declared in filecoin-ffi/filcrypto.h:729 +// FilVerifyAggregateSealProof function as declared in filecoin-ffi/filcrypto.h:731 func FilVerifyAggregateSealProof(registeredProof FilRegisteredSealProof, registeredAggregation FilRegisteredAggregationProof, proverId Fil32ByteArray, proofPtr []byte, proofLen uint, commitInputsPtr []FilAggregationInputs, commitInputsLen uint) *FilVerifyAggregateSealProofResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown cregisteredAggregation, cregisteredAggregationAllocMap := (C.enum_fil_RegisteredAggregationProof)(registeredAggregation), cgoAllocsUnknown @@ -476,7 +476,7 @@ func FilVerifyAggregateSealProof(registeredProof FilRegisteredSealProof, registe return __v } -// FilUnsealRange function as declared in filecoin-ffi/filcrypto.h:740 +// FilUnsealRange function as declared in filecoin-ffi/filcrypto.h:742 func FilUnsealRange(registeredProof FilRegisteredSealProof, cacheDirPath string, sealedSectorFdRaw int32, unsealOutputFdRaw int32, sectorId uint64, proverId Fil32ByteArray, ticket Fil32ByteArray, commD Fil32ByteArray, unpaddedByteIndex uint64, unpaddedBytesAmount uint64) *FilUnsealRangeResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown cacheDirPath = safeString(cacheDirPath) @@ -505,7 +505,7 @@ func FilUnsealRange(registeredProof FilRegisteredSealProof, cacheDirPath string, return __v } -// FilVerifySeal function as declared in filecoin-ffi/filcrypto.h:755 +// FilVerifySeal function as declared in filecoin-ffi/filcrypto.h:757 func FilVerifySeal(registeredProof FilRegisteredSealProof, commR Fil32ByteArray, commD Fil32ByteArray, proverId Fil32ByteArray, ticket Fil32ByteArray, seed Fil32ByteArray, sectorId uint64, proofPtr []byte, proofLen uint) *FilVerifySealResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown ccommR, ccommRAllocMap := commR.PassValue() @@ -530,7 +530,7 @@ func FilVerifySeal(registeredProof FilRegisteredSealProof, commR Fil32ByteArray, return __v } -// FilGenerateWinningPostSectorChallenge function as declared in filecoin-ffi/filcrypto.h:769 +// FilGenerateWinningPostSectorChallenge function as declared in filecoin-ffi/filcrypto.h:771 func FilGenerateWinningPostSectorChallenge(registeredProof FilRegisteredPoStProof, randomness Fil32ByteArray, sectorSetLen uint64, proverId Fil32ByteArray) *FilGenerateWinningPoStSectorChallenge { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown crandomness, crandomnessAllocMap := randomness.PassValue() @@ -545,7 +545,7 @@ func FilGenerateWinningPostSectorChallenge(registeredProof FilRegisteredPoStProo return __v } -// FilGenerateFallbackSectorChallenges function as declared in filecoin-ffi/filcrypto.h:778 +// FilGenerateFallbackSectorChallenges function as declared in filecoin-ffi/filcrypto.h:780 func FilGenerateFallbackSectorChallenges(registeredProof FilRegisteredPoStProof, randomness Fil32ByteArray, sectorIdsPtr []uint64, sectorIdsLen uint, proverId Fil32ByteArray) *FilGenerateFallbackSectorChallengesResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown crandomness, crandomnessAllocMap := randomness.PassValue() @@ -562,7 +562,7 @@ func FilGenerateFallbackSectorChallenges(registeredProof FilRegisteredPoStProof, return __v } -// FilGenerateSingleVanillaProof function as declared in filecoin-ffi/filcrypto.h:788 +// FilGenerateSingleVanillaProof function as declared in filecoin-ffi/filcrypto.h:790 func FilGenerateSingleVanillaProof(replica FilPrivateReplicaInfo, challengesPtr []uint64, challengesLen uint) *FilGenerateSingleVanillaProofResponse { creplica, creplicaAllocMap := replica.PassValue() cchallengesPtr, cchallengesPtrAllocMap := copyPUint64TBytes((*sliceHeader)(unsafe.Pointer(&challengesPtr))) @@ -575,7 +575,7 @@ func FilGenerateSingleVanillaProof(replica FilPrivateReplicaInfo, challengesPtr return __v } -// FilGenerateWinningPostWithVanilla function as declared in filecoin-ffi/filcrypto.h:796 +// FilGenerateWinningPostWithVanilla function as declared in filecoin-ffi/filcrypto.h:798 func FilGenerateWinningPostWithVanilla(registeredProof FilRegisteredPoStProof, randomness Fil32ByteArray, proverId Fil32ByteArray, vanillaProofsPtr []FilVanillaProof, vanillaProofsLen uint) *FilGenerateWinningPoStResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown crandomness, crandomnessAllocMap := randomness.PassValue() @@ -593,7 +593,7 @@ func FilGenerateWinningPostWithVanilla(registeredProof FilRegisteredPoStProof, r return __v } -// FilGenerateWinningPost function as declared in filecoin-ffi/filcrypto.h:806 +// FilGenerateWinningPost function as declared in filecoin-ffi/filcrypto.h:808 func FilGenerateWinningPost(randomness Fil32ByteArray, replicasPtr []FilPrivateReplicaInfo, replicasLen uint, proverId Fil32ByteArray) *FilGenerateWinningPoStResponse { crandomness, crandomnessAllocMap := randomness.PassValue() creplicasPtr, creplicasPtrAllocMap := unpackArgSFilPrivateReplicaInfo(replicasPtr) @@ -609,7 +609,7 @@ func FilGenerateWinningPost(randomness Fil32ByteArray, replicasPtr []FilPrivateR return __v } -// FilVerifyWinningPost function as declared in filecoin-ffi/filcrypto.h:814 +// FilVerifyWinningPost function as declared in filecoin-ffi/filcrypto.h:816 func FilVerifyWinningPost(randomness Fil32ByteArray, replicasPtr []FilPublicReplicaInfo, replicasLen uint, proofsPtr []FilPoStProof, proofsLen uint, proverId Fil32ByteArray) *FilVerifyWinningPoStResponse { crandomness, crandomnessAllocMap := randomness.PassValue() creplicasPtr, creplicasPtrAllocMap := unpackArgSFilPublicReplicaInfo(replicasPtr) @@ -630,7 +630,7 @@ func FilVerifyWinningPost(randomness Fil32ByteArray, replicasPtr []FilPublicRepl return __v } -// FilGenerateWindowPostWithVanilla function as declared in filecoin-ffi/filcrypto.h:825 +// FilGenerateWindowPostWithVanilla function as declared in filecoin-ffi/filcrypto.h:827 func FilGenerateWindowPostWithVanilla(registeredProof FilRegisteredPoStProof, randomness Fil32ByteArray, proverId Fil32ByteArray, vanillaProofsPtr []FilVanillaProof, vanillaProofsLen uint) *FilGenerateWindowPoStResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown crandomness, crandomnessAllocMap := randomness.PassValue() @@ -648,7 +648,7 @@ func FilGenerateWindowPostWithVanilla(registeredProof FilRegisteredPoStProof, ra return __v } -// FilGenerateWindowPost function as declared in filecoin-ffi/filcrypto.h:835 +// FilGenerateWindowPost function as declared in filecoin-ffi/filcrypto.h:837 func FilGenerateWindowPost(randomness Fil32ByteArray, replicasPtr []FilPrivateReplicaInfo, replicasLen uint, proverId Fil32ByteArray) *FilGenerateWindowPoStResponse { crandomness, crandomnessAllocMap := randomness.PassValue() creplicasPtr, creplicasPtrAllocMap := unpackArgSFilPrivateReplicaInfo(replicasPtr) @@ -664,7 +664,7 @@ func FilGenerateWindowPost(randomness Fil32ByteArray, replicasPtr []FilPrivateRe return __v } -// FilVerifyWindowPost function as declared in filecoin-ffi/filcrypto.h:843 +// FilVerifyWindowPost function as declared in filecoin-ffi/filcrypto.h:845 func FilVerifyWindowPost(randomness Fil32ByteArray, replicasPtr []FilPublicReplicaInfo, replicasLen uint, proofsPtr []FilPoStProof, proofsLen uint, proverId Fil32ByteArray) *FilVerifyWindowPoStResponse { crandomness, crandomnessAllocMap := randomness.PassValue() creplicasPtr, creplicasPtrAllocMap := unpackArgSFilPublicReplicaInfo(replicasPtr) @@ -685,7 +685,7 @@ func FilVerifyWindowPost(randomness Fil32ByteArray, replicasPtr []FilPublicRepli return __v } -// FilMergeWindowPostPartitionProofs function as declared in filecoin-ffi/filcrypto.h:854 +// FilMergeWindowPostPartitionProofs function as declared in filecoin-ffi/filcrypto.h:856 func FilMergeWindowPostPartitionProofs(registeredProof FilRegisteredPoStProof, partitionProofsPtr []FilPartitionSnarkProof, partitionProofsLen uint) *FilMergeWindowPoStPartitionProofsResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown cpartitionProofsPtr, cpartitionProofsPtrAllocMap := unpackArgSFilPartitionSnarkProof(partitionProofsPtr) @@ -699,7 +699,7 @@ func FilMergeWindowPostPartitionProofs(registeredProof FilRegisteredPoStProof, p return __v } -// FilGetNumPartitionForFallbackPost function as declared in filecoin-ffi/filcrypto.h:862 +// FilGetNumPartitionForFallbackPost function as declared in filecoin-ffi/filcrypto.h:864 func FilGetNumPartitionForFallbackPost(registeredProof FilRegisteredPoStProof, numSectors uint) *FilGetNumPartitionForFallbackPoStResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown cnumSectors, cnumSectorsAllocMap := (C.size_t)(numSectors), cgoAllocsUnknown @@ -710,7 +710,7 @@ func FilGetNumPartitionForFallbackPost(registeredProof FilRegisteredPoStProof, n return __v } -// FilGenerateSingleWindowPostWithVanilla function as declared in filecoin-ffi/filcrypto.h:869 +// FilGenerateSingleWindowPostWithVanilla function as declared in filecoin-ffi/filcrypto.h:871 func FilGenerateSingleWindowPostWithVanilla(registeredProof FilRegisteredPoStProof, randomness Fil32ByteArray, proverId Fil32ByteArray, vanillaProofsPtr []FilVanillaProof, vanillaProofsLen uint, partitionIndex uint) *FilGenerateSingleWindowPoStWithVanillaResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown crandomness, crandomnessAllocMap := randomness.PassValue() @@ -730,7 +730,7 @@ func FilGenerateSingleWindowPostWithVanilla(registeredProof FilRegisteredPoStPro return __v } -// FilEmptySectorUpdateEncodeInto function as declared in filecoin-ffi/filcrypto.h:880 +// FilEmptySectorUpdateEncodeInto function as declared in filecoin-ffi/filcrypto.h:882 func FilEmptySectorUpdateEncodeInto(registeredProof FilRegisteredUpdateProof, newReplicaPath string, newCacheDirPath string, sectorKeyPath string, sectorKeyCacheDirPath string, stagedDataPath string, piecesPtr []FilPublicPieceInfo, piecesLen uint) *FilEmptySectorUpdateEncodeIntoResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredUpdateProof)(registeredProof), cgoAllocsUnknown newReplicaPath = safeString(newReplicaPath) @@ -764,7 +764,7 @@ func FilEmptySectorUpdateEncodeInto(registeredProof FilRegisteredUpdateProof, ne return __v } -// FilEmptySectorUpdateDecodeFrom function as declared in filecoin-ffi/filcrypto.h:893 +// FilEmptySectorUpdateDecodeFrom function as declared in filecoin-ffi/filcrypto.h:895 func FilEmptySectorUpdateDecodeFrom(registeredProof FilRegisteredUpdateProof, outDataPath string, replicaPath string, sectorKeyPath string, sectorKeyCacheDirPath string, commDNew Fil32ByteArray) *FilEmptySectorUpdateDecodeFromResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredUpdateProof)(registeredProof), cgoAllocsUnknown outDataPath = safeString(outDataPath) @@ -791,7 +791,7 @@ func FilEmptySectorUpdateDecodeFrom(registeredProof FilRegisteredUpdateProof, ou return __v } -// FilEmptySectorUpdateRemoveEncodedData function as declared in filecoin-ffi/filcrypto.h:904 +// FilEmptySectorUpdateRemoveEncodedData function as declared in filecoin-ffi/filcrypto.h:906 func FilEmptySectorUpdateRemoveEncodedData(registeredProof FilRegisteredUpdateProof, sectorKeyPath string, sectorKeyCacheDirPath string, replicaPath string, replicaCachePath string, dataPath string, commDNew Fil32ByteArray) *FilEmptySectorUpdateRemoveEncodedDataResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredUpdateProof)(registeredProof), cgoAllocsUnknown sectorKeyPath = safeString(sectorKeyPath) @@ -822,7 +822,7 @@ func FilEmptySectorUpdateRemoveEncodedData(registeredProof FilRegisteredUpdatePr return __v } -// FilGenerateEmptySectorUpdatePartitionProofs function as declared in filecoin-ffi/filcrypto.h:916 +// FilGenerateEmptySectorUpdatePartitionProofs function as declared in filecoin-ffi/filcrypto.h:918 func FilGenerateEmptySectorUpdatePartitionProofs(registeredProof FilRegisteredUpdateProof, commROld Fil32ByteArray, commRNew Fil32ByteArray, commDNew Fil32ByteArray, sectorKeyPath string, sectorKeyCacheDirPath string, replicaPath string, replicaCachePath string) *FilPartitionProofResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredUpdateProof)(registeredProof), cgoAllocsUnknown ccommROld, ccommROldAllocMap := commROld.PassValue() @@ -853,7 +853,7 @@ func FilGenerateEmptySectorUpdatePartitionProofs(registeredProof FilRegisteredUp return __v } -// FilVerifyEmptySectorUpdatePartitionProofs function as declared in filecoin-ffi/filcrypto.h:929 +// FilVerifyEmptySectorUpdatePartitionProofs function as declared in filecoin-ffi/filcrypto.h:931 func FilVerifyEmptySectorUpdatePartitionProofs(registeredProof FilRegisteredUpdateProof, proofsLen uint, proofsPtr []FilPartitionProof, commROld Fil32ByteArray, commRNew Fil32ByteArray, commDNew Fil32ByteArray) *FilVerifyPartitionProofResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredUpdateProof)(registeredProof), cgoAllocsUnknown cproofsLen, cproofsLenAllocMap := (C.size_t)(proofsLen), cgoAllocsUnknown @@ -873,7 +873,7 @@ func FilVerifyEmptySectorUpdatePartitionProofs(registeredProof FilRegisteredUpda return __v } -// FilGenerateEmptySectorUpdateProofWithVanilla function as declared in filecoin-ffi/filcrypto.h:940 +// FilGenerateEmptySectorUpdateProofWithVanilla function as declared in filecoin-ffi/filcrypto.h:942 func FilGenerateEmptySectorUpdateProofWithVanilla(registeredProof FilRegisteredUpdateProof, vanillaProofsPtr []FilPartitionProof, vanillaProofsLen uint, commROld Fil32ByteArray, commRNew Fil32ByteArray, commDNew Fil32ByteArray) *FilEmptySectorUpdateProofResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredUpdateProof)(registeredProof), cgoAllocsUnknown cvanillaProofsPtr, cvanillaProofsPtrAllocMap := unpackArgSFilPartitionProof(vanillaProofsPtr) @@ -893,7 +893,7 @@ func FilGenerateEmptySectorUpdateProofWithVanilla(registeredProof FilRegisteredU return __v } -// FilGenerateEmptySectorUpdateProof function as declared in filecoin-ffi/filcrypto.h:951 +// FilGenerateEmptySectorUpdateProof function as declared in filecoin-ffi/filcrypto.h:953 func FilGenerateEmptySectorUpdateProof(registeredProof FilRegisteredUpdateProof, commROld Fil32ByteArray, commRNew Fil32ByteArray, commDNew Fil32ByteArray, sectorKeyPath string, sectorKeyCacheDirPath string, replicaPath string, replicaCachePath string) *FilEmptySectorUpdateProofResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredUpdateProof)(registeredProof), cgoAllocsUnknown ccommROld, ccommROldAllocMap := commROld.PassValue() @@ -924,7 +924,7 @@ func FilGenerateEmptySectorUpdateProof(registeredProof FilRegisteredUpdateProof, return __v } -// FilVerifyEmptySectorUpdateProof function as declared in filecoin-ffi/filcrypto.h:964 +// FilVerifyEmptySectorUpdateProof function as declared in filecoin-ffi/filcrypto.h:966 func FilVerifyEmptySectorUpdateProof(registeredProof FilRegisteredUpdateProof, proofPtr []byte, proofLen uint, commROld Fil32ByteArray, commRNew Fil32ByteArray, commDNew Fil32ByteArray) *FilVerifyEmptySectorUpdateProofResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredUpdateProof)(registeredProof), cgoAllocsUnknown cproofPtr, cproofPtrAllocMap := copyPUint8TBytes((*sliceHeader)(unsafe.Pointer(&proofPtr))) @@ -943,7 +943,7 @@ func FilVerifyEmptySectorUpdateProof(registeredProof FilRegisteredUpdateProof, p return __v } -// FilGeneratePieceCommitment function as declared in filecoin-ffi/filcrypto.h:975 +// FilGeneratePieceCommitment function as declared in filecoin-ffi/filcrypto.h:977 func FilGeneratePieceCommitment(registeredProof FilRegisteredSealProof, pieceFdRaw int32, unpaddedPieceSize uint64) *FilGeneratePieceCommitmentResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown cpieceFdRaw, cpieceFdRawAllocMap := (C.int)(pieceFdRaw), cgoAllocsUnknown @@ -956,7 +956,7 @@ func FilGeneratePieceCommitment(registeredProof FilRegisteredSealProof, pieceFdR return __v } -// FilGenerateDataCommitment function as declared in filecoin-ffi/filcrypto.h:982 +// FilGenerateDataCommitment function as declared in filecoin-ffi/filcrypto.h:984 func FilGenerateDataCommitment(registeredProof FilRegisteredSealProof, piecesPtr []FilPublicPieceInfo, piecesLen uint) *FilGenerateDataCommitmentResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown cpiecesPtr, cpiecesPtrAllocMap := unpackArgSFilPublicPieceInfo(piecesPtr) @@ -970,7 +970,7 @@ func FilGenerateDataCommitment(registeredProof FilRegisteredSealProof, piecesPtr return __v } -// FilClearCache function as declared in filecoin-ffi/filcrypto.h:986 +// FilClearCache function as declared in filecoin-ffi/filcrypto.h:988 func FilClearCache(sectorSize uint64, cacheDirPath string) *FilClearCacheResponse { csectorSize, csectorSizeAllocMap := (C.uint64_t)(sectorSize), cgoAllocsUnknown cacheDirPath = safeString(cacheDirPath) @@ -983,84 +983,84 @@ func FilClearCache(sectorSize uint64, cacheDirPath string) *FilClearCacheRespons return __v } -// FilDestroyWriteWithAlignmentResponse function as declared in filecoin-ffi/filcrypto.h:988 +// FilDestroyWriteWithAlignmentResponse function as declared in filecoin-ffi/filcrypto.h:990 func FilDestroyWriteWithAlignmentResponse(ptr *FilWriteWithAlignmentResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_write_with_alignment_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyWriteWithoutAlignmentResponse function as declared in filecoin-ffi/filcrypto.h:990 +// FilDestroyWriteWithoutAlignmentResponse function as declared in filecoin-ffi/filcrypto.h:992 func FilDestroyWriteWithoutAlignmentResponse(ptr *FilWriteWithoutAlignmentResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_write_without_alignment_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyFauxrepResponse function as declared in filecoin-ffi/filcrypto.h:992 +// FilDestroyFauxrepResponse function as declared in filecoin-ffi/filcrypto.h:994 func FilDestroyFauxrepResponse(ptr *FilFauxRepResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_fauxrep_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroySealPreCommitPhase1Response function as declared in filecoin-ffi/filcrypto.h:994 +// FilDestroySealPreCommitPhase1Response function as declared in filecoin-ffi/filcrypto.h:996 func FilDestroySealPreCommitPhase1Response(ptr *FilSealPreCommitPhase1Response) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_seal_pre_commit_phase1_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroySealPreCommitPhase2Response function as declared in filecoin-ffi/filcrypto.h:996 +// FilDestroySealPreCommitPhase2Response function as declared in filecoin-ffi/filcrypto.h:998 func FilDestroySealPreCommitPhase2Response(ptr *FilSealPreCommitPhase2Response) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_seal_pre_commit_phase2_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroySealCommitPhase1Response function as declared in filecoin-ffi/filcrypto.h:998 +// FilDestroySealCommitPhase1Response function as declared in filecoin-ffi/filcrypto.h:1000 func FilDestroySealCommitPhase1Response(ptr *FilSealCommitPhase1Response) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_seal_commit_phase1_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroySealCommitPhase2Response function as declared in filecoin-ffi/filcrypto.h:1000 +// FilDestroySealCommitPhase2Response function as declared in filecoin-ffi/filcrypto.h:1002 func FilDestroySealCommitPhase2Response(ptr *FilSealCommitPhase2Response) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_seal_commit_phase2_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyUnsealRangeResponse function as declared in filecoin-ffi/filcrypto.h:1002 +// FilDestroyUnsealRangeResponse function as declared in filecoin-ffi/filcrypto.h:1004 func FilDestroyUnsealRangeResponse(ptr *FilUnsealRangeResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_unseal_range_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGeneratePieceCommitmentResponse function as declared in filecoin-ffi/filcrypto.h:1004 +// FilDestroyGeneratePieceCommitmentResponse function as declared in filecoin-ffi/filcrypto.h:1006 func FilDestroyGeneratePieceCommitmentResponse(ptr *FilGeneratePieceCommitmentResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_piece_commitment_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGenerateDataCommitmentResponse function as declared in filecoin-ffi/filcrypto.h:1006 +// FilDestroyGenerateDataCommitmentResponse function as declared in filecoin-ffi/filcrypto.h:1008 func FilDestroyGenerateDataCommitmentResponse(ptr *FilGenerateDataCommitmentResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_data_commitment_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyStringResponse function as declared in filecoin-ffi/filcrypto.h:1008 +// FilDestroyStringResponse function as declared in filecoin-ffi/filcrypto.h:1010 func FilDestroyStringResponse(ptr *FilStringResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_string_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilGetMaxUserBytesPerStagedSector function as declared in filecoin-ffi/filcrypto.h:1014 +// FilGetMaxUserBytesPerStagedSector function as declared in filecoin-ffi/filcrypto.h:1016 func FilGetMaxUserBytesPerStagedSector(registeredProof FilRegisteredSealProof) uint64 { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_max_user_bytes_per_staged_sector(cregisteredProof) @@ -1069,7 +1069,7 @@ func FilGetMaxUserBytesPerStagedSector(registeredProof FilRegisteredSealProof) u return __v } -// FilGetSealParamsCid function as declared in filecoin-ffi/filcrypto.h:1020 +// FilGetSealParamsCid function as declared in filecoin-ffi/filcrypto.h:1022 func FilGetSealParamsCid(registeredProof FilRegisteredSealProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_seal_params_cid(cregisteredProof) @@ -1078,7 +1078,7 @@ func FilGetSealParamsCid(registeredProof FilRegisteredSealProof) *FilStringRespo return __v } -// FilGetSealVerifyingKeyCid function as declared in filecoin-ffi/filcrypto.h:1026 +// FilGetSealVerifyingKeyCid function as declared in filecoin-ffi/filcrypto.h:1028 func FilGetSealVerifyingKeyCid(registeredProof FilRegisteredSealProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_seal_verifying_key_cid(cregisteredProof) @@ -1087,7 +1087,7 @@ func FilGetSealVerifyingKeyCid(registeredProof FilRegisteredSealProof) *FilStrin return __v } -// FilGetSealParamsPath function as declared in filecoin-ffi/filcrypto.h:1033 +// FilGetSealParamsPath function as declared in filecoin-ffi/filcrypto.h:1035 func FilGetSealParamsPath(registeredProof FilRegisteredSealProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_seal_params_path(cregisteredProof) @@ -1096,7 +1096,7 @@ func FilGetSealParamsPath(registeredProof FilRegisteredSealProof) *FilStringResp return __v } -// FilGetSealVerifyingKeyPath function as declared in filecoin-ffi/filcrypto.h:1040 +// FilGetSealVerifyingKeyPath function as declared in filecoin-ffi/filcrypto.h:1042 func FilGetSealVerifyingKeyPath(registeredProof FilRegisteredSealProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_seal_verifying_key_path(cregisteredProof) @@ -1105,7 +1105,7 @@ func FilGetSealVerifyingKeyPath(registeredProof FilRegisteredSealProof) *FilStri return __v } -// FilGetSealCircuitIdentifier function as declared in filecoin-ffi/filcrypto.h:1046 +// FilGetSealCircuitIdentifier function as declared in filecoin-ffi/filcrypto.h:1048 func FilGetSealCircuitIdentifier(registeredProof FilRegisteredSealProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_seal_circuit_identifier(cregisteredProof) @@ -1114,7 +1114,7 @@ func FilGetSealCircuitIdentifier(registeredProof FilRegisteredSealProof) *FilStr return __v } -// FilGetSealVersion function as declared in filecoin-ffi/filcrypto.h:1052 +// FilGetSealVersion function as declared in filecoin-ffi/filcrypto.h:1054 func FilGetSealVersion(registeredProof FilRegisteredSealProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredSealProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_seal_version(cregisteredProof) @@ -1123,7 +1123,7 @@ func FilGetSealVersion(registeredProof FilRegisteredSealProof) *FilStringRespons return __v } -// FilGetPostParamsCid function as declared in filecoin-ffi/filcrypto.h:1058 +// FilGetPostParamsCid function as declared in filecoin-ffi/filcrypto.h:1060 func FilGetPostParamsCid(registeredProof FilRegisteredPoStProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_post_params_cid(cregisteredProof) @@ -1132,7 +1132,7 @@ func FilGetPostParamsCid(registeredProof FilRegisteredPoStProof) *FilStringRespo return __v } -// FilGetPostVerifyingKeyCid function as declared in filecoin-ffi/filcrypto.h:1064 +// FilGetPostVerifyingKeyCid function as declared in filecoin-ffi/filcrypto.h:1066 func FilGetPostVerifyingKeyCid(registeredProof FilRegisteredPoStProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_post_verifying_key_cid(cregisteredProof) @@ -1141,7 +1141,7 @@ func FilGetPostVerifyingKeyCid(registeredProof FilRegisteredPoStProof) *FilStrin return __v } -// FilGetPostParamsPath function as declared in filecoin-ffi/filcrypto.h:1071 +// FilGetPostParamsPath function as declared in filecoin-ffi/filcrypto.h:1073 func FilGetPostParamsPath(registeredProof FilRegisteredPoStProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_post_params_path(cregisteredProof) @@ -1150,7 +1150,7 @@ func FilGetPostParamsPath(registeredProof FilRegisteredPoStProof) *FilStringResp return __v } -// FilGetPostVerifyingKeyPath function as declared in filecoin-ffi/filcrypto.h:1078 +// FilGetPostVerifyingKeyPath function as declared in filecoin-ffi/filcrypto.h:1080 func FilGetPostVerifyingKeyPath(registeredProof FilRegisteredPoStProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_post_verifying_key_path(cregisteredProof) @@ -1159,7 +1159,7 @@ func FilGetPostVerifyingKeyPath(registeredProof FilRegisteredPoStProof) *FilStri return __v } -// FilGetPostCircuitIdentifier function as declared in filecoin-ffi/filcrypto.h:1084 +// FilGetPostCircuitIdentifier function as declared in filecoin-ffi/filcrypto.h:1086 func FilGetPostCircuitIdentifier(registeredProof FilRegisteredPoStProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_post_circuit_identifier(cregisteredProof) @@ -1168,7 +1168,7 @@ func FilGetPostCircuitIdentifier(registeredProof FilRegisteredPoStProof) *FilStr return __v } -// FilGetPostVersion function as declared in filecoin-ffi/filcrypto.h:1090 +// FilGetPostVersion function as declared in filecoin-ffi/filcrypto.h:1092 func FilGetPostVersion(registeredProof FilRegisteredPoStProof) *FilStringResponse { cregisteredProof, cregisteredProofAllocMap := (C.enum_fil_RegisteredPoStProof)(registeredProof), cgoAllocsUnknown __ret := C.fil_get_post_version(cregisteredProof) @@ -1177,168 +1177,168 @@ func FilGetPostVersion(registeredProof FilRegisteredPoStProof) *FilStringRespons return __v } -// FilDestroyVerifySealResponse function as declared in filecoin-ffi/filcrypto.h:1096 +// FilDestroyVerifySealResponse function as declared in filecoin-ffi/filcrypto.h:1098 func FilDestroyVerifySealResponse(ptr *FilVerifySealResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_verify_seal_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyVerifyAggregateSealResponse function as declared in filecoin-ffi/filcrypto.h:1102 +// FilDestroyVerifyAggregateSealResponse function as declared in filecoin-ffi/filcrypto.h:1104 func FilDestroyVerifyAggregateSealResponse(ptr *FilVerifyAggregateSealProofResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_verify_aggregate_seal_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyFinalizeTicketResponse function as declared in filecoin-ffi/filcrypto.h:1104 +// FilDestroyFinalizeTicketResponse function as declared in filecoin-ffi/filcrypto.h:1106 func FilDestroyFinalizeTicketResponse(ptr *FilFinalizeTicketResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_finalize_ticket_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyVerifyWinningPostResponse function as declared in filecoin-ffi/filcrypto.h:1110 +// FilDestroyVerifyWinningPostResponse function as declared in filecoin-ffi/filcrypto.h:1112 func FilDestroyVerifyWinningPostResponse(ptr *FilVerifyWinningPoStResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_verify_winning_post_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyVerifyWindowPostResponse function as declared in filecoin-ffi/filcrypto.h:1112 +// FilDestroyVerifyWindowPostResponse function as declared in filecoin-ffi/filcrypto.h:1114 func FilDestroyVerifyWindowPostResponse(ptr *FilVerifyWindowPoStResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_verify_window_post_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGenerateFallbackSectorChallengesResponse function as declared in filecoin-ffi/filcrypto.h:1114 +// FilDestroyGenerateFallbackSectorChallengesResponse function as declared in filecoin-ffi/filcrypto.h:1116 func FilDestroyGenerateFallbackSectorChallengesResponse(ptr *FilGenerateFallbackSectorChallengesResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_fallback_sector_challenges_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGenerateSingleVanillaProofResponse function as declared in filecoin-ffi/filcrypto.h:1116 +// FilDestroyGenerateSingleVanillaProofResponse function as declared in filecoin-ffi/filcrypto.h:1118 func FilDestroyGenerateSingleVanillaProofResponse(ptr *FilGenerateSingleVanillaProofResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_single_vanilla_proof_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGenerateSingleWindowPostWithVanillaResponse function as declared in filecoin-ffi/filcrypto.h:1118 +// FilDestroyGenerateSingleWindowPostWithVanillaResponse function as declared in filecoin-ffi/filcrypto.h:1120 func FilDestroyGenerateSingleWindowPostWithVanillaResponse(ptr *FilGenerateSingleWindowPoStWithVanillaResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_single_window_post_with_vanilla_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGetNumPartitionForFallbackPostResponse function as declared in filecoin-ffi/filcrypto.h:1120 +// FilDestroyGetNumPartitionForFallbackPostResponse function as declared in filecoin-ffi/filcrypto.h:1122 func FilDestroyGetNumPartitionForFallbackPostResponse(ptr *FilGetNumPartitionForFallbackPoStResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_get_num_partition_for_fallback_post_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyMergeWindowPostPartitionProofsResponse function as declared in filecoin-ffi/filcrypto.h:1122 +// FilDestroyMergeWindowPostPartitionProofsResponse function as declared in filecoin-ffi/filcrypto.h:1124 func FilDestroyMergeWindowPostPartitionProofsResponse(ptr *FilMergeWindowPoStPartitionProofsResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_merge_window_post_partition_proofs_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGenerateWinningPostResponse function as declared in filecoin-ffi/filcrypto.h:1124 +// FilDestroyGenerateWinningPostResponse function as declared in filecoin-ffi/filcrypto.h:1126 func FilDestroyGenerateWinningPostResponse(ptr *FilGenerateWinningPoStResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_winning_post_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGenerateWindowPostResponse function as declared in filecoin-ffi/filcrypto.h:1126 +// FilDestroyGenerateWindowPostResponse function as declared in filecoin-ffi/filcrypto.h:1128 func FilDestroyGenerateWindowPostResponse(ptr *FilGenerateWindowPoStResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_window_post_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGenerateWinningPostSectorChallenge function as declared in filecoin-ffi/filcrypto.h:1128 +// FilDestroyGenerateWinningPostSectorChallenge function as declared in filecoin-ffi/filcrypto.h:1130 func FilDestroyGenerateWinningPostSectorChallenge(ptr *FilGenerateWinningPoStSectorChallenge) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_winning_post_sector_challenge(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyClearCacheResponse function as declared in filecoin-ffi/filcrypto.h:1130 +// FilDestroyClearCacheResponse function as declared in filecoin-ffi/filcrypto.h:1132 func FilDestroyClearCacheResponse(ptr *FilClearCacheResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_clear_cache_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyAggregateProof function as declared in filecoin-ffi/filcrypto.h:1136 +// FilDestroyAggregateProof function as declared in filecoin-ffi/filcrypto.h:1138 func FilDestroyAggregateProof(ptr *FilAggregateProof) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_aggregate_proof(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyEmptySectorUpdateGenerateProofResponse function as declared in filecoin-ffi/filcrypto.h:1142 +// FilDestroyEmptySectorUpdateGenerateProofResponse function as declared in filecoin-ffi/filcrypto.h:1144 func FilDestroyEmptySectorUpdateGenerateProofResponse(ptr *FilEmptySectorUpdateProofResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_empty_sector_update_generate_proof_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyEmptySectorUpdateVerifyProofResponse function as declared in filecoin-ffi/filcrypto.h:1148 +// FilDestroyEmptySectorUpdateVerifyProofResponse function as declared in filecoin-ffi/filcrypto.h:1150 func FilDestroyEmptySectorUpdateVerifyProofResponse(ptr *FilVerifyEmptySectorUpdateProofResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_empty_sector_update_verify_proof_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyGenerateEmptySectorUpdatePartitionProofResponse function as declared in filecoin-ffi/filcrypto.h:1154 +// FilDestroyGenerateEmptySectorUpdatePartitionProofResponse function as declared in filecoin-ffi/filcrypto.h:1156 func FilDestroyGenerateEmptySectorUpdatePartitionProofResponse(ptr *FilPartitionProofResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_generate_empty_sector_update_partition_proof_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyVerifyEmptySectorUpdatePartitionProofResponse function as declared in filecoin-ffi/filcrypto.h:1160 +// FilDestroyVerifyEmptySectorUpdatePartitionProofResponse function as declared in filecoin-ffi/filcrypto.h:1162 func FilDestroyVerifyEmptySectorUpdatePartitionProofResponse(ptr *FilVerifyPartitionProofResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_verify_empty_sector_update_partition_proof_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyEmptySectorUpdateEncodeIntoResponse function as declared in filecoin-ffi/filcrypto.h:1166 +// FilDestroyEmptySectorUpdateEncodeIntoResponse function as declared in filecoin-ffi/filcrypto.h:1168 func FilDestroyEmptySectorUpdateEncodeIntoResponse(ptr *FilEmptySectorUpdateEncodeIntoResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_empty_sector_update_encode_into_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyEmptySectorUpdateDecodeFromResponse function as declared in filecoin-ffi/filcrypto.h:1172 +// FilDestroyEmptySectorUpdateDecodeFromResponse function as declared in filecoin-ffi/filcrypto.h:1174 func FilDestroyEmptySectorUpdateDecodeFromResponse(ptr *FilEmptySectorUpdateDecodeFromResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_empty_sector_update_decode_from_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyEmptySectorUpdateRemoveEncodedDataResponse function as declared in filecoin-ffi/filcrypto.h:1178 +// FilDestroyEmptySectorUpdateRemoveEncodedDataResponse function as declared in filecoin-ffi/filcrypto.h:1180 func FilDestroyEmptySectorUpdateRemoveEncodedDataResponse(ptr *FilEmptySectorUpdateRemoveEncodedDataResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_empty_sector_update_remove_encoded_data_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilGetGpuDevices function as declared in filecoin-ffi/filcrypto.h:1183 +// FilGetGpuDevices function as declared in filecoin-ffi/filcrypto.h:1185 func FilGetGpuDevices() *FilGpuDeviceResponse { __ret := C.fil_get_gpu_devices() __v := NewFilGpuDeviceResponseRef(unsafe.Pointer(__ret)) return __v } -// FilInitLogFd function as declared in filecoin-ffi/filcrypto.h:1194 +// FilInitLogFd function as declared in filecoin-ffi/filcrypto.h:1196 func FilInitLogFd(logFd int32) *FilInitLogFdResponse { clogFd, clogFdAllocMap := (C.int)(logFd), cgoAllocsUnknown __ret := C.fil_init_log_fd(clogFd) @@ -1347,14 +1347,14 @@ func FilInitLogFd(logFd int32) *FilInitLogFdResponse { return __v } -// FilDestroyGpuDeviceResponse function as declared in filecoin-ffi/filcrypto.h:1196 +// FilDestroyGpuDeviceResponse function as declared in filecoin-ffi/filcrypto.h:1198 func FilDestroyGpuDeviceResponse(ptr *FilGpuDeviceResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_gpu_device_response(cptr) runtime.KeepAlive(cptrAllocMap) } -// FilDestroyInitLogFdResponse function as declared in filecoin-ffi/filcrypto.h:1198 +// FilDestroyInitLogFdResponse function as declared in filecoin-ffi/filcrypto.h:1200 func FilDestroyInitLogFdResponse(ptr *FilInitLogFdResponse) { cptr, cptrAllocMap := ptr.PassRef() C.fil_destroy_init_log_fd_response(cptr) diff --git a/generated/types.go b/generated/types.go index 8b3639d5..2466f61d 100644 --- a/generated/types.go +++ b/generated/types.go @@ -100,7 +100,7 @@ type FilCreateFvmMachineResponse struct { allocs40465416 interface{} } -// FilFvmMachineExecuteResponse as declared in filecoin-ffi/filcrypto.h:181 +// FilFvmMachineExecuteResponse as declared in filecoin-ffi/filcrypto.h:183 type FilFvmMachineExecuteResponse struct { ErrorMsg string StatusCode FCPResponseStatus @@ -114,11 +114,13 @@ type FilFvmMachineExecuteResponse struct { MinerTipLo uint64 ExecTracePtr []byte ExecTraceLen uint + FailureInfoPtr []byte + FailureInfoLen uint ref88f63595 *C.fil_FvmMachineExecuteResponse allocs88f63595 interface{} } -// FilFvmMachineFlushResponse as declared in filecoin-ffi/filcrypto.h:188 +// FilFvmMachineFlushResponse as declared in filecoin-ffi/filcrypto.h:190 type FilFvmMachineFlushResponse struct { ErrorMsg string StatusCode FCPResponseStatus @@ -128,7 +130,7 @@ type FilFvmMachineFlushResponse struct { allocs9eb3b4f4 interface{} } -// FilWriteWithAlignmentResponse as declared in filecoin-ffi/filcrypto.h:196 +// FilWriteWithAlignmentResponse as declared in filecoin-ffi/filcrypto.h:198 type FilWriteWithAlignmentResponse struct { CommP [32]byte ErrorMsg string @@ -139,7 +141,7 @@ type FilWriteWithAlignmentResponse struct { allocsa330e79 interface{} } -// FilWriteWithoutAlignmentResponse as declared in filecoin-ffi/filcrypto.h:203 +// FilWriteWithoutAlignmentResponse as declared in filecoin-ffi/filcrypto.h:205 type FilWriteWithoutAlignmentResponse struct { CommP [32]byte ErrorMsg string @@ -149,7 +151,7 @@ type FilWriteWithoutAlignmentResponse struct { allocsc8e1ed8 interface{} } -// FilFauxRepResponse as declared in filecoin-ffi/filcrypto.h:209 +// FilFauxRepResponse as declared in filecoin-ffi/filcrypto.h:211 type FilFauxRepResponse struct { ErrorMsg string StatusCode FCPResponseStatus @@ -158,7 +160,7 @@ type FilFauxRepResponse struct { allocsaa003f71 interface{} } -// FilSealPreCommitPhase1Response as declared in filecoin-ffi/filcrypto.h:216 +// FilSealPreCommitPhase1Response as declared in filecoin-ffi/filcrypto.h:218 type FilSealPreCommitPhase1Response struct { ErrorMsg string StatusCode FCPResponseStatus @@ -168,7 +170,7 @@ type FilSealPreCommitPhase1Response struct { allocs132bbfd8 interface{} } -// FilPublicPieceInfo as declared in filecoin-ffi/filcrypto.h:221 +// FilPublicPieceInfo as declared in filecoin-ffi/filcrypto.h:223 type FilPublicPieceInfo struct { NumBytes uint64 CommP [32]byte @@ -176,7 +178,7 @@ type FilPublicPieceInfo struct { allocsd00025ac interface{} } -// FilSealPreCommitPhase2Response as declared in filecoin-ffi/filcrypto.h:229 +// FilSealPreCommitPhase2Response as declared in filecoin-ffi/filcrypto.h:231 type FilSealPreCommitPhase2Response struct { ErrorMsg string StatusCode FCPResponseStatus @@ -187,7 +189,7 @@ type FilSealPreCommitPhase2Response struct { allocs2aa6831d interface{} } -// FilSealCommitPhase1Response as declared in filecoin-ffi/filcrypto.h:236 +// FilSealCommitPhase1Response as declared in filecoin-ffi/filcrypto.h:238 type FilSealCommitPhase1Response struct { StatusCode FCPResponseStatus ErrorMsg string @@ -197,7 +199,7 @@ type FilSealCommitPhase1Response struct { allocs61ed8561 interface{} } -// FilAggregationInputs as declared in filecoin-ffi/filcrypto.h:244 +// FilAggregationInputs as declared in filecoin-ffi/filcrypto.h:246 type FilAggregationInputs struct { CommR Fil32ByteArray CommD Fil32ByteArray @@ -208,7 +210,7 @@ type FilAggregationInputs struct { allocs90b967c9 interface{} } -// FilSealCommitPhase2Response as declared in filecoin-ffi/filcrypto.h:253 +// FilSealCommitPhase2Response as declared in filecoin-ffi/filcrypto.h:255 type FilSealCommitPhase2Response struct { StatusCode FCPResponseStatus ErrorMsg string @@ -220,7 +222,7 @@ type FilSealCommitPhase2Response struct { allocs5860b9a4 interface{} } -// FilAggregateProof as declared in filecoin-ffi/filcrypto.h:260 +// FilAggregateProof as declared in filecoin-ffi/filcrypto.h:262 type FilAggregateProof struct { StatusCode FCPResponseStatus ErrorMsg string @@ -230,7 +232,7 @@ type FilAggregateProof struct { allocs22b6c4f6 interface{} } -// FilVerifyAggregateSealProofResponse as declared in filecoin-ffi/filcrypto.h:266 +// FilVerifyAggregateSealProofResponse as declared in filecoin-ffi/filcrypto.h:268 type FilVerifyAggregateSealProofResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -239,7 +241,7 @@ type FilVerifyAggregateSealProofResponse struct { allocs66180e0 interface{} } -// FilUnsealRangeResponse as declared in filecoin-ffi/filcrypto.h:271 +// FilUnsealRangeResponse as declared in filecoin-ffi/filcrypto.h:273 type FilUnsealRangeResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -247,7 +249,7 @@ type FilUnsealRangeResponse struct { allocs61e219c9 interface{} } -// FilVerifySealResponse as declared in filecoin-ffi/filcrypto.h:277 +// FilVerifySealResponse as declared in filecoin-ffi/filcrypto.h:279 type FilVerifySealResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -256,7 +258,7 @@ type FilVerifySealResponse struct { allocsd4397079 interface{} } -// FilGenerateWinningPoStSectorChallenge as declared in filecoin-ffi/filcrypto.h:284 +// FilGenerateWinningPoStSectorChallenge as declared in filecoin-ffi/filcrypto.h:286 type FilGenerateWinningPoStSectorChallenge struct { ErrorMsg string StatusCode FCPResponseStatus @@ -266,7 +268,7 @@ type FilGenerateWinningPoStSectorChallenge struct { allocs69d2a405 interface{} } -// FilGenerateFallbackSectorChallengesResponse as declared in filecoin-ffi/filcrypto.h:294 +// FilGenerateFallbackSectorChallengesResponse as declared in filecoin-ffi/filcrypto.h:296 type FilGenerateFallbackSectorChallengesResponse struct { ErrorMsg string StatusCode FCPResponseStatus @@ -279,7 +281,7 @@ type FilGenerateFallbackSectorChallengesResponse struct { allocs7047a3fa interface{} } -// FilVanillaProof as declared in filecoin-ffi/filcrypto.h:299 +// FilVanillaProof as declared in filecoin-ffi/filcrypto.h:301 type FilVanillaProof struct { ProofLen uint ProofPtr []byte @@ -287,7 +289,7 @@ type FilVanillaProof struct { allocsb3e7638c interface{} } -// FilGenerateSingleVanillaProofResponse as declared in filecoin-ffi/filcrypto.h:305 +// FilGenerateSingleVanillaProofResponse as declared in filecoin-ffi/filcrypto.h:307 type FilGenerateSingleVanillaProofResponse struct { ErrorMsg string VanillaProof FilVanillaProof @@ -296,7 +298,7 @@ type FilGenerateSingleVanillaProofResponse struct { allocsf9d21b04 interface{} } -// FilPrivateReplicaInfo as declared in filecoin-ffi/filcrypto.h:313 +// FilPrivateReplicaInfo as declared in filecoin-ffi/filcrypto.h:315 type FilPrivateReplicaInfo struct { RegisteredProof FilRegisteredPoStProof CacheDirPath string @@ -307,7 +309,7 @@ type FilPrivateReplicaInfo struct { allocs81a31e9b interface{} } -// FilPoStProof as declared in filecoin-ffi/filcrypto.h:319 +// FilPoStProof as declared in filecoin-ffi/filcrypto.h:321 type FilPoStProof struct { RegisteredProof FilRegisteredPoStProof ProofLen uint @@ -316,7 +318,7 @@ type FilPoStProof struct { allocs3451bfa interface{} } -// FilGenerateWinningPoStResponse as declared in filecoin-ffi/filcrypto.h:326 +// FilGenerateWinningPoStResponse as declared in filecoin-ffi/filcrypto.h:328 type FilGenerateWinningPoStResponse struct { ErrorMsg string ProofsLen uint @@ -326,7 +328,7 @@ type FilGenerateWinningPoStResponse struct { allocs1405b8ec interface{} } -// FilVerifyWinningPoStResponse as declared in filecoin-ffi/filcrypto.h:332 +// FilVerifyWinningPoStResponse as declared in filecoin-ffi/filcrypto.h:334 type FilVerifyWinningPoStResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -335,7 +337,7 @@ type FilVerifyWinningPoStResponse struct { allocsaca6860c interface{} } -// FilPublicReplicaInfo as declared in filecoin-ffi/filcrypto.h:338 +// FilPublicReplicaInfo as declared in filecoin-ffi/filcrypto.h:340 type FilPublicReplicaInfo struct { RegisteredProof FilRegisteredPoStProof CommR [32]byte @@ -344,7 +346,7 @@ type FilPublicReplicaInfo struct { allocs81b617c2 interface{} } -// FilGenerateWindowPoStResponse as declared in filecoin-ffi/filcrypto.h:347 +// FilGenerateWindowPoStResponse as declared in filecoin-ffi/filcrypto.h:349 type FilGenerateWindowPoStResponse struct { ErrorMsg string ProofsLen uint @@ -356,7 +358,7 @@ type FilGenerateWindowPoStResponse struct { allocs2a5f3ba8 interface{} } -// FilVerifyWindowPoStResponse as declared in filecoin-ffi/filcrypto.h:353 +// FilVerifyWindowPoStResponse as declared in filecoin-ffi/filcrypto.h:355 type FilVerifyWindowPoStResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -365,7 +367,7 @@ type FilVerifyWindowPoStResponse struct { allocs34c4d49f interface{} } -// FilMergeWindowPoStPartitionProofsResponse as declared in filecoin-ffi/filcrypto.h:359 +// FilMergeWindowPoStPartitionProofsResponse as declared in filecoin-ffi/filcrypto.h:361 type FilMergeWindowPoStPartitionProofsResponse struct { ErrorMsg string Proof FilPoStProof @@ -374,7 +376,7 @@ type FilMergeWindowPoStPartitionProofsResponse struct { allocs3369154e interface{} } -// FilPartitionSnarkProof as declared in filecoin-ffi/filcrypto.h:365 +// FilPartitionSnarkProof as declared in filecoin-ffi/filcrypto.h:367 type FilPartitionSnarkProof struct { RegisteredProof FilRegisteredPoStProof ProofLen uint @@ -383,7 +385,7 @@ type FilPartitionSnarkProof struct { allocs4de03739 interface{} } -// FilGetNumPartitionForFallbackPoStResponse as declared in filecoin-ffi/filcrypto.h:371 +// FilGetNumPartitionForFallbackPoStResponse as declared in filecoin-ffi/filcrypto.h:373 type FilGetNumPartitionForFallbackPoStResponse struct { ErrorMsg string StatusCode FCPResponseStatus @@ -392,7 +394,7 @@ type FilGetNumPartitionForFallbackPoStResponse struct { allocsc0084478 interface{} } -// FilGenerateSingleWindowPoStWithVanillaResponse as declared in filecoin-ffi/filcrypto.h:379 +// FilGenerateSingleWindowPoStWithVanillaResponse as declared in filecoin-ffi/filcrypto.h:381 type FilGenerateSingleWindowPoStWithVanillaResponse struct { ErrorMsg string PartitionProof FilPartitionSnarkProof @@ -403,7 +405,7 @@ type FilGenerateSingleWindowPoStWithVanillaResponse struct { allocs96c012c3 interface{} } -// FilEmptySectorUpdateEncodeIntoResponse as declared in filecoin-ffi/filcrypto.h:387 +// FilEmptySectorUpdateEncodeIntoResponse as declared in filecoin-ffi/filcrypto.h:389 type FilEmptySectorUpdateEncodeIntoResponse struct { ErrorMsg string StatusCode FCPResponseStatus @@ -414,7 +416,7 @@ type FilEmptySectorUpdateEncodeIntoResponse struct { allocs8d3238a7 interface{} } -// FilEmptySectorUpdateDecodeFromResponse as declared in filecoin-ffi/filcrypto.h:392 +// FilEmptySectorUpdateDecodeFromResponse as declared in filecoin-ffi/filcrypto.h:394 type FilEmptySectorUpdateDecodeFromResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -422,7 +424,7 @@ type FilEmptySectorUpdateDecodeFromResponse struct { allocsf02a01b8 interface{} } -// FilEmptySectorUpdateRemoveEncodedDataResponse as declared in filecoin-ffi/filcrypto.h:397 +// FilEmptySectorUpdateRemoveEncodedDataResponse as declared in filecoin-ffi/filcrypto.h:399 type FilEmptySectorUpdateRemoveEncodedDataResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -430,7 +432,7 @@ type FilEmptySectorUpdateRemoveEncodedDataResponse struct { allocs50783b83 interface{} } -// FilPartitionProof as declared in filecoin-ffi/filcrypto.h:402 +// FilPartitionProof as declared in filecoin-ffi/filcrypto.h:404 type FilPartitionProof struct { ProofLen uint ProofPtr []byte @@ -438,7 +440,7 @@ type FilPartitionProof struct { allocs566a2be6 interface{} } -// FilPartitionProofResponse as declared in filecoin-ffi/filcrypto.h:409 +// FilPartitionProofResponse as declared in filecoin-ffi/filcrypto.h:411 type FilPartitionProofResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -448,7 +450,7 @@ type FilPartitionProofResponse struct { allocs51343e7a interface{} } -// FilVerifyPartitionProofResponse as declared in filecoin-ffi/filcrypto.h:415 +// FilVerifyPartitionProofResponse as declared in filecoin-ffi/filcrypto.h:417 type FilVerifyPartitionProofResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -457,7 +459,7 @@ type FilVerifyPartitionProofResponse struct { allocsaed1b67 interface{} } -// FilEmptySectorUpdateProofResponse as declared in filecoin-ffi/filcrypto.h:422 +// FilEmptySectorUpdateProofResponse as declared in filecoin-ffi/filcrypto.h:424 type FilEmptySectorUpdateProofResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -467,7 +469,7 @@ type FilEmptySectorUpdateProofResponse struct { allocs5c2faef interface{} } -// FilVerifyEmptySectorUpdateProofResponse as declared in filecoin-ffi/filcrypto.h:428 +// FilVerifyEmptySectorUpdateProofResponse as declared in filecoin-ffi/filcrypto.h:430 type FilVerifyEmptySectorUpdateProofResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -476,7 +478,7 @@ type FilVerifyEmptySectorUpdateProofResponse struct { allocs50b7b13 interface{} } -// FilGeneratePieceCommitmentResponse as declared in filecoin-ffi/filcrypto.h:439 +// FilGeneratePieceCommitmentResponse as declared in filecoin-ffi/filcrypto.h:441 type FilGeneratePieceCommitmentResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -486,7 +488,7 @@ type FilGeneratePieceCommitmentResponse struct { allocs4b00fda4 interface{} } -// FilGenerateDataCommitmentResponse as declared in filecoin-ffi/filcrypto.h:445 +// FilGenerateDataCommitmentResponse as declared in filecoin-ffi/filcrypto.h:447 type FilGenerateDataCommitmentResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -495,7 +497,7 @@ type FilGenerateDataCommitmentResponse struct { allocs87da7dd9 interface{} } -// FilClearCacheResponse as declared in filecoin-ffi/filcrypto.h:450 +// FilClearCacheResponse as declared in filecoin-ffi/filcrypto.h:452 type FilClearCacheResponse struct { ErrorMsg string StatusCode FCPResponseStatus @@ -503,7 +505,7 @@ type FilClearCacheResponse struct { allocsa9a80400 interface{} } -// FilStringResponse as declared in filecoin-ffi/filcrypto.h:459 +// FilStringResponse as declared in filecoin-ffi/filcrypto.h:461 type FilStringResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -512,7 +514,7 @@ type FilStringResponse struct { allocs4f413043 interface{} } -// FilFinalizeTicketResponse as declared in filecoin-ffi/filcrypto.h:465 +// FilFinalizeTicketResponse as declared in filecoin-ffi/filcrypto.h:467 type FilFinalizeTicketResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -521,7 +523,7 @@ type FilFinalizeTicketResponse struct { allocsb370fa86 interface{} } -// FilGpuDeviceResponse as declared in filecoin-ffi/filcrypto.h:472 +// FilGpuDeviceResponse as declared in filecoin-ffi/filcrypto.h:474 type FilGpuDeviceResponse struct { StatusCode FCPResponseStatus ErrorMsg string @@ -531,7 +533,7 @@ type FilGpuDeviceResponse struct { allocs58f92915 interface{} } -// FilInitLogFdResponse as declared in filecoin-ffi/filcrypto.h:477 +// FilInitLogFdResponse as declared in filecoin-ffi/filcrypto.h:479 type FilInitLogFdResponse struct { StatusCode FCPResponseStatus ErrorMsg string diff --git a/rust/src/fvm/machine.rs b/rust/src/fvm/machine.rs index 90936896..e187b01d 100644 --- a/rust/src/fvm/machine.rs +++ b/rust/src/fvm/machine.rs @@ -233,6 +233,13 @@ pub unsafe extern "C" fn fil_fvm_machine_execute_message( } } + if let Some(info) = apply_ret.failure_info { + let info_bytes = info.to_string().into_boxed_str().into_boxed_bytes(); + response.failure_info_ptr = info_bytes.as_ptr(); + response.failure_info_len = info_bytes.len(); + Box::leak(info_bytes); + } + // TODO: use the non-bigint token amount everywhere in the FVM let penalty: u128 = apply_ret.penalty.try_into().unwrap(); let miner_tip: u128 = apply_ret.miner_tip.try_into().unwrap(); diff --git a/rust/src/fvm/types.rs b/rust/src/fvm/types.rs index facefcac..91bfcb58 100644 --- a/rust/src/fvm/types.rs +++ b/rust/src/fvm/types.rs @@ -54,6 +54,8 @@ pub struct fil_FvmMachineExecuteResponse { pub miner_tip_lo: u64, pub exec_trace_ptr: *const u8, pub exec_trace_len: libc::size_t, + pub failure_info_ptr: *const u8, + pub failure_info_len: libc::size_t, } impl Default for fil_FvmMachineExecuteResponse { @@ -71,6 +73,8 @@ impl Default for fil_FvmMachineExecuteResponse { miner_tip_lo: 0, exec_trace_ptr: ptr::null(), exec_trace_len: 0, + failure_info_ptr: ptr::null(), + failure_info_len: 0, } } } From 1aaf422791bc0c6396ce4703587ed338b718f088 Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Wed, 20 Apr 2022 17:37:56 +0200 Subject: [PATCH 2/2] fix: propagate FailureInfo in ApplyImplicitMessage --- fvm.go | 1 + 1 file changed, 1 insertion(+) diff --git a/fvm.go b/fvm.go index 3d465d4c..f2bbeb05 100644 --- a/fvm.go +++ b/fvm.go @@ -151,6 +151,7 @@ func (f *FVM) ApplyImplicitMessage(msgBytes []byte) (*ApplyRet, error) { GasUsed: int64(resp.GasUsed), MinerPenalty: reformBigInt(resp.PenaltyHi, resp.PenaltyLo), MinerTip: reformBigInt(resp.MinerTipHi, resp.MinerTipLo), + FailureInfo: string(copyBytes(resp.FailureInfoPtr, resp.FailureInfoLen)), }, nil }