|
26 | 26 | * [Hash Table](#hash-table) |
27 | 27 | 5. [DWARF](#dwarf) |
28 | 28 | * [Dwarf Register Numbers](#dwarf-register-numbers) |
| 29 | +6. [Linux-specific ABI](#linux-abi) |
| 30 | + * [Linux-specific C type sizes and alignments](#linux-c-type-sizes) |
| 31 | + * [Linux-specific C type representations](#linux-c-type-representations) |
29 | 32 |
|
30 | 33 | ## Copyright and license information |
31 | 34 |
|
@@ -833,3 +836,29 @@ Dwarf Number | Register Name | Description |
833 | 836 | The alternate frame return column is meant to be used when unwinding from |
834 | 837 | signal handlers, and stores the address where the signal handler will return |
835 | 838 | to. |
| 839 | + |
| 840 | +# <a name=linux-abi></a> Linux-specific ABI |
| 841 | + |
| 842 | +**This section of the RISC-V ELF psABI specification only applies to Linux-based |
| 843 | +systems.** |
| 844 | + |
| 845 | +In order to ensure compatibility between different implementations of the C |
| 846 | +library for Linux, we provide some extra definitions which only apply on those |
| 847 | +systems. These are noted in this section. |
| 848 | + |
| 849 | +## <a name=linux-c-type-sizes></a> Linux-specific C type sizes and alignments |
| 850 | + |
| 851 | +The following definitions apply for all ABIs defined in this document. Here |
| 852 | +there is no differentiation between ILP32 and LP64 abis. |
| 853 | + |
| 854 | +Type | Size (Bytes) | Alignment (Bytes) |
| 855 | +------------|---------------|------------------ |
| 856 | +wchar_t | 4 | 4 |
| 857 | +wint_t | 4 | 4 |
| 858 | + |
| 859 | +## <a name=linux-c-type-representations></a> Linux-specific C type representations |
| 860 | + |
| 861 | +The following definitions apply for all ABIs defined in this document. Here |
| 862 | +there is no differentiation between ILP32 and LP64 abis. |
| 863 | + |
| 864 | +`wchar_t` is signed. `wint_t` is unsigned. |
0 commit comments