2018-06-30 00:12:45 +08:00
|
|
|
; RUN: llc %s -debug-pass=Structure -verify-machineinstrs \
|
|
|
|
; RUN: -enable-machine-outliner=always -mtriple arm64---- -o /dev/null 2>&1 \
|
|
|
|
; RUN: | FileCheck %s -check-prefix=ALWAYS
|
|
|
|
|
2018-06-29 05:49:24 +08:00
|
|
|
; RUN: llc %s -debug-pass=Structure -verify-machineinstrs \
|
|
|
|
; RUN: -enable-machine-outliner -mtriple arm64---- -o /dev/null 2>&1 \
|
|
|
|
; RUN: | FileCheck %s -check-prefix=ENABLE
|
|
|
|
|
2018-06-30 00:12:45 +08:00
|
|
|
; RUN: llc %s -debug-pass=Structure -verify-machineinstrs \
|
|
|
|
; RUN: -enable-machine-outliner=never -mtriple arm64---- -o /dev/null 2>&1 \
|
|
|
|
; RUN: | FileCheck %s -check-prefix=NEVER
|
|
|
|
|
2018-06-29 05:49:24 +08:00
|
|
|
; RUN: llc %s -debug-pass=Structure -verify-machineinstrs \
|
|
|
|
; RUN: -mtriple arm64---- -o /dev/null 2>&1 \
|
|
|
|
; RUN: | FileCheck %s -check-prefix=NOT-ADDED
|
|
|
|
|
|
|
|
; RUN: llc %s -O=0 -debug-pass=Structure -verify-machineinstrs \
|
|
|
|
; RUN: -mtriple arm64---- -o /dev/null 2>&1 \
|
|
|
|
; RUN: | FileCheck %s -check-prefix=OPTNONE
|
|
|
|
|
|
|
|
; Make sure that the outliner is added to the pass pipeline only when the
|
|
|
|
; appropriate flags/settings are set. Make sure it isn't added otherwise.
|
|
|
|
;
|
|
|
|
; Cases where it should be added:
|
|
|
|
; * -enable-machine-outliner
|
2018-06-30 00:12:45 +08:00
|
|
|
; * -enable-machine-outliner=always
|
2018-06-29 05:49:24 +08:00
|
|
|
;
|
|
|
|
; Cases where it should not be added:
|
|
|
|
; * -O0 or equivalent
|
|
|
|
; * -enable-machine-outliner is not passed
|
2018-06-30 00:12:45 +08:00
|
|
|
; * -enable-machine-outliner=never is passed
|
2018-06-29 05:49:24 +08:00
|
|
|
|
2018-06-30 00:12:45 +08:00
|
|
|
; ALWAYS: Machine Outliner
|
2018-06-29 05:49:24 +08:00
|
|
|
; ENABLE: Machine Outliner
|
2018-06-30 00:12:45 +08:00
|
|
|
; NEVER-NOT: Machine Outliner
|
2018-06-29 05:49:24 +08:00
|
|
|
; NOT-ADDED-NOT: Machine Outliner
|
|
|
|
; OPTNONE-NOT: Machine Outliner
|
|
|
|
|
|
|
|
define void @foo() {
|
|
|
|
ret void;
|
|
|
|
}
|
|
|
|
|