Skip to content

Commit b1bc601

Browse files
committed
platforms: Add RISC-V 32-bit and 64-bit platform files
Refer to RISC-V calling conventions [1], this commit adds platform files for RISC-V 32-bit and 64-bit plarforms. [1]: https://github.com/riscv-non-isa/riscv-elf-psabi-doc/blob/master/riscv-cc.adoc#cc-type-sizes-and-alignments
1 parent b9e6ace commit b1bc601

2 files changed

Lines changed: 36 additions & 0 deletions

File tree

platforms/riscv32.xml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?xml version="1.0"?>
2+
<platform>
3+
<char_bit>8</char_bit>
4+
<default-sign>unsigned</default-sign>
5+
<sizeof>
6+
<bool>1</bool>
7+
<short>2</short>
8+
<int>4</int>
9+
<long>4</long>
10+
<long-long>8</long-long>
11+
<float>4</float>
12+
<double>8</double>
13+
<long-double>16</long-double>
14+
<pointer>4</pointer>
15+
<size_t>4</size_t>
16+
<wchar_t>4</wchar_t>
17+
</sizeof>
18+
</platform>

platforms/riscv64.xml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?xml version="1.0"?>
2+
<platform>
3+
<char_bit>8</char_bit>
4+
<default-sign>unsigned</default-sign>
5+
<sizeof>
6+
<bool>1</bool>
7+
<short>2</short>
8+
<int>4</int>
9+
<long>8</long>
10+
<long-long>8</long-long>
11+
<float>4</float>
12+
<double>8</double>
13+
<long-double>16</long-double>
14+
<pointer>8</pointer>
15+
<size_t>8</size_t>
16+
<wchar_t>4</wchar_t>
17+
</sizeof>
18+
</platform>

0 commit comments

Comments
 (0)