Skip to content

Instantly share code, notes, and snippets.

View jamwt's full-sized avatar

Jamie Turner jamwt

View GitHub Profile
#![feature(test)]
extern crate rayon;
extern crate test;
#[cfg(test)]
mod tests {
use test::Bencher;
use rayon::prelude::*;
#[bench]
BUGCHECK_STR: STATUS_ILLEGAL_INSTRUCTION
DEFAULT_BUCKET_ID: STATUS_ILLEGAL_INSTRUCTION
LAST_CONTROL_TRANSFER: from 730e1068 to 73127b68
STACK_TEXT:
0014f084 730e1068 0000004c 0014f0c4 774138e7 dropbox_watchdog!std::sys::imp::ext::ffi::{{impl}}::from_wide+0xf8
0014f9bc 002c10ae 00000000 00162307 00000006 dropbox_watchdog!spawn_monitoring_process+0x68
WARNING: Stack unwind information not available. Following frames may be wrong.
diff --git a/rust/Cargo.toml b/rust/Cargo.toml
index b24d5cf..c715446 100644
--- a/rust/Cargo.toml
+++ b/rust/Cargo.toml
@@ -6,4 +6,6 @@ authors = [ "David Shoemaker <mrshoe@gmail.com>" ]
[dependencies]
image = "*"
+itertools = "*"
+rayon = "*"
Before
0.80user 0.00system 0:00.81elapsed 99%CPU
After
1.62user 0.02system 0:00.26elapsed 624%CPU
[root]
name = "test_repo"
version = "0.1.0"
dependencies = [
"slog 1.0.0-alpha3 (registry+https://github.com/rust-lang/crates.io-index)",
"slog-atomic 0.2.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "crossbeam"
jamwt@dash:~/contrib/repro/test_repo$ cargo build
Unpacking slog v1.0.0-alpha3 (registry file:///home/jamwt/contrib/repro/test_repo/../registry)
Compiling slog v1.0.0-alpha3
Compiling test_repo v0.1.0 (file:///home/jamwt/contrib/repro/test_repo)
Finished debug [unoptimized + debuginfo] target(s) in 2.28 secs
jamwt@dash:~/contrib/repro/test_repo$ vi Cargo.toml
jamwt@dash:~/contrib/repro/test_repo$ cargo build
error: no matching package named `slog` found (required by `slog-atomic`)
location searched: registry https://github.com/rust-lang/crates.io-index
version required: *
jamwt@dash:~/devel/client/rust/registry$ cat index/sl/og/slog | json_pp
{
"features" : {
"release_max_level_off" : [],
"max_level_trace" : [],
"release_max_level_trace" : [],
"max_level_warn" : [],
"max_level_debug" : [],
"release_max_level_warn" : [],
"max_level_off" : [],
jamwt@dash:~/devel/client/rust/registry$ tar -xf slog-atomic-0.2.0.crate -O slog-atomic-0.2.0/Cargo.toml
[package]
name = "slog-atomic"
version = "0.2.0"
authors = ["Dawid Ciężarkiewicz <dpc@dpc.pw>"]
description = "Unix terminal drain and formatter for slog-rs"
keywords = ["slog", "logging", "log", "atomic"]
license = "MPL-2.0"
documentation = "https://dpc.github.io/slog-rs/"
homepage = "https://github.com/dpc/slog-rs"
DEBUG:cargo: handle_error; err=CliError { error: Some(no matching package named `slog` found (required by `slog-term`)
location searched: registry https://github.com/rust-lang/crates.io-index
version required: *), unknown: false, exit_code: 101 }
error: no matching package named `slog` found (required by `slog-term`)
location searched: registry https://github.com/rust-lang/crates.io-index
version required: *
jamwt@dash:~/devel/client/rust/nucleus/com
TRACE:cargo::core::resolver: common[5]>slog 1 candidates
TRACE:cargo::core::resolver: common[5]>slog 0 prev activations
TRACE:cargo::core::resolver: common[5]>slog trying 1.0.0-alpha3
TRACE:cargo::core::resolver: activating slog v1.0.0-alpha3
TRACE:cargo::core::resolver: futures[0]>log 1 candidates
TRACE:cargo::core::resolver: futures[0]>log 0 prev activations
TRACE:cargo::core::resolver: futures[0]>log trying 0.3.6
TRACE:cargo::core::resolver: activating log v0.3.6
TRACE:cargo::core::resolver: common[6]>base64 1 candidates
TRACE:cargo::core::resolver: common[6]>base64 0 prev activations