Skip to content

Conversation

@Kixunil
Copy link
Collaborator

@Kixunil Kixunil commented Sep 20, 2021

This clearly states lack of support for 16-bit architectures as well as
adds readable compile_error!() call. It also fixes a few stylistic
mistakes - headings (top-level should not be repeated) and missing
newlines.

Closes #660

This clearly states lack of support for 16-bit architectures as well as
adds readable `compile_error!()` call. It also fixes a few stylistic
mistakes - headings (top-level should not be repeated) and missing
newlines.

Closes rust-bitcoin#660
ever be fixed, and there are no plans to do so. Of course, patches to
fix specific consensus incompatibilities are welcome.

### Support for 16-bit pointer sizes
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: The limitation is that there is no support.

Suggested change
### Support for 16-bit pointer sizes
### No support for 16-bit pointer sizes

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I went for consistency with previous chapter ("Consensus", not "No consensus").

Copy link
Member

@TheBlueMatt TheBlueMatt left a comment

Choose a reason for hiding this comment

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

Note that even if we did 16-bit pointer support we'd have a lot of limitations - eg we can never deserialize or serialize a block as they're regularly longer than 64KiB.

@Kixunil
Copy link
Collaborator Author

Kixunil commented Sep 21, 2021

We could with streaming deserialization which I was thinking of proposing but decided not to until I profile electrs and find allocations to be bottleneck. :)

@TheBlueMatt
Copy link
Member

We could with streaming deserialization

I don't think a host with 16-bit pointers will support deserializing a 4MiB object whether the source is a stream or not, given it only supports process memory of 64KiB :p

Copy link
Member

@sanket1729 sanket1729 left a comment

Choose a reason for hiding this comment

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

ACK 083f5f3

@sanket1729 sanket1729 merged commit 72dbe1d into rust-bitcoin:master Sep 21, 2021
@Kixunil Kixunil deleted the 16-bit-doc branch September 22, 2021 19:10
@Kixunil
Copy link
Collaborator Author

Kixunil commented Sep 22, 2021

@TheBlueMatt presumably it'd read data off some other storage medium using larger addressing integer just as it's possible to use more than 4GiB HDD on 32-bit platforms. :) Of course it couldn't hold whole thing in memory but some applications don't have to.

@dr-orlovsky dr-orlovsky added this to the 0.28.0 milestone Sep 25, 2021
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.

Architecture support documentation (pointer sizes < 64)

5 participants