[llvm] [ORC] Add signext on @sum() arguments in test. (PR #113308)

Jonas Paulsson via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 29 04:16:17 PDT 2024


================
@@ -90,6 +90,35 @@ class OrcCAPITestBase : public testing::Test {
 
     LLVMOrcDisposeLLJIT(J);
     TargetSupported = true;
+
+    // Create test functions in text format, with the proper extension
+    // attributes.
+    if (SumExample.empty()) {
+      std::string I32RetExt = "";
+      std::string I32ArgExt = "";
+      if (StringRef(TargetTriple).starts_with("s390x-ibm-linux"))
+        I32RetExt = I32ArgExt = "signext ";
+
+      std::ostringstream OS;
+      OS << "define " << I32RetExt << " i32 "
+         << R"(@sum()" << "i32 " << I32ArgExt << "%x, i32 " << I32ArgExt << "%y)"
----------------
JonPsson1 wrote:

yep

https://github.com/llvm/llvm-project/pull/113308


More information about the llvm-commits mailing list