Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
PIR Generators #4559
PIR Generators #4559
Changes from 52 commits
669707c
7e79cf7
8fa0859
242984a
faf11cd
45978d1
1990886
fb1b37d
08a9ec7
a0f84e3
7b961e6
dd35f47
794a7e1
23b8c1d
d0b9f8e
f00254f
c48edcb
536642e
6ee2d0f
6cf273e
d05a210
f06f47d
7cea94f
37e2b89
876b07e
890ff91
1a392dd
50df298
d0a6e10
7249c77
50ffcea
d40e57e
adc8415
78c592b
f16f958
bfb7d07
a10454f
a52a16a
8a2c44e
f29dcbb
cda5770
a0de3e2
4377c2f
fd13cb4
108e665
b30f947
87908f4
a4d1bff
2a42fc6
2898705
723fda2
b841156
6610af0
d4e43bd
a1a6382
c4765df
2389328
69e6065
cd90088
a8e8afd
aeea83b
0956890
ccd9484
75d1fa3
c866f28
f3ca510
b3887c3
9662aa2
0f50120
7a69139
dd9b95c
7caa634
99124c8
a087635
122630d
6b29e28
85c40d7
2e9068a
e25eec6
74c4b46
d1f3e78
a9f872b
004587e
8272249
180d8e5
025a495
5db7792
a8a2919
5359389
6f17b92
01cf59c
2f1899c
2073a2d
3068a4a
cae4fb5
bd6bbbc
3eed522
c643347
d4582f6
47a4227
b4b54d4
c71d964
560a377
d1cf5a6
c0cf301
fd751ff
33e154d
84286f4
5afc967
4c76ad2
88bec79
44de8c4
bb64ff1
b27a07e
dd0048c
ba134a6
c20e48d
e824886
b1691fa
d7eb16d
1a4abe2
05a1f36
2559022
b2cfc24
4425a58
1b6f144
6a74dc3
ef9e328
ef4a379
7e794a7
4033f34
fd778e9
4ef3ca6
abdf1d2
d855182
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@michaelpj Is the compiler supposed to do renaming itself? It's weird to impose this requirement on the caller for any not for-internal-consumption-only function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, and in particular this property only becomes interesting when the shrinker isn't working, at which point you can't rely on shrinks being well-typed!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Super clever.
I'm confused about something, though. So let's pretend those pairs are numbers and "type checking" a number fails when that number is, say, 17.
We start running tests:
Now we start shrinking 25.
Now reduce 20:
So in total: any counterexample will require us to go through a cubic (?) number of boring test cases. Is this correct?
Of course type-and-term pairs are not numbers, so we aren't going to test the same thing over and over again, but it does seem like we're mostly stuck in the corner with little examples.
Or am I misunderstanding it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I unresolved this comment, because I still have the questions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oops, I don't think this was meant to get resolved. I was intending to answer here. Yes, you're right that - in the worst case - you get cubic shrinking. There are two things you can do about this:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will they see that shrinking is being done? I don't remember how QuickCheck handles that.
Yeah, I'm not trying to suggest this needs to be fixed in this PR, seems like a rather non-trivial problem. It's not even clear to me if anything needs to be fixed at all, maybe we get diverse small shrinks that way.
But could you leave a note about shrinking being cubic in the worst case and potentially running through the same shrinks over and over again?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, the user sees that shrinking is taking place. The reason I hesitate to put a comment in about this is that this is almost always the case for all QuickCheck properties - not just this one.