Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't allocate when forwarding stdout #119

Merged
merged 1 commit into from
Jun 14, 2021
Merged

Conversation

mkroening
Copy link
Member

This avoids heap allocations and allows writing non-UTF-8-data to stdout.

@mkroening mkroening requested a review from stlankes June 13, 2021 17:22
@mkroening mkroening self-assigned this Jun 13, 2021
@codecov
Copy link

codecov bot commented Jun 13, 2021

Codecov Report

Merging #119 (b20a7fb) into master (11f00e6) will increase coverage by 0.02%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #119      +/-   ##
==========================================
+ Coverage   19.80%   19.82%   +0.02%     
==========================================
  Files          21       21              
  Lines        5196     5190       -6     
==========================================
  Hits         1029     1029              
+ Misses       4167     4161       -6     
Impacted Files Coverage Δ
src/linux/vcpu.rs 0.00% <ø> (ø)
src/macos/vcpu.rs 0.00% <0.00%> (ø)
src/vm.rs 14.40% <0.00%> (+0.07%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 11f00e6...b20a7fb. Read the comment docs.

Copy link
Collaborator

@stlankes stlankes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

bors r+

bors bot added a commit that referenced this pull request Jun 14, 2021
119: Don't allocate when forwarding stdout r=stlankes a=mkroening

This avoids heap allocations and allows writing non-UTF-8-data to stdout.

120: Bump env_logger from 0.8.3 to 0.8.4 r=stlankes a=dependabot[bot]

Bumps [env_logger](https://github.com/env-logger-rs/env_logger) from 0.8.3 to 0.8.4.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/env-logger-rs/env_logger/releases">env_logger's releases</a>.</em></p>
<blockquote>
<h2>0.8.4</h2>
<p>Improvements:</p>
<ul>
<li>Allow writing logs to a custom output target (via <code>Target::Pipe</code>)</li>
</ul>
<p>Bug fixes:</p>
<ul>
<li>Actually allow overriding filter levels using <code>env_logger::Builder</code>s methods, as documented</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="https://github.com/env-logger-rs/env_logger/commit/13cafce572362582f57964eae6cb4a41f52fd04a"><code>13cafce</code></a> Bump version to 0.8.4</li>
<li><a href="https://github.com/env-logger-rs/env_logger/commit/090081156127dcd896b8b00837549cb4008c43d0"><code>0900811</code></a> Ensure unique directive names when building filters</li>
<li><a href="https://github.com/env-logger-rs/env_logger/commit/1a8379a533f043e623d5eb4a898d171927ad61c1"><code>1a8379a</code></a> Allow writing logs to a custom output target (Target::Pipe)</li>
<li><a href="https://github.com/env-logger-rs/env_logger/commit/2151771ffd1e4c8e20ed6070ab49528d85ebcde1"><code>2151771</code></a> Upgrade to GitHub-native Dependabot</li>
<li><a href="https://github.com/env-logger-rs/env_logger/commit/16d982ed979bb9361048fc25a5589ac5e06daf17"><code>16d982e</code></a> Fix lints</li>
<li>See full diff in <a href="https://github.com/env-logger-rs/env_logger/compare/v0.8.3...v0.8.4">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=env_logger&package-manager=cargo&previous-version=0.8.3&new-version=0.8.4)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

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>

Co-authored-by: Martin Kröning <mkroening@posteo.net>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@bors
Copy link
Contributor

bors bot commented Jun 14, 2021

Build failed (retrying...):

bors bot added a commit that referenced this pull request Jun 14, 2021
119: Don't allocate when forwarding stdout r=stlankes a=mkroening

This avoids heap allocations and allows writing non-UTF-8-data to stdout.

Co-authored-by: Martin Kröning <mkroening@posteo.net>
@bors
Copy link
Contributor

bors bot commented Jun 14, 2021

Build failed:

@stlankes
Copy link
Collaborator

bors retry

@bors bors bot merged commit 1656e55 into hermit-os:master Jun 14, 2021
@mkroening mkroening deleted the uart-string branch July 14, 2021 10:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants