Skip to content

Commit

Permalink
update files with new format
Browse files Browse the repository at this point in the history
  • Loading branch information
bdemann committed Oct 23, 2024
1 parent fb13dbb commit 74eddab
Show file tree
Hide file tree
Showing 6 changed files with 144 additions and 363 deletions.
44 changes: 11 additions & 33 deletions examples/hello_world_http_server/benchmarks.json
Original file line number Diff line number Diff line change
@@ -1,41 +1,19 @@
{
"backend": {
"previous": {
"version": "0.25.0",
"benchmarks": [
[
{ "__bigint__": "1729632054202977481" },
{
"instructions": { "__bigint__": "8134412120" },
"method_name": "2"
}
],
[
{ "__bigint__": "1729632070383750569" },
{
"instructions": { "__bigint__": "53820571" },
"method_name": "1"
}
]
]
},
"previous": { "version": "0.25.0", "benchmarks": [] },
"current": {
"version": "0.25.0",
"benchmarks": [
[
{ "__bigint__": "1729632150390909668" },
{
"instructions": { "__bigint__": "8134412120" },
"method_name": "2"
}
],
[
{ "__bigint__": "1729632166938651498" },
{
"instructions": { "__bigint__": "53820571" },
"method_name": "1"
}
]
{
"instructions": { "__bigint__": "8134540687" },
"method_name": "2",
"timestamp": { "__bigint__": "1729714575428306041" }
},
{
"instructions": { "__bigint__": "53839065" },
"method_name": "1",
"timestamp": { "__bigint__": "1729714593153022784" }
}
]
}
}
Expand Down
21 changes: 9 additions & 12 deletions examples/hello_world_http_server/benchmarks.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,22 @@

## Current benchmarks Azle version: 0.25.0

| Execution | Method Name | Instructions | Cycles | USD | USD/Thousand Calls | Change |
| --------- | ----------- | ------------- | ------------- | ------------- | ------------------ | -------------------------- |
| 0 | 2 | 8,134,412,120 | 3,254,354,848 | $0.0043498032 | $4.3498 | <font color="red">0</font> |
| 1 | 1 | 53,820,571 | 22,118,228 | $0.0000295634 | $0.0296 | <font color="red">0</font> |
| Id | Method Name | Instructions | Cycles | USD | USD/Million Calls |
| --- | ----------- | ------------- | ------------- | ------------- | ----------------- |
| 0 | 2 | 8_134_540_687 | 6_454_406_274 | $0.0086270240 | $8627.0240 |
| 1 | 1 | 53_839_065 | 22_125_626 | $0.0000295733 | $29.5733 |

## Baseline benchmarks Azle version: 0.25.0

| Execution | Method Name | Instructions | Cycles | USD | USD/Thousand Calls |
| --------- | ----------- | ------------- | ------------- | ------------- | ------------------ |
| 0 | 2 | 8,134,412,120 | 3,254,354,848 | $0.0043498032 | $4.3498 |
| 1 | 1 | 53,820,571 | 22,118,228 | $0.0000295634 | $0.0296 |

---

**Note on calculations:**

- Cycles are calculated using the formula: base_fee + (per_instruction_fee \* number_of_instructions)
- Cycles are calculated using the formula: base_fee + (per_instruction_fee _ number_of_instructions) + (additional_fee_per_billion _ floor(number_of_instructions / 1_billion))
- 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)
- Additional fee: 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.33661 (as of December 18, 2023)

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).
Loading

0 comments on commit 74eddab

Please sign in to comment.