Skip to content

Feat: How to use profiler to optimize gas usage #261

Open
@julio4

Description

@julio4

Description

In this example, we will use cairo-profiler to learn how to analyze execution traces to help developers optimize L2 ressource usage and debug their contracts.

It should use a simple but unoptimized contract example (e.g., array manipulation or mapping iteration) to demonstrate how to:

  • Run cairo-profiler
  • Read and interpret its output (mainly with graph and flame graph views from pprof)
  • Identify step-heavy operations
  • Apply optimizations there
  • Compare before/after metrics

ODHack

To be eligible for additional rewards, be sure to review and follow the ODHack Common Guidelines and Contributing Guidelines.
Be sure to join the telegram group and introduce yourself.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions