Files
swift-mirror/test/SILOptimizer/pass_printer.swift
Erik Eckstein 8bc7fb860d Some improvements and simplifications regarding pass name printing in the pass manager.
* rename "Name" to "Description" in the pass definition, because it's not really the pass name, but the description of a pass
* remove the getName() from Transforms (which actually returned the description of a pass)
* in debug printing, print the pass ID and not the pass description. It makes it easier to correlate the debug output to the actual pass implementation.
* remove the iteration numbering in the pass manager, because we only run a single iteration anyway.
2018-01-09 15:35:26 -08:00

9 lines
825 B
Swift

// RUN: %target-swift-frontend -Xllvm -sil-print-before=definite-init -emit-sil %s -o /dev/null 2>&1 | %FileCheck --check-prefix=BEFORE %s
// RUN: %target-swift-frontend -Xllvm -sil-print-after=definite-init -emit-sil %s -o /dev/null 2>&1 | %FileCheck --check-prefix=AFTER %s
// RUN: %target-swift-frontend -Xllvm -sil-disable-pass=definite-init -Xllvm -sil-print-pass-name -emit-sil %s -o /dev/null 2>&1 | %FileCheck --check-prefix=DISABLE %s
// BEFORE: SIL function before #{{[0-9]+}}, stage Guaranteed Passes, pass {{[0-9]+}}: DefiniteInitialization (definite-init)
// AFTER: SIL function after #{{[0-9]+}}, stage Guaranteed Passes, pass {{[0-9]+}}: DefiniteInitialization (definite-init)
// DISABLE: (Disabled) #{{[0-9]+}}, stage Guaranteed Passes, pass {{[0-9]+}}: DefiniteInitialization (definite-init)
func foo() {}