opshin icon indicating copy to clipboard operation
opshin copied to clipboard

Optimization: Function inlining

Open nielstron opened this issue 1 year ago • 1 comments

Is your feature request related to a problem? Please describe. Function calls can be expensive.

Describe the solution you'd like Short functions can be inlined by the opshin compiler.

Describe alternatives you've considered None

Additional context Should be toggleable through #168

Bug bounty: 1000 ADA

nielstron avatar Sep 12 '23 13:09 nielstron

This can/should also encompass

  • inlining of variables that are only written once (i.e. x = y; z = x --> z = y)
  • inlining of function calls to functions that are only written once

nielstron avatar Nov 01 '23 00:11 nielstron