Fix bugs in ECAdd Circuit
Opened this issue · 0 comments
fpapa250 commented
There are a few bugs with the ECAdd circuit from https://arxiv.org/abs/2306.08585. The inputs and outputs are fine, but in steps 2, 5, and 6 some of the flag bits are freed before they are set correctly back to zero. The circuit shows that none of the qubits are freed when dirty, however this is not the case. The following bugs exist:
- Step 2: lam = lam_r undoes f1 when it should only happen if lam is set to lam_r
- Step 5: free dirty reg lam when a,b=x,y (not sure why)
- Step 6: free dirty reg when x,y = 0,0
- when b = y = 0, but x != 0: f2 never gets flipped back
- when p1 = p2 and f4 not set f4 gets flipped on