Skip to content

Commit f055791

Browse files
Merge pull request #26939 from varungandhi-apple/vg-mem-hungry-solver-test
Add minimal test case for rdar://problem/54580427.
2 parents 23cd3d6 + e4f0f78 commit f055791

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
// FIXME: This should be linear instead of exponential.
2+
// RUN: %scale-test --begin 1 --end 10 --step 1 --select NumLeafScopes --invert-result %s
3+
// REQUIRES: OS=macosx
4+
// REQUIRES: asserts
5+
6+
enum Val {
7+
case d([String: Val])
8+
case f(Double)
9+
}
10+
11+
struct X {
12+
var x : Float
13+
}
14+
15+
extension X {
16+
func val() -> Val {
17+
return Val.d([
18+
%for i in range(0, N):
19+
"x": .f(Double(x)),
20+
%end
21+
])
22+
}
23+
}

0 commit comments

Comments
 (0)