Files
swift-mirror/test/SILOptimizer/OSLogMandatoryOptTest.swift
Ravi Kandhadai fb943cca8a [OSLogOptimization] Make emitCodeForSymbolicValue function generate
code for closures iff the closure is not created by the caller function
where the code is generated. Otherwise, when the closure is created
by the caller, just reuse it after copying and extending its lifetime.

Before this change new closures were created as long as all captures
of the closures were symbolic constants. This patch updates it so that
even if all captures are symbolic constants no code is generated for
closures that are already available in the caller. This avoids doing
needless work and also fixes the following bug.

<rdar://problem/61465764>
2020-04-08 11:53:52 -07:00

35 KiB