rust/library/stdarch
Ruud van Asseldonk ee249f766c Add x86 AES-NI vendor intrinsics (#311)
* Define _mm_aes*_si128 intrinsics

* Add tests for _mm_aes*_si128 intrinsics

These tests are based on the examples in Microsoft's documentation.
Same input should result in the same output in any case.

* Constify imm8 argument of aeskeygenassist

* Do not rely on internal layout of __m128

Use _mm_set_epi64x instead to construct constants.

* Move AES vendor intrinsics from x86_64 to i686

Although i686 does not have the AES New Instructions, making code
compatible across x86 and x64_64 tends to be easier if the intrinsics
are available everywhere.

* Pass constant for assert_instr(aeskeygenassist)

Pass a particular value for the disassembly test, so we end up with one
instruction, instead of the match arm that matches on all 256 values.

* Make aeskeygenassist imm8 argument i32, not u8

Intel documentation specifies it as an "8-bit round constant", but then
goes on to give it a type "const int", which translates to i32 in Rust.
The test that verifies the Rust signatures against Intel documentation
failed on this.

For now we will replicate the C API verbatim. Even when Rust could have
a more accurate type signature that makes passing values more than 8
bits impossible, rather than silently mapping out-of-range values to
255.

* Reflow doc comment as proposed by rustfmt

* Add module doc comment for i686::aes
2018-02-05 11:07:40 -06:00
..
ci Update doc generation with recent devlopments 2018-01-28 22:00:13 -08:00
coresimd Add x86 AES-NI vendor intrinsics (#311) 2018-02-05 11:07:40 -06:00
examples Run-time feature detection for AES-NI and TSC (#312) 2018-02-02 09:08:27 -06:00
src Run-time feature detection for AES-NI and TSC (#312) 2018-02-02 09:08:27 -06:00
stdsimd-test Run-time feature detection for AES-NI and TSC (#312) 2018-02-02 09:08:27 -06:00
stdsimd-verify Remove known exceptions to Intel's signatures (#317) 2018-02-05 10:04:46 -06:00
tests Run-time feature detection for AES-NI and TSC (#312) 2018-02-02 09:08:27 -06:00
.appveyor.yml Attempt to fix CI (#108) 2017-10-11 11:28:02 -04:00
.gitignore Use workspaces and fix tests 2017-11-22 13:42:58 +01:00
.travis.yml Move travis workaround earlier 2018-01-11 08:24:11 -08:00
Cargo.toml Add an example of SIMD-powered hex encoding (#291) 2018-01-19 16:53:38 -06:00
CONTRIBUTING.md Update CONTRIBUTING.md with recent changes 2018-01-29 07:17:14 -08:00
LICENSE-APACHE Add license files 2017-09-25 12:43:06 -07:00
LICENSE-MIT Add license files 2017-09-25 12:43:06 -07:00
QUESTIONS.md refactor 2017-06-19 17:06:53 -04:00
README.md Update doc generation with recent devlopments 2018-01-28 22:00:13 -08:00
rustfmt.toml [fmt] remove fn_call_width option (was removed upstream) 2017-12-22 00:24:23 +01:00

stdsimd

Travis-CI Status Appveyor Status Latest Version docs

Experimental support for SIMD destined to eventually become part of Rust's standard library

This is a work in progress.

Approach

The main goal is to expose APIs defined by vendors with the least amount of abstraction possible. On x86, for example, the API should correspond to that provided by emmintrin.h.

License

stdsimd is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0), with portions covered by various BSD-like licenses.

See LICENSE-APACHE, and LICENSE-MIT for details.