-
Notifications
You must be signed in to change notification settings - Fork 235
Remove heapsize #94
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
Remove heapsize #94
Changes from all commits
25270be
94bb293
197a27d
f816aaf
2a0cc08
418e03b
6105606
59b4d55
efadc31
b2f1708
fb127a7
d5aa899
fd9dc92
3df427b
da88f97
ef9a5b6
1b0b2e3
8839576
5fd398f
5340912
8ada814
e3516d2
61c60b0
767dc90
9876b65
a8a9b0e
a31851e
73e8c7e
64135ac
af24ca4
00a0931
d85752e
32beba3
ac83cdd
bce898c
821c02c
85597c0
d770316
a0a2577
ca27409
c6a6982
b7de962
a65dcdb
45860cd
ba4dd7c
96c860b
1b0bc65
0fbc1ce
18d3f99
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "ethbloom" | ||
version = "0.6.4" | ||
version = "0.7.0" | ||
authors = ["Parity Technologies <[email protected]>"] | ||
description = "Ethereum bloom filter" | ||
license = "MIT" | ||
|
@@ -11,7 +11,7 @@ repository = "https://github.com/paritytech/parity-common" | |
[dependencies] | ||
tiny-keccak = "1.4" | ||
crunchy = { version = "0.2", default-features = false, features = ["limit_256"] } | ||
fixed-hash = { path = "../fixed-hash", version = "0.3", default-features = false } | ||
fixed-hash = { path = "../fixed-hash", version = "0.4", default-features = false } | ||
impl-serde = { path = "../primitive-types/impls/serde", version = "0.2", default-features = false, optional = true } | ||
impl-rlp = { path = "../primitive-types/impls/rlp", version = "0.2", default-features = false } | ||
|
||
|
@@ -20,7 +20,6 @@ rand = { version = "0.4" } | |
hex-literal = "0.1.1" | ||
|
||
[features] | ||
default = ["std", "heapsize", "serialize", "fixed-hash/libc", "fixed-hash/rustc-hex"] | ||
default = ["std", "serialize", "fixed-hash/libc", "fixed-hash/rustc-hex"] | ||
std = ["fixed-hash/std", "crunchy/std"] | ||
heapsize = ["fixed-hash/heapsize"] | ||
serialize = ["std", "impl-serde"] |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,24 +1,23 @@ | ||
[package] | ||
name = "ethereum-types" | ||
version = "0.6.0" | ||
version = "0.7.0" | ||
authors = ["Parity Technologies <[email protected]>"] | ||
license = "MIT" | ||
homepage = "https://github.com/paritytech/parity-common" | ||
description = "Ethereum types" | ||
|
||
[dependencies] | ||
ethbloom = { path = "../ethbloom", version = "0.6", default-features = false } | ||
fixed-hash = { path = "../fixed-hash", version = "0.3", default-features = false, features = ["byteorder", "rustc-hex"] } | ||
uint = { path = "../uint", version = "0.7", default-features = false } | ||
primitive-types = { path = "../primitive-types", version = "0.3", features = ["rlp", "byteorder", "rustc-hex"], default-features = false } | ||
ethbloom = { path = "../ethbloom", version = "0.7", default-features = false } | ||
fixed-hash = { path = "../fixed-hash", version = "0.4", default-features = false, features = ["byteorder", "rustc-hex"] } | ||
uint = { path = "../uint", version = "0.8", default-features = false } | ||
primitive-types = { path = "../primitive-types", version = "0.4", features = ["rlp", "byteorder", "rustc-hex"], default-features = false } | ||
impl-serde = { path = "../primitive-types/impls/serde", version = "0.2", default-features = false, optional = true } | ||
impl-rlp = { path = "../primitive-types/impls/rlp", version = "0.2", default-features = false } | ||
|
||
[dev-dependencies] | ||
serde_json = "1.0" | ||
|
||
[features] | ||
default = ["std", "heapsize", "serialize"] | ||
default = ["std", "serialize"] | ||
std = ["uint/std", "fixed-hash/std", "ethbloom/std", "primitive-types/std"] | ||
heapsize = ["uint/heapsize", "primitive-types/heapsize", "fixed-hash/heapsize", "ethbloom/heapsize"] | ||
serialize = ["std", "impl-serde", "primitive-types/serde", "ethbloom/serialize"] |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "fixed-hash" | ||
version = "0.3.2" | ||
version = "0.4.0" | ||
authors = ["Parity Technologies <[email protected]>"] | ||
license = "MIT" | ||
homepage = "https://github.com/paritytech/parity-common" | ||
|
@@ -10,10 +10,9 @@ documentation = "https://docs.rs/fixed-hash/" | |
readme = "README.md" | ||
|
||
[package.metadata.docs.rs] | ||
features = ["heapsize", "quickcheck", "api-dummy"] | ||
features = ["quickcheck", "api-dummy"] | ||
|
||
[dependencies] | ||
heapsize = { version = "0.4", optional = true } | ||
rand = { version = "0.5", optional = true, default-features = false } | ||
rustc-hex = { version = "2.0", optional = true, default-features = false } | ||
quickcheck = { version = "0.7", optional = true } | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "keccak-hash" | ||
version = "0.2.0" | ||
version = "0.3.0" | ||
description = "`keccak-hash` is a set of utility functions to facilitate working with Keccak hashes (256/512 bits long)." | ||
authors = ["Parity Technologies <[email protected]>"] | ||
repository = "https://github.com/paritytech/parity-common" | ||
|
@@ -9,7 +9,7 @@ license = "GPL-3.0" | |
|
||
[dependencies] | ||
tiny-keccak = "1.4" | ||
primitive-types = { path = "../primitive-types", version = "0.3" } | ||
primitive-types = { path = "../primitive-types", version = "0.4" } | ||
|
||
[dev-dependencies] | ||
tempdir = "0.3" |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,9 +13,9 @@ malloc_size_of_derive = "0.1.0" | |
dlmalloc = { version = "0.1", features = ["global"], optional = true } | ||
wee_alloc = { version = "0.4", optional = true } | ||
|
||
elastic-array = { version = "*", optional = true } | ||
ethereum-types = { version = "*", optional = true } | ||
parking_lot = { version = "*", optional = true } | ||
elastic-array = { version = "0", optional = true } | ||
ethereum-types = { version = "0", optional = true } | ||
parking_lot = { version = "0", optional = true } | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This should work fine, says |
||
|
||
[target.'cfg(target_os = "windows")'.dependencies.winapi] | ||
version = "0.3.4" | ||
|
@@ -27,8 +27,6 @@ optional = true | |
[features] | ||
default = ["std", "ethereum-impls"] | ||
std = [] | ||
# when activated mem is removed through volatile primitive instead of clear_on_drop crate | ||
dvdplm marked this conversation as resolved.
Show resolved
Hide resolved
|
||
volatile-erase = [] | ||
# use dlmalloc as global allocator | ||
dlmalloc-global = ["dlmalloc", "estimate-heapsize"] | ||
# use wee_alloc as global allocator | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,13 +4,14 @@ Collection of memory related utilities. | |
|
||
## Features | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you add a recommended way of using this crate to, for example, replace code that uses |
||
|
||
- volatile-erase : Not set by default, `Memzero` struct will be erasing memory through a simple [`write_volatile`](https://doc.rust-lang.org/std/ptr/fn.write_volatile.html) call. | ||
- estimate-heapsize : Do not use allocator, but `size_of` or `size_of_val`. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. (commenting here because GH doesn't allow me to comment below) Need to update the |
||
|
||
Others features define global allocator, see `src/alloc.rs`. | ||
|
||
## Dependency | ||
|
||
This crate groups common dependency, [`clear_on_drop`](https://crates.io/crates/clear_on_drop) is reexported, and a patched copy of unpublished [`malloc_size_of`](https://github.com/servo/servo/tree/master/components/malloc_size_of) from servo project is copied and partially reexported. | ||
This crate groups common dependency, a patched copy of unpublished [`malloc_size_of`](https://github.com/servo/servo/tree/master/components/malloc_size_of) from servo project is copied and partially reexported. | ||
|
||
`Malloc_size_of` code is used internally as a module with a few modification to be able to implement type locally. | ||
|
||
For existing code using deprecated `HeapsizeOf` crate, calls to `heapsize_of_children` should be replace by calls to `size_of`. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,22 +1,21 @@ | ||
[package] | ||
name = "primitive-types" | ||
version = "0.3.0" | ||
version = "0.4.0" | ||
authors = ["Parity Technologies <[email protected]>"] | ||
license = "Apache-2.0/MIT" | ||
homepage = "https://github.com/paritytech/parity-common" | ||
description = "Primitive types shared by Ethereum and Substrate" | ||
|
||
[dependencies] | ||
fixed-hash = { version = "0.3", path = "../fixed-hash", default-features = false } | ||
uint = { version = "0.7", path = "../uint", default-features = false } | ||
fixed-hash = { version = "0.4", path = "../fixed-hash", default-features = false } | ||
uint = { version = "0.8", path = "../uint", default-features = false } | ||
impl-serde = { version = "0.2", path = "impls/serde", default-features = false, optional = true } | ||
impl-codec = { version = "0.2", path = "impls/codec", default-features = false, optional = true } | ||
impl-rlp = { version = "0.2", path = "impls/rlp", default-features = false, optional = true } | ||
|
||
[features] | ||
default = ["std"] | ||
std = ["uint/std", "fixed-hash/std", "impl-codec/std"] | ||
heapsize = ["uint/heapsize", "fixed-hash/heapsize"] | ||
byteorder = ["fixed-hash/byteorder"] | ||
libc = ["fixed-hash/libc"] | ||
rustc-hex = ["fixed-hash/rustc-hex"] | ||
|
Uh oh!
There was an error while loading. Please reload this page.