2012-05-13 05:10:52 +08:00
|
|
|
// RUN: %clang_cc1 -emit-llvm %s -o - | FileCheck %s
|
|
|
|
|
|
|
|
int test1() __attribute__((__cold__)) {
|
|
|
|
return 42;
|
|
|
|
|
|
|
|
// Check that we set the optsize attribute on the function.
|
2013-02-21 03:30:01 +08:00
|
|
|
// CHECK: @test1{{.*}}[[ATTR:#[0-9]+]]
|
2012-05-13 05:10:52 +08:00
|
|
|
// CHECK: ret
|
|
|
|
}
|
2013-02-20 15:22:19 +08:00
|
|
|
|
2013-02-21 03:30:01 +08:00
|
|
|
// CHECK: attributes [[ATTR]] = { {{.*}}optsize{{.*}} }
|