Crypto3-Blueprint library to TVC compilation (contest)

in #contest3 years ago


Hello everyone, friends. As I wrote earlier, the recently launched Free TON Cryptography Governance subdivision immediately launched 2 contests with excellent prize money. Today I want to tell you about the Crypto3-Blueprint library to TVC compilation competition

Application Dates

October 1 - October 28, 2021

Description

As part of the integration of the Groth16 zkp schema into Free TON, it should be possible to generate proofs in DeBots. The proof generation itself can be added as a TVM instruction, but to generate the proof you must first generate an auxiliary (and sometimes public) input that satisfies the R1CS scheme

Since the generation of the auxiliary input differs significantly in different circuits, it cannot be added as an instruction, but must instead be done using in-TVM logic. Fortunately, there is a C ++ compiler to TVC (TVM bytecode)

In addition, since TVM operates slightly differently than a conventional processor, it may be more efficient to use the native types and functions of TVM. It is necessary not only to compile the libraries but also to optimize them to use the TVM features where necessary. Of course, a patch to a drawing library should not prevent the library from being compiled using a normal compiler to machine code

Task

It is necessary to write patches for crypto3-blueprint (https://github.com/NilFoundation/crypto3-blueprint) and its dependencies, as well as for the C ++ compiler so that it can be compiled and run a C ++ smart contract that uses this library. It is recommended to use the template repository as a basis

It should be able to use all the library features that can be used at the present time, the library contains several incomplete components

It should still be possible to compile the patched library with a regular C ++ native compiler and run it. Its performance should not degrade

Requirements

  • Improving the library performance in TVM will increase your score, you can use your own TVM types for this, for example using preprocessor definitions
  • In addition to uploading the material, you need to submit the code according to https://github.com/freeton-org/readme
  • The solution should include tests in the form of Free TON smart contracts that use various parts of the crypto3-blueprint library. These smart contracts must compile and run successfully
  • Besides uploading the view, the code should be posted according to GitHub - freeton-org / readme
  • The participant should make a presentation of his solution at a convenient time, agreed with the members of the cryptography group. The solution should include tests with clear instructions
  • The solution must be an open source license
  • The solution must contain at least a draft of the architecture description

Rewards

  • 1st prize 200,000 TONs
  • 2nd prize 100,000 TONs
  • 3rd prize 50,000 TONs

Only applications with an average score equal to or higher than 6.0 can be rewarded

Landing page - https://tvc.freeton.today/
Official news - https://forum.freeton.org/t/crypto3-blueprint-library-to-tvc-compilation-contest/11765
Developers Chat - https://t.me/FT_cryptography_SG

Coin Marketplace

STEEM 0.20
TRX 0.12
JST 0.030
BTC 60843.73
ETH 3406.11
USDT 1.00
SBD 2.57