Skip to content

Commit

Permalink
run benchmarks
Browse files Browse the repository at this point in the history
  • Loading branch information
lastmjs committed Oct 29, 2024
1 parent 2b4bbbc commit b3ef139
Show file tree
Hide file tree
Showing 281 changed files with 10,859 additions and 178 deletions.
15 changes: 15 additions & 0 deletions examples/hello_world/benchmarks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"hello_world": {
"previous": { "version": "0.25.0", "benchmarks": [] },
"current": {
"version": "0.25.0",
"benchmarks": [
{
"instructions": { "__bigint__": "1300399" },
"method_name": "setMessage",
"timestamp": { "__bigint__": "1730239570802280595" }
}
]
}
}
}
24 changes: 24 additions & 0 deletions examples/hello_world/benchmarks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Benchmarks for hello_world

## Current benchmarks Azle version: 0.25.0

| Id | Method Name | Instructions | Cycles | USD | USD/Million Calls |
| --- | ----------- | ------------ | --------- | ------------- | ----------------- |
| 0 | setMessage | 1_300_399 | 1_110_159 | $0.0000014761 | $1.47 |

## Baseline benchmarks Azle version: 0.25.0

No benchmarks reported

---

**Note on calculations:**

- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions) + (additional_fee_per_billion \* floor(number_of_instructions / 1_000_000_000))
- base_fee: 590_000 cycles
- per_instruction_fee: 0.4 cycles
- additional_fee_per_billion: 400_000_000 cycles per billion instructions
- USD value is derived from the total cycles, where 1 trillion cycles = 1 XDR, and 1 XDR = $1.329670 (as of October 24, 2024)

For the most up-to-date XDR to USD conversion rate, please refer to the [IMF website](https://www.imf.org/external/np/fin/data/rms_sdrv.aspx).
For the most current fee information, please check the [official documentation](https://internetcomputer.org/docs/current/developer-docs/gas-cost#execution).
Original file line number Diff line number Diff line change
Expand Up @@ -29,24 +29,24 @@
"version": "0.25.0",
"benchmarks": [
{
"instructions": { "__bigint__": "1403216" },
"instructions": { "__bigint__": "1403239" },
"method_name": "getRandomnessDirectly",
"timestamp": { "__bigint__": "1729803403463099043" }
"timestamp": { "__bigint__": "1730239608847785987" }
},
{
"instructions": { "__bigint__": "1331416" },
"method_name": "getRandomnessIndirectly",
"timestamp": { "__bigint__": "1729803405328542548" }
"timestamp": { "__bigint__": "1730239611013122232" }
},
{
"instructions": { "__bigint__": "1370777" },
"instructions": { "__bigint__": "1370696" },
"method_name": "getRandomnessSuperIndirectly",
"timestamp": { "__bigint__": "1729803407508425902" }
"timestamp": { "__bigint__": "1730239613202868641" }
},
{
"instructions": { "__bigint__": "1315499" },
"instructions": { "__bigint__": "1315488" },
"method_name": "returnPromiseVoid",
"timestamp": { "__bigint__": "1729803409436362598" }
"timestamp": { "__bigint__": "1730239615151180920" }
}
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@

| Id | Method Name | Instructions | Cycles | USD | USD/Million Calls | Change |
| --- | ---------------------------- | ------------ | --------- | ------------- | ----------------- | --------------------------------- |
| 0 | getRandomnessDirectly | 1_403_216 | 1_151_286 | $0.0000015308 | $1.53 | <font color="green">-6_032</font> |
| 0 | getRandomnessDirectly | 1_403_239 | 1_151_295 | $0.0000015308 | $1.53 | <font color="green">-6_009</font> |
| 1 | getRandomnessIndirectly | 1_331_416 | 1_122_566 | $0.0000014926 | $1.49 | <font color="red">+5_340</font> |
| 2 | getRandomnessSuperIndirectly | 1_370_777 | 1_138_310 | $0.0000015136 | $1.51 | <font color="red">+2_233</font> |
| 3 | returnPromiseVoid | 1_315_499 | 1_116_199 | $0.0000014842 | $1.48 | <font color="red">+2_383</font> |
| 2 | getRandomnessSuperIndirectly | 1_370_696 | 1_138_278 | $0.0000015135 | $1.51 | <font color="red">+2_152</font> |
| 3 | returnPromiseVoid | 1_315_488 | 1_116_195 | $0.0000014842 | $1.48 | <font color="red">+2_372</font> |

## Baseline benchmarks Azle version: 0.25.0

Expand Down
16 changes: 11 additions & 5 deletions tests/end_to_end/candid_rpc/class_syntax/blob_array/benchmarks.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,21 @@

## Current benchmarks Azle version: 0.25.0

No benchmarks reported

## Baseline benchmarks Azle version: 0.25.0

No benchmarks reported

---

**Note on calculations:**

- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions)
- Base fee: 590,000 cycles
- Per instruction fee: 0.4 cycles
- USD value is derived from the total cycles, where 1 trillion cycles = 1 XDR, and 1 XDR = $1.336610 (as of December 18, 2023)
- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions) + (additional_fee_per_billion \* floor(number_of_instructions / 1_000_000_000))
- base_fee: 590_000 cycles
- per_instruction_fee: 0.4 cycles
- additional_fee_per_billion: 400_000_000 cycles per billion instructions
- USD value is derived from the total cycles, where 1 trillion cycles = 1 XDR, and 1 XDR = $1.329670 (as of October 24, 2024)

For the most up-to-date fee information, please refer to the [official documentation](https://internetcomputer.org/docs/current/developer-docs/gas-cost#execution).
For the most up-to-date XDR to USD conversion rate, please refer to the [IMF website](https://www.imf.org/external/np/fin/data/rms_sdrv.aspx).
For the most current fee information, please check the [official documentation](https://internetcomputer.org/docs/current/developer-docs/gas-cost#execution).
35 changes: 35 additions & 0 deletions tests/end_to_end/candid_rpc/class_syntax/bytes/benchmarks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"bytes_canister": {
"previous": { "version": "0.25.0", "benchmarks": [] },
"current": {
"version": "0.25.0",
"benchmarks": [
{
"instructions": { "__bigint__": "1927510" },
"method_name": "getBytes",
"timestamp": { "__bigint__": "1730239597330523686" }
},
{
"instructions": { "__bigint__": "2551057" },
"method_name": "getBytes",
"timestamp": { "__bigint__": "1730239599444917323" }
},
{
"instructions": { "__bigint__": "9456404" },
"method_name": "getBytes",
"timestamp": { "__bigint__": "1730239601649831092" }
},
{
"instructions": { "__bigint__": "77855537" },
"method_name": "getBytes",
"timestamp": { "__bigint__": "1730239605414146220" }
},
{
"instructions": { "__bigint__": "153850484" },
"method_name": "getBytes",
"timestamp": { "__bigint__": "1730239613699007531" }
}
]
}
}
}
28 changes: 28 additions & 0 deletions tests/end_to_end/candid_rpc/class_syntax/bytes/benchmarks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Benchmarks for bytes_canister

## Current benchmarks Azle version: 0.25.0

| Id | Method Name | Instructions | Cycles | USD | USD/Million Calls |
| --- | ----------- | ------------ | ---------- | ------------- | ----------------- |
| 0 | getBytes | 1_927_510 | 1_361_004 | $0.0000018097 | $1.80 |
| 1 | getBytes | 2_551_057 | 1_610_422 | $0.0000021413 | $2.14 |
| 2 | getBytes | 9_456_404 | 4_372_561 | $0.0000058141 | $5.81 |
| 3 | getBytes | 77_855_537 | 31_732_214 | $0.0000421934 | $42.19 |
| 4 | getBytes | 153_850_484 | 62_130_193 | $0.0000826127 | $82.61 |

## Baseline benchmarks Azle version: 0.25.0

No benchmarks reported

---

**Note on calculations:**

- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions) + (additional_fee_per_billion \* floor(number_of_instructions / 1_000_000_000))
- base_fee: 590_000 cycles
- per_instruction_fee: 0.4 cycles
- additional_fee_per_billion: 400_000_000 cycles per billion instructions
- USD value is derived from the total cycles, where 1 trillion cycles = 1 XDR, and 1 XDR = $1.329670 (as of October 24, 2024)

For the most up-to-date XDR to USD conversion rate, please refer to the [IMF website](https://www.imf.org/external/np/fin/data/rms_sdrv.aspx).
For the most current fee information, please check the [official documentation](https://internetcomputer.org/docs/current/developer-docs/gas-cost#execution).

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions tests/end_to_end/candid_rpc/class_syntax/call_raw/benchmarks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"call_raw": {
"previous": { "version": "0.25.0", "benchmarks": [] },
"current": {
"version": "0.25.0",
"benchmarks": [
{
"instructions": { "__bigint__": "1485457" },
"method_name": "executeCallRaw",
"timestamp": { "__bigint__": "1730239874446305864" }
},
{
"instructions": { "__bigint__": "1891128" },
"method_name": "executeCallRaw",
"timestamp": { "__bigint__": "1730239876602478171" }
}
]
}
}
}
25 changes: 25 additions & 0 deletions tests/end_to_end/candid_rpc/class_syntax/call_raw/benchmarks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Benchmarks for call_raw

## Current benchmarks Azle version: 0.25.0

| Id | Method Name | Instructions | Cycles | USD | USD/Million Calls |
| --- | -------------- | ------------ | --------- | ------------- | ----------------- |
| 0 | executeCallRaw | 1_485_457 | 1_184_182 | $0.0000015746 | $1.57 |
| 1 | executeCallRaw | 1_891_128 | 1_346_451 | $0.0000017903 | $1.79 |

## Baseline benchmarks Azle version: 0.25.0

No benchmarks reported

---

**Note on calculations:**

- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions) + (additional_fee_per_billion \* floor(number_of_instructions / 1_000_000_000))
- base_fee: 590_000 cycles
- per_instruction_fee: 0.4 cycles
- additional_fee_per_billion: 400_000_000 cycles per billion instructions
- USD value is derived from the total cycles, where 1 trillion cycles = 1 XDR, and 1 XDR = $1.329670 (as of October 24, 2024)

For the most up-to-date XDR to USD conversion rate, please refer to the [IMF website](https://www.imf.org/external/np/fin/data/rms_sdrv.aspx).
For the most current fee information, please check the [official documentation](https://internetcomputer.org/docs/current/developer-docs/gas-cost#execution).
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"candid_encoding": {
"previous": { "version": "0.25.0", "benchmarks": [] },
"current": { "version": "0.25.0", "benchmarks": [] }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Benchmarks for candid_encoding

## Current benchmarks Azle version: 0.25.0

No benchmarks reported

## Baseline benchmarks Azle version: 0.25.0

No benchmarks reported

---

**Note on calculations:**

- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions) + (additional_fee_per_billion \* floor(number_of_instructions / 1_000_000_000))
- base_fee: 590_000 cycles
- per_instruction_fee: 0.4 cycles
- additional_fee_per_billion: 400_000_000 cycles per billion instructions
- USD value is derived from the total cycles, where 1 trillion cycles = 1 XDR, and 1 XDR = $1.329670 (as of October 24, 2024)

For the most up-to-date XDR to USD conversion rate, please refer to the [IMF website](https://www.imf.org/external/np/fin/data/rms_sdrv.aspx).
For the most current fee information, please check the [official documentation](https://internetcomputer.org/docs/current/developer-docs/gas-cost#execution).

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"candid_keywords": {
"previous": { "version": "0.25.0", "benchmarks": [] },
"current": { "version": "0.25.0", "benchmarks": [] }
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Benchmarks for candid_keywords

## Current benchmarks Azle version: 0.25.0

No benchmarks reported

## Baseline benchmarks Azle version: 0.25.0

No benchmarks reported

---

**Note on calculations:**

- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions) + (additional_fee_per_billion \* floor(number_of_instructions / 1_000_000_000))
- base_fee: 590_000 cycles
- per_instruction_fee: 0.4 cycles
- additional_fee_per_billion: 400_000_000 cycles per billion instructions
- USD value is derived from the total cycles, where 1 trillion cycles = 1 XDR, and 1 XDR = $1.329670 (as of October 24, 2024)

For the most up-to-date XDR to USD conversion rate, please refer to the [IMF website](https://www.imf.org/external/np/fin/data/rms_sdrv.aspx).
For the most current fee information, please check the [official documentation](https://internetcomputer.org/docs/current/developer-docs/gas-cost#execution).

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

25 changes: 25 additions & 0 deletions tests/end_to_end/candid_rpc/class_syntax/canister/benchmarks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"canister": {
"previous": { "version": "0.25.0", "benchmarks": [] },
"current": {
"version": "0.25.0",
"benchmarks": [
{
"instructions": { "__bigint__": "6222466" },
"method_name": "canisterNestedReturnType",
"timestamp": { "__bigint__": "1730239613007380364" }
},
{
"instructions": { "__bigint__": "6705068" },
"method_name": "canisterList",
"timestamp": { "__bigint__": "1730239615010287952" }
},
{
"instructions": { "__bigint__": "2525839" },
"method_name": "canisterCrossCanisterCall",
"timestamp": { "__bigint__": "1730239616976680152" }
}
]
}
}
}
26 changes: 26 additions & 0 deletions tests/end_to_end/candid_rpc/class_syntax/canister/benchmarks.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Benchmarks for canister

## Current benchmarks Azle version: 0.25.0

| Id | Method Name | Instructions | Cycles | USD | USD/Million Calls |
| --- | ------------------------- | ------------ | --------- | ------------- | ----------------- |
| 0 | canisterNestedReturnType | 6_222_466 | 3_078_986 | $0.0000040940 | $4.09 |
| 1 | canisterList | 6_705_068 | 3_272_027 | $0.0000043507 | $4.35 |
| 2 | canisterCrossCanisterCall | 2_525_839 | 1_600_335 | $0.0000021279 | $2.12 |

## Baseline benchmarks Azle version: 0.25.0

No benchmarks reported

---

**Note on calculations:**

- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions) + (additional_fee_per_billion \* floor(number_of_instructions / 1_000_000_000))
- base_fee: 590_000 cycles
- per_instruction_fee: 0.4 cycles
- additional_fee_per_billion: 400_000_000 cycles per billion instructions
- USD value is derived from the total cycles, where 1 trillion cycles = 1 XDR, and 1 XDR = $1.329670 (as of October 24, 2024)

For the most up-to-date XDR to USD conversion rate, please refer to the [IMF website](https://www.imf.org/external/np/fin/data/rms_sdrv.aspx).
For the most current fee information, please check the [official documentation](https://internetcomputer.org/docs/current/developer-docs/gas-cost#execution).

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit b3ef139

Please sign in to comment.