# Replace hand-written endian-specific loads with std.mem.readInt\*\(\) \(\#16431\) · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/a0b35249a29c6869650ba7e3515999fcced8dcf2)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: a0b35249a29c6869650ba7e3515999fcced8dcf2

Requested commit: a0b35249a29c6869650ba7e3515999fcced8dcf2

Commit: a0b35249a29c6869650ba7e3515999fcced8dcf2

Tree: 42b82769f330b2840d23363b57033677e5dc36ea

Author: Frank Denis

Committer: GitHub

## Message

```
Replace hand-written endian-specific loads with std.mem.readInt*() (#16431)

And when we have the choice, favor little-endian because it's 2023.

Gives a slight performance improvement:

   md5: 552 -> 555 MiB/s
  sha1: 768 -> 786 MiB/s
sha512: 211 -> 217 MiB/s
```

## Parents

- [a86f589a9f03622aa13eab4895c505c7f131c075](https://git.cafe/gitcafe/zig/commit/a86f589a9f03622aa13eab4895c505c7f131c075?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/a0b35249a29c6869650ba7e3515999fcced8dcf2?format=markdown)
