Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Zig Fiat-Crypto-generated code is now continuously tested #959

Merged
merged 1 commit into from
May 3, 2021

Conversation

jedisct1
Copy link
Contributor

@jedisct1 jedisct1 commented May 1, 2021

The first bits of Fiat-generated code have landed into the Zig standard library.

The code is now continuously tested on all supported platforms.

@jedisct1 jedisct1 changed the title Fiat-generated code is now continuously tested Zig Fiat-generated code is now continuously tested May 1, 2021
@JasonGross
Copy link
Collaborator

That's great to hear!

I'd like to reserve the heavy checkmark for tests that will be applied to pull requests before they are merged, i.e., backends where we expect that introducing, e.g., a transcription error changing + to * will result in our CI failing.

Is there a way to add a test to our CI that runs our code against the Zig crypto test-suite?

@JasonGross JasonGross changed the title Zig Fiat-generated code is now continuously tested Zig Fiat-Crypto-generated code is now continuously tested May 1, 2021
@jedisct1
Copy link
Contributor Author

jedisct1 commented May 1, 2021

Oh, absolutely, I can add that!

The first bits of fiat-generated code have landed into the Zig
standard library.

The code is now continuously tested on all supported platforms.
@jedisct1
Copy link
Contributor Author

jedisct1 commented May 1, 2021

Meanwhile, the check mark has been replaced by the white one.

@JasonGross
Copy link
Collaborator

Great, thanks! Could I trouble you too provide links to Zig's CI (if it's public) and to the part of the standard library that includes fiat-crypto (I couldn't find it with a brief Google search)

@jedisct1
Copy link
Contributor Author

jedisct1 commented May 1, 2021

Zig uses multiple CI systems, but this is the main one, used to test Linux, macOS and Windows builds.

The first bits using Fiat-crypto are here (generated file here) and other curves will follow quickly.

@JasonGross JasonGross merged commit a0ad690 into mit-plv:master May 3, 2021
@jedisct1
Copy link
Contributor Author

jedisct1 commented May 3, 2021

The generated code is now directly tested in fiat-crypto's CI:

https://github.com/mit-plv/fiat-crypto/blob/master/fiat-zig/src/main.zig

in addition to the inversion code, that is also part of what is run by CI.

These tests are run in debug mode, which checks for arithmetic overflow. And will also check for unexpected truncation with help of #939

@jedisct1 jedisct1 deleted the zigstd branch May 3, 2021 04:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants