Don't try to use inreg with 0 sized structs. Thanks to Eli for reporting the
regression.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@166461 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/TargetInfo.cpp b/lib/CodeGen/TargetInfo.cpp
index a9e11cb..6a929a1 100644
--- a/lib/CodeGen/TargetInfo.cpp
+++ b/lib/CodeGen/TargetInfo.cpp
@@ -810,6 +810,10 @@
     return false;
 
   unsigned SizeInRegs = (getContext().getTypeSize(Ty) + 31) / 32;
+
+  if (SizeInRegs == 0)
+    return false;
+
   if (SizeInRegs > FreeRegs) {
     FreeRegs = 0;
     return false;