dependabot[bot] 6039337457 Update wasmi requirement from 0.28 to 0.29 (#58)
Updates the requirements on [wasmi](https://github.com/paritytech/wasmi)
to permit the latest version.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/paritytech/wasmi/releases">wasmi's
releases</a>.</em></p>
<blockquote>
<h2>v0.29.0 - 2023-03-20</h2>
<h3>Added</h3>
<ul>
<li>Added support for <code>extended-const</code> Wasm proposal. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/707">paritytech/wasmi#707</a>)</li>
<li>Added fuel consumption modes. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/706">paritytech/wasmi#706</a>)
<ul>
<li>This allows eager and lazy fuel consumption modes to be used which
mainly affects bulk operations such as <code>table.copy</code> and
<code>memory.grow</code>.
Eager fuel consumption always consumes fuel before a bulk operation for
the
total amount independent of success or failure of the operation whereras
lazy fuel consumption only consumes fuel for successful executions.</li>
</ul>
</li>
</ul>
<h3>Changed</h3>
<ul>
<li>Normalize fuel costs of all instructions. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/705">paritytech/wasmi#705</a>)
<ul>
<li>With this change most instructions cost roughly 1 fuel upon
execution.
This is more similar to how Wasmtime deals with fuel metered instruction
costs.
Before this change <code>wasmi</code> tried to have fuel costs that more
closely mirror
the computation intensity of the respective instruction according to
benchmarks.</li>
</ul>
</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/paritytech/wasmi/blob/master/CHANGELOG.md">wasmi's
changelog</a>.</em></p>
<blockquote>
<h2>[<code>0.29.0</code>] - 2023-03-20</h2>
<h3>Added</h3>
<ul>
<li>Added support for <code>extended-const</code> Wasm proposal. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/707">paritytech/wasmi#707</a>)</li>
<li>Added fuel consumption modes. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/706">paritytech/wasmi#706</a>)
<ul>
<li>This allows eager and lazy fuel consumption modes to be used which
mainly affects bulk operations such as <code>table.copy</code> and
<code>memory.grow</code>.
Eager fuel consumption always consumes fuel before a bulk operation for
the
total amount independent of success or failure of the operation whereras
lazy fuel consumption only consumes fuel for successful executions.</li>
</ul>
</li>
</ul>
<h3>Changed</h3>
<ul>
<li>Normalize fuel costs of all instructions. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/705">paritytech/wasmi#705</a>)
<ul>
<li>With this change most instructions cost roughly 1 fuel upon
execution.
This is more similar to how Wasmtime deals with fuel metered instruction
costs.
Before this change <code>wasmi</code> tried to have fuel costs that more
closely mirror
the computation intensity of the respective instruction according to
benchmarks.</li>
</ul>
</li>
</ul>
<h2>[<code>0.28.0</code>] - 2023-03-01</h2>
<h3>Added</h3>
<ul>
<li>Added support for the <code>tail-call</code> Wasm proposal. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/683">paritytech/wasmi#683</a>)</li>
<li>Added support for <code>Linker</code> defined host functions. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/692">paritytech/wasmi#692</a>)
<ul>
<li>Apparently this PR introduced some performance wins for the Wasm
target according to our tests.
This information shall be taken with a grain of salt since we are not
sure why those performance
improvement occured since the PR's functionality is orthogonal to Wasm
engine performance.</li>
<li>Required precursor refactoring PR: <a
href="https://redirect.github.com/paritytech/wasmi/pull/681">paritytech/wasmi#681</a></li>
</ul>
</li>
</ul>
<h3>Changed</h3>
<ul>
<li>The <code>wasmi_wasi</code> crate now more closely mirrors the
<code>wasmtime_wasi</code> crate API. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/700">paritytech/wasmi#700</a>)</li>
</ul>
<h3>Internal</h3>
<ul>
<li>Refactor the <code>wasmi</code> Wasm engine to handle Wasm calls and
returns in its core. [(<a
href="https://redirect.github.com/paritytech/wasmi/issues/694">#694</a>)]
<ul>
<li>This improved performance of Wasm function calls significantly at
the cost of host function call performance.</li>
<li>Also this seemed to have impacts Wasm target performance quite
positively, too.</li>
</ul>
</li>
<li>The <code>Store</code> now handles Wasm functions and host functions
separately. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/686">paritytech/wasmi#686</a>)
<ul>
<li>This allows to store Wasm functions into the <code>StoreInner</code>
type which was an important
step towards the major refactoring in [(<a
href="https://redirect.github.com/paritytech/wasmi/issues/694">#694</a>)]</li>
<li>It was expected that host function call performance would degrade by
this PR but our tests
actually showed that the opposite was true and Wasm target performance
was improved overall.</li>
</ul>
</li>
<li>Introduce <code>ValueStackPtr</code> abstraction for the
<code>wasmi</code> engine core. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/688">paritytech/wasmi#688</a>)
<ul>
<li>This change significantly improved performance especially on the
Wasm target according to our tests.</li>
</ul>
</li>
<li>Optimize <code>memory.{load,store}</code> when reading or writing
single bytes. (<a
href="https://redirect.github.com/paritytech/wasmi/pull/689">paritytech/wasmi#689</a>)</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/paritytech/wasmi/commit/23d8d8c684255f2d63526baa348ab3eb3d249de0"><code>23d8d8c</code></a>
Prepare <code>wasmi</code> release of version <code>0.29.0</code> (<a
href="https://redirect.github.com/paritytech/wasmi/issues/708">#708</a>)</li>
<li><a
href="https://github.com/paritytech/wasmi/commit/eb8d73fd3b2a7f9134bc46d391b6a6963439dbd6"><code>eb8d73f</code></a>
Add <code>extended-const</code> Wasm proposal support (<a
href="https://redirect.github.com/paritytech/wasmi/issues/707">#707</a>)</li>
<li><a
href="https://github.com/paritytech/wasmi/commit/6dbbada8099511e538fb2a26e583012df0c90b5c"><code>6dbbada</code></a>
Add fuel consumption modes (<a
href="https://redirect.github.com/paritytech/wasmi/issues/706">#706</a>)</li>
<li><a
href="https://github.com/paritytech/wasmi/commit/cf7736f57abb7dec469d5485f4a80fcf3aa2a392"><code>cf7736f</code></a>
Normalize fuel costs to roughly 1 fuel per executed instruction (<a
href="https://redirect.github.com/paritytech/wasmi/issues/705">#705</a>)</li>
<li><a
href="https://github.com/paritytech/wasmi/commit/223f815d087fb918493b243182ae24bb960d8336"><code>223f815</code></a>
Update and refactor the <code>wasmi_wasi</code> crate (<a
href="https://redirect.github.com/paritytech/wasmi/issues/700">#700</a>)</li>
<li>See full diff in <a
href="https://github.com/paritytech/wasmi/compare/v0.28.0...v0.29.0">compare
view</a></li>
</ul>
</details>
<br />


Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-21 00:11:34 +01:00
2023-01-10 16:01:52 -03:00
2021-07-28 16:29:33 +02:00
2017-11-03 02:11:41 +03:00
2022-01-11 21:46:18 +02:00

wasm-instrument

A Rust library containing a collection of wasm module instrumentations and transformations mainly useful for wasm based block chains and smart contracts.

Provided functionality

This is a non exhaustive list of provided functionality. Please check out the documentation for details.

Gas Metering

Add gas metering to your platform by injecting the necessary code directly into the wasm module. This allows having a uniform gas metering implementation across different execution engines (interpreters, JIT compilers).

Stack Height Limiter

Neither the wasm standard nor any sufficiently complex execution engine specifies how many items on the wasm stack are supported before the execution aborts or malfunctions. Even the same execution engine on different operating systems or host architectures could support a different number of stack items and be well within its rights.

This is the kind of indeterminism that can lead to consensus failures when used in a blockchain context.

To address this issue we can inject some code that meters the stack height at runtime and aborts the execution when it reaches a predefined limit. Choosing this limit suffciently small so that it is smaller than what any reasonably parameterized execution engine would support solves the issue: All execution engines would reach the injected limit before hitting any implementation specific limitation.

License

wasm-instrument is distributed under the terms of both the MIT license and the Apache License (Version 2.0), at your choice.

See LICENSE-APACHE, and LICENSE-MIT for details.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in wasm-instrument by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

S
Description
No description provided
Readme 1.1 MiB
Languages
Rust 85.7%
WebAssembly 13.9%
Just 0.4%