Extend CI with Windows (MSVC x86, MSVC amd64, GCC i686, GCC x86_64 and Clang)
Seeing how you added CI testing, would you also be interested in adding Windows to the tested platforms?
I mentioned in #1 that I have a fork with a test binary produced using the GCC builtins. This would need to be committed into this repo as well and the testing code needs to use that as a reference, since MSVC has no builtins to check against.
The fork can be found here https://github.com/friendlyanon/jtckdint and I have been tweaking it a lot, mainly to experiment with things, so please let me know if you like the look of things and I will create a PR with only the necessary changes.
Should also be mentioned that for GCC i686 and x86_64 I am using my minimal fork of Chris Wellons' w64devkit. I build the GCC and MinGW libraries in GitHub Actions. These can also easily be used in CI. Please let me know if you agree.
So, I'm trying to work on upstreaming the related changes from my fork, but I'm having trouble.
I have created a C89-ish file that reproduces the test.bin data for testing implementations without GCC builtins: https://github.com/friendlyanon/jtckdint/blob/master/corpus.c
The output of this tests perfectly with GCC builtins (duh!) and C(++)11 implementations of my fork, but not with (practically) unaltered upstream header: https://github.com/friendlyanon/jtckdint/commit/28b960cecb6691efe34f6f75bfa3fbc123077087#diff-b8d595a699e7694d818d745fd1d7056bb853a61a15479d8bbd6bc90faf1bf5c2
Mismatch @ 0x7FCA
Actual: (1) 1
Expected: (0) 1
Types: T = uint8_t, U = uint8_t, V = int8_t
Operation: ckd_sub(0, -1)
Vector indices: i = 0, j = 7
I'm not sure if it's even worth trying to find out why this happens, since my fork tests correctly on all platforms with all implementations. I could upstream all my changes if you agree to having the reserved identifiers changed to allowed identifiers, ckd_* being treated as a "namespace" for some additional names, east const and clang-formatted source.