[AA] Pass query info.
[llvm-project.git] / libc / src / stdlib / linux / _Exit.cpp
blob1c5f60a17a2792d1ebf08a53909a6b1c6a07bed9
1 //===------------------- Linux Implementation of _Exit --------------------===//
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-exception
6 //
7 //===----------------------------------------------------------------------===//
9 #include "config/linux/syscall.h" // For internal syscall function.
10 #include "include/sys/syscall.h" // For syscall numbers.
11 #include "src/__support/common.h"
13 #include "src/stdlib/_Exit.h"
15 namespace __llvm_libc {
17 void LLVM_LIBC_ENTRYPOINT(_Exit)(int status) {
18 for (;;) {
19 __llvm_libc::syscall(SYS_exit_group, status);
20 __llvm_libc::syscall(SYS_exit, status);
24 } // namespace __llvm_libc