You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The verification condition for expected/actual JVP/VJP operand types can be relaxed to sth like checking for "function type ABI differences".
Re-enabling verification would be great. I think it may expose some latent issues in autodiff tests (like test/AutoDiff/reabstraction.swift) that cause flaky test failures.
Currently, @differentiable function types in SIL are quite difficult to correctly reabstract and transform because expected JVP/VJP types are computed from the original function type. I think your old idea of "creating a new SILDifferentiableFunctionType" where all three types are distinct could still be a good idea. That would also enable optimization/specialization of the original function operand when the JVP/VJP operands cannot be optimized.
Thanks for the context. Disabling verification seemed like an suboptimal solution. There are a lot of weaker things that can be checked here, e.g. the equality of unsubstituted types or at least making sure the indirectness and ownership conventions are the same. Not checking these will lead to memory leaks (which happened to me when I make ownership-related changes) and other errors that are hard to debug.
Additional Detail from JIRA
md5: 3d2c6f9bc1f6178b50b1c770758eb175
Parent-Task:
blocks:
relates to:
Issue Description:
The text was updated successfully, but these errors were encountered: