Skip to content

In this project, we use Yul & Huff to write a basic solidity smart contract.

Notifications You must be signed in to change notification settings

napallday/huff-counter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Summary

In this project, we use Yul & Huff to write a basic solidity smart contract.

The implementations are covered by unit tests and fuzz tests.

Build

$ forge build

Test

$ forge test

Gas Snapshots

$ forge snapshot

Result:

[PASS] testFuzz_SetHuffValue(uint256) (runs: 1001, μ: 30728, ~: 30967)
[PASS] testFuzz_SetYulValue(uint256) (runs: 1001, μ: 31046, ~: 31285)
[PASS] testHuff_AddOne() (gas: 31090)
[PASS] testHuff_Overflow() (gas: 32059)
[PASS] testHuff_ReadValue() (gas: 10232)
[PASS] testSol_AddOne() (gas: 31469)
[PASS] testSol_Overflow() (gas: 32762)
[PASS] testSol_ReadValue() (gas: 10503)
[PASS] testSol_SetValue(uint256) (runs: 1001, μ: 31084, ~: 31323)
[PASS] testStatefulFuzz_AddCompare(uint256[]) (runs: 1001, μ: 1126914, ~: 1122116)
[PASS] testYul_AddOne() (gas: 31188)
[PASS] testYul_Overflow() (gas: 32368)
[PASS] testYul_ReadValue() (gas: 10387)

About

In this project, we use Yul & Huff to write a basic solidity smart contract.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published