3

I am trying to figure out what part of a complicated smart contract transaction is responsible for the cost. I was wondering if there is already a tool for that. Ideally it would spit out you are spending this much gas on this kind of opcode or storage op etc. It would be great for writing optimized computation "heavy" smart contracts.

0

On Remix, you can view gas estimates by clicking on your contract on the right side, followed by clicking "Details".

From there, you will get many details about your contract, including the gas estimate for each function.

0

there is another option I'm trying out right now sol-profiler buy the guys at 0x project

Sol-profiler gathers line-by-line gas usage for any transaction submitted through your provider. This will help you find unexpected inefficiencies in parts of your smart contract, and take a data-driven approach to optimizing it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.