Strip unknown attributes during bitcode translation.
am: bcb03e5437
Change-Id: I7f3db7071417db424530aa00b0883a1d05f355ab
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
diff --git a/lib/Script.cpp b/lib/Script.cpp
index 950d82a..d84012c 100644
--- a/lib/Script.cpp
+++ b/lib/Script.cpp
@@ -66,6 +66,8 @@
// violate any compiler version guarantees, so the right thing to
// do is retain the compiler version from source, which specifies
// which guarantees source (and hence the merged code) satisfies.
+ // See frameworks/rs/driver/README.txt regarding libclcore_source
+ // obeying compiler version guarantees.
// - optimization level in source and libclcore_source is meaningful.
// We simply define the optimization level in the linked code to
// be the optimization level of source.