Merge "[MIPS64] Pass large objects by value for mips64 arch" am: 6834cd0d47 am: be6f51c8ea
am: 6482d80deb

Change-Id: I42b09e7ef1d939cbe6fc12b00fafa3536bee05c8
diff --git a/lib/Compiler.cpp b/lib/Compiler.cpp
index 5000fa1..44f23c5 100644
--- a/lib/Compiler.cpp
+++ b/lib/Compiler.cpp
@@ -269,8 +269,9 @@
 
   // These passes have to come after LTO, since we don't want to examine
   // functions that are never actually called.
-  if (llvm::Triple(getTargetMachine().getTargetTriple()).getArch() == llvm::Triple::x86_64)
-    transformPasses.add(createRSX86_64CallConvPass());  // Add pass to correct calling convention for X86-64.
+  if (llvm::Triple(getTargetMachine().getTargetTriple()).getArch() == llvm::Triple::x86_64 ||
+      llvm::Triple(getTargetMachine().getTargetTriple()).getArch() == llvm::Triple::mips64el)
+    transformPasses.add(createRSX86_64CallConvPass());  // Add pass to correct calling convention for X86-64 and mips64.
   transformPasses.add(createRSIsThreadablePass());      // Add pass to mark script as threadable.
 
   // RSEmbedInfoPass needs to come after we have scanned for non-threadable