[flang] Use object before converts in fir.dispatch (#68589)
[llvm-project.git] / libc / include / llvm-libc-types / jmp_buf.h
blob6af4e8ebad92ca646292c639e657c552bc9b7567
1 //===-- Definition of type jmp_buf ----------------------------------------===//
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 #ifndef __LLVM_LIBC_TYPES_JMP_BUF_H__
10 #define __LLVM_LIBC_TYPES_JMP_BUF_H__
12 typedef struct {
13 #ifdef __x86_64__
14 __UINT64_TYPE__ rbx;
15 __UINT64_TYPE__ rbp;
16 __UINT64_TYPE__ r12;
17 __UINT64_TYPE__ r13;
18 __UINT64_TYPE__ r14;
19 __UINT64_TYPE__ r15;
20 __UINTPTR_TYPE__ rsp;
21 __UINTPTR_TYPE__ rip;
22 #elif defined(__riscv)
23 /* Program counter. */
24 long int __pc;
25 /* Callee-saved registers. */
26 long int __regs[12];
27 /* Stack pointer. */
28 long int __sp;
29 /* Callee-saved floating point registers. */
30 #if __riscv_float_abi_double
31 double __fpregs[12];
32 #elif defined(__riscv_float_abi_single)
33 #error "__jmp_buf not available for your target architecture."
34 #endif
35 #else
36 #error "__jmp_buf not available for your target architecture."
37 #endif
38 } __jmp_buf;
40 typedef __jmp_buf jmp_buf[1];
42 #endif // __LLVM_LIBC_TYPES_JMP_BUF_H__