mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-12-12 22:17:47 +00:00
8a584da153
To match NewPM pass name, and also for readability. Also rename rpo-functionattrs -> rpo-function-attrs while we're here. Reviewed By: arsenm Differential Revision: https://reviews.llvm.org/D84694
26 lines
575 B
LLVM
26 lines
575 B
LLVM
; RUN: opt < %s -function-attrs -S | FileCheck %s
|
|
; RUN: opt < %s -passes=function-attrs -S | FileCheck %s
|
|
|
|
@x = global i32 0
|
|
|
|
define void @test_opt(i8* %p) {
|
|
; CHECK-LABEL: @test_opt
|
|
; CHECK: (i8* nocapture readnone %p) #0 {
|
|
ret void
|
|
}
|
|
|
|
define void @test_optnone(i8* %p) noinline optnone {
|
|
; CHECK-LABEL: @test_optnone
|
|
; CHECK: (i8* %p) #1 {
|
|
ret void
|
|
}
|
|
|
|
declare i8 @strlen(i8*) noinline optnone
|
|
; CHECK-LABEL: @strlen
|
|
; CHECK: (i8*) #1
|
|
|
|
; CHECK-LABEL: attributes #0
|
|
; CHECK: = { norecurse nounwind readnone }
|
|
; CHECK-LABEL: attributes #1
|
|
; CHECK: = { noinline optnone }
|