snarkVM icon indicating copy to clipboard operation
snarkVM copied to clipboard

Fix compilation without 'parallel' feature

Open zvolin opened this issue 2 years ago • 0 comments

Motivation

Hi! was playing with some part of snarkVM's compiler a bit and due to the environment I'm running it on I wanted to make sure it compiles with the least possible amount of dependencies and that it runs single-threaded. I've discovered that even if you turn feature parallel off, it still gets included with default features of snarkvm-compiler and after turning this off, the code stops compiling because snarkvm-compiler uses rayon in some places unconditionally.

This PR includes fixes to the both of those.

cargo tree --no-default-features --features cli
...
├── snarkvm-compiler v0.9.0
│   ├── rayon v1.5.3 (*)

TLDR

The goal is to make cargo build --lib --no-default-features --features cli passing without it using rayon. Currently it builds on master but still includes rayon through snarkvm-compiler

zvolin avatar Oct 12 '22 10:10 zvolin