RustCrypto / asm-hashes

Assembly implementations of cryptographic hash functions
46 stars 26 forks source link

Windows Asm Hash is incorrect #78

Closed MaxKingPor closed 5 months ago

MaxKingPor commented 5 months ago

WindowsProductName WindowsVersion OsHardwareAbstractionLayer


Windows Server 2022 Datacenter 2009 10.0.20348.2031

* Dependencies
``` Toml
sha2 = { version = "0.10.8", features = ["asm"] }
newpavlov commented 5 months ago

Could you look into generated assembly? And check if the incorrect behavior is reproducible with other Rust versions? It's probably caused by some weird ABI issue...

We probably should simply raise compilation error when these crates get compiled on Windows, regardless whether it's MSVC or GNU toolchain.

MaxKingPor commented 5 months ago

Could you look into generated assembly? And check if the incorrect behavior is reproducible with other Rust versions? It's probably caused by some weird ABI issue...

We probably should simply raise compilation error when these crates get compiled on Windows, regardless whether it's MSVC or GNU toolchain.

image It's the same with toolchain 1.70-x86_64-pc-windows-gnu