3 ms·
If you enjoy reading Rust code, you can see some examples I have... 1. This example [1] compares a SIMD-accelerated implementation of an algorithm vs the naive
by shepmaster 4y ago
If you enjoy reading Rust code, you can see some examples I have...
1. This example [1] compares a SIMD-accelerated implementation of an algorithm vs the naive implementation. This is usually referred to as an "oracle".
2. This example [2] tests an XML document object model library. The tests construct a sequence of operations to apply to a document ("add an element", "delete an element", "move an element" etc) and then assert properties that you expect to be true for a DOM tree (a parent and child are always cross-linked, for example)
[1]: https://github.com/shepmaster/jetscii/blob/8d7e44ad7da990ef1cec52284c224744db2c035f/src/simd.rs#L408-L430 https://github.com/shepmaster/jetscii/blob/8d7e44ad7da990ef1...
[2]: https://github.com/shepmaster/sxd/pull/21/files#diff-fc21cbf590daae893e9c208224575446c71288af0e7db1bfcb3dad0b67f94c33R1481-R1492 https://github.com/shepmaster/sxd/pull/21/files#diff-fc21cbf...