#instructions #padding #account #data #solarti #wrap #transaction

solarti-instruction-padding

Solarti Program Library Instruction Padding Program

10 releases

new 0.1.9 Nov 7, 2024
0.1.8 Nov 6, 2024
0.1.5 Mar 29, 2024
0.1.4 Dec 24, 2023
0.1.0 Apr 28, 2023

#203 in Magic Beans

Download history 17/week @ 2024-09-27 1/week @ 2024-10-04 267/week @ 2024-11-01

267 downloads per month

Apache-2.0

11KB
185 lines

Instruction Pad Program

A program for padding instructions with additional data or accounts, to be used for testing larger transactions, either more instruction data, or more accounts.

The main use-case is with miraland-bench-tps, where we can see the impact of larger transactions through TPS numbers. With that data, we can develop a fair fee model for large transactions.

It operates with two instructions: no-op and wrap.

  • No-op: simply an instruction with as much data and as many accounts as desired, of which none will be used for processing.
  • Wrap: before the padding data and accounts, accepts a real instruction and required accounts, and performs a CPI into the program specified by the instruction

Both of these modes add the general overhead of calling a BPF program, and the wrap mode adds the CPI overhead.

Because of the overhead, it's best to use the instruction padding program with all large transaction tests, and comparing TPS numbers between:

  • using the program with no padding
  • using the program with data and account padding

Audit

The repository README contains information about program audits.

Dependencies

~17–25MB
~422K SLoC