24 lines · cpp
1//===-- Implementation of siglongjmp --------------------------------------===//2//3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.4// See https://llvm.org/LICENSE.txt for license information.5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception6//7//===----------------------------------------------------------------------===//8 9#include "src/setjmp/siglongjmp.h"10#include "src/__support/common.h"11#include "src/setjmp/longjmp.h"12 13namespace LIBC_NAMESPACE_DECL {14 15// siglongjmp is the same as longjmp. The additional recovery work is done in16// the epilogue of the sigsetjmp function.17// TODO: move this inside the TU of longjmp and making it an alias after18// sigsetjmp is implemented for all architectures.19LLVM_LIBC_FUNCTION(void, siglongjmp, (jmp_buf buf, int val)) {20 return LIBC_NAMESPACE::longjmp(buf, val);21}22 23} // namespace LIBC_NAMESPACE_DECL24