runtime: add and switch to SWIFT_NOINLINE (NFC)

This switches the `LLVM_ATTRIBUTE_NOINLINE` to a local copy which is
namespaced in Swift.
This commit is contained in:
Saleem Abdulrasool
2020-05-06 08:27:26 -07:00
parent 923def217f
commit f465ec0345
6 changed files with 33 additions and 24 deletions

View File

@@ -224,7 +224,7 @@ static _Unwind_Reason_Code SwiftUnwindFrame(struct _Unwind_Context *context, voi
}
#endif
LLVM_ATTRIBUTE_NOINLINE
SWIFT_NOINLINE
void swift::printCurrentBacktrace(unsigned framesToSkip) {
#if SWIFT_SUPPORTS_BACKTRACE_REPORTING
constexpr unsigned maxSupportedStackDepth = 128;
@@ -320,9 +320,9 @@ reportNow(uint32_t flags, const char *message)
#endif
}
LLVM_ATTRIBUTE_NOINLINE SWIFT_RUNTIME_EXPORT
void _swift_runtime_on_report(uintptr_t flags, const char *message,
RuntimeErrorDetails *details) {
SWIFT_NOINLINE SWIFT_RUNTIME_EXPORT void
_swift_runtime_on_report(uintptr_t flags, const char *message,
RuntimeErrorDetails *details) {
// Do nothing. This function is meant to be used by the debugger.
// The following is necessary to avoid calls from being optimized out.