summaryrefslogtreecommitdiffstats
path: root/test/CodeGenCXX/regparm.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2011-11-27 18:35:39 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2011-11-27 18:35:39 +0000
commit2871020b2d30b8a642c02280be849a7924426222 (patch)
treeef7635f8d14fb23e2f6f9f8f3ad6abfa7ca2978c /test/CodeGenCXX/regparm.cpp
parent13dc8f98f6108dca8aaa9721567ed5a2d9911e0f (diff)
Add inreg attributes to reference arguments.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145189 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGenCXX/regparm.cpp')
-rw-r--r--test/CodeGenCXX/regparm.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/CodeGenCXX/regparm.cpp b/test/CodeGenCXX/regparm.cpp
new file mode 100644
index 0000000000..f0ebd2be41
--- /dev/null
+++ b/test/CodeGenCXX/regparm.cpp
@@ -0,0 +1,6 @@
+// RUN: %clang_cc1 -triple i386-unknown-unknown %s -emit-llvm -o - | FileCheck %s
+
+
+// CHECK: _Z3fooRi(i32* inreg
+void __attribute__ ((regparm (1))) foo(int &a) {
+}