From 0ab1886df1c6b202479a41cf5733d32eb9c54bfc Mon Sep 17 00:00:00 2001 From: Mark Stoodley Date: Wed, 23 Aug 2023 16:49:23 -0400 Subject: [PATCH] JitBuilder method symbols should use TR_System linkage convention Discovered on Aarch64 but it's something we should do consistently for all platforms. Signed-off-by: Mark Stoodley --- compiler/ilgen/OMRIlBuilder.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/compiler/ilgen/OMRIlBuilder.cpp b/compiler/ilgen/OMRIlBuilder.cpp index 402a7f3a9d9..dc25344cf17 100644 --- a/compiler/ilgen/OMRIlBuilder.cpp +++ b/compiler/ilgen/OMRIlBuilder.cpp @@ -2022,6 +2022,7 @@ OMR::IlBuilder::ComputedCall(const char *functionName, int32_t numArgs, ...) TR_ASSERT_FATAL(resolvedMethod, "Could not identify function %s\n", functionName); TR::SymbolReference *methodSymRef = symRefTab()->findOrCreateComputedStaticMethodSymbol(JITTED_METHOD_INDEX, -1, resolvedMethod); + methodSymRef->getSymbol()->getMethodSymbol()->setLinkage(TR_System); return genCall(methodSymRef, numArgs, argValues, false /*isDirectCall*/); } @@ -2041,6 +2042,7 @@ OMR::IlBuilder::ComputedCall(const char *functionName, int32_t numArgs, TR::IlVa TR_ASSERT_FATAL(resolvedMethod, "Could not identify function %s\n", functionName); TR::SymbolReference *methodSymRef = symRefTab()->findOrCreateComputedStaticMethodSymbol(JITTED_METHOD_INDEX, -1, resolvedMethod); + methodSymRef->getSymbol()->getMethodSymbol()->setLinkage(TR_System); return genCall(methodSymRef, numArgs, argValues, false /*isDirectCall*/); } @@ -2143,6 +2145,7 @@ OMR::IlBuilder::Call(const char *functionName, int32_t numArgs, ...) TR_ASSERT_FATAL(resolvedMethod, "Could not identify function %s\n", functionName); TR::SymbolReference *methodSymRef = symRefTab()->findOrCreateStaticMethodSymbol(JITTED_METHOD_INDEX, -1, resolvedMethod); + methodSymRef->getSymbol()->getMethodSymbol()->setLinkage(TR_System); return genCall(methodSymRef, numArgs, argValues); } @@ -2156,6 +2159,7 @@ OMR::IlBuilder::Call(const char *functionName, int32_t numArgs, TR::IlValue ** a TR_ASSERT_FATAL(resolvedMethod, "Could not identify function %s\n", functionName); TR::SymbolReference *methodSymRef = symRefTab()->findOrCreateStaticMethodSymbol(JITTED_METHOD_INDEX, -1, resolvedMethod); + methodSymRef->getSymbol()->getMethodSymbol()->setLinkage(TR_System); return genCall(methodSymRef, numArgs, argValues); }