File tree Expand file tree Collapse file tree 2 files changed +22
-0
lines changed Expand file tree Collapse file tree 2 files changed +22
-0
lines changed Original file line number Diff line number Diff line change
1
+ // RUN: not %target-build-swift -O %s
2
+
3
+ // SR-12493: SIL verification error regarding substituted function types and
4
+ // `differentiable_function_extract` instruction. Occurs only with `-O`.
5
+
6
+ import _Differentiation
7
+
8
+ func exampleVJP_1( _ x0: Float ) -> ( Float , ( Float ) -> ( Float ) ) {
9
+ (
10
+ x0 * x0,
11
+ { ( 2 * x0 * $0) }
12
+ )
13
+ }
14
+
15
+ func bar( ) {
16
+ let f = differentiableFunction ( from: exampleVJP_1)
17
+ let pb = pullback ( at: 10 , in: f)
18
+ _ = pb ( 1 )
19
+ }
Original file line number Diff line number Diff line change 4
4
// RUN: %target-run %t/differential_operators
5
5
// REQUIRES: executable_test
6
6
7
+ // FIXME(SR-12493): Disable test for `-O` due to SIL verification error.
8
+ // REQUIRES: swift_test_mode_optimize_none
9
+
7
10
import _Differentiation
8
11
9
12
import StdlibUnittest
You can’t perform that action at this time.
0 commit comments