Skip to content

Commit ea821b1

Browse files
committed
Use blackHole to make sure benchmark isn't optimized away
1 parent bdd9480 commit ea821b1

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

benchmark/single-source/DevirtualizeProtocolComposition.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ public func entryPoint1(c: ClassB) -> Int {
5959

6060
@inline(never)
6161
public func run_DevirtualizeProtocolComposition(N: Int) {
62-
for _ in 0..<N * 10_000 {
63-
entryPoint1(c: ClassB())
62+
for _ in 0..<N * 20_000 {
63+
blackHole(entryPoint1(c: ClassB()))
6464
}
6565
}

0 commit comments

Comments
 (0)