Commit Graph

3 Commits

Author SHA1 Message Date
Rafael Espindola e2a9e90c88 Don't try to use inreg with 0 sized structs. Thanks to Eli for reporting the
regression.

llvm-svn: 166461
2012-10-23 02:04:01 +00:00
Rafael Espindola 703c47f807 Fix handling of the regparm attribute in the presence of classes with copy
constructors.

When I first moved regparm support to TargetInfo.cpp I tried to isolate it
in classifyArgumentTypeWithReg, but it is actually a lot easier to flip the
code around and check for regparm at the end of the decision tree.

Without this refactoring classifyArgumentTypeWithReg would have to duplicate
the logic about when to use non-byval indirect arguments.

llvm-svn: 166266
2012-10-19 05:04:37 +00:00
Rafael Espindola 32d8a275b9 Add inreg attributes to reference arguments.
llvm-svn: 145189
2011-11-27 18:35:39 +00:00