You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We introduce .note.gnu.property section to store infomations that linker
or runtime system may use, and we define 4 program property classes to
specifying the merge semantics, it's used for forward compatibility in linker
implementations, allowing linker can correctly handle program property types
even if they are not recognized.
We don't define any program property within this PR, it would be
separate PR like #417
+++.riscv.attributes+++ names a section that contains RISC-V ELF attributes.
1091
1092
1092
1093
+++.riscv.jvt+++ is a linker-created section to store table jump
1093
1094
target addresses. The minimum alignment of this section is 64 bytes.
1094
1095
1096
+
+++.note.gnu.property+++ names a section that contains a program property note.
1097
+
1095
1098
=== Program Header Table
1096
1099
1097
1100
The defined processor-specific segment types are listed in <<rv-seg-type>>.
@@ -1355,6 +1358,46 @@ value. After the merge, the resulting value will be the non-zero one.
1355
1358
1356
1359
--
1357
1360
1361
+
=== Program Property
1362
+
1363
+
Program property are used to record information about an object file/binary that
1364
+
a linker or runtime loader needs to check compatibility.
1365
+
1366
+
The program property is divided into different classes, each defining a range
1367
+
of program property types and specifying the merge semantics. This is designed
1368
+
for forward compatibility in linker implementations, allowing them to correctly
1369
+
handle program property types even if they are not recognized.
1370
+
1371
+
[[rv-prog-prop-classes]]
1372
+
.RISC-V-specific program property classes
1373
+
[cols="3,2,2,5"]
1374
+
[width=100%]
1375
+
|===
1376
+
| Name | Range | Data Type | Merge Semantic
1377
+
1378
+
| UINT32_AND | 0xc0000000 ~ 0xc0007fff | 4-bytes | A bit is set if it is set in all inputs.
1379
+
| UINT32_OR | 0xc0008000 ~ 0xc000ffff | 4-bytes | A bit is set if it is set in any inputs.
1380
+
| UINT32_OR_AND | 0xc0010000 ~ 0xc0017fff | 4-bytes | A bit is set if it is set in any inputs and the property is present in all inputs.
1381
+
| UINT32_EXACTLY | 0xc0018000 ~ 0xc001ffff | 4-bytes | A 32 bit unsigned value is specified if it is set same value in all inputs, tool should report error if mismatched.
1382
+
|===
1383
+
1384
+
[[rv-prog-prop-class-constants]]
1385
+
.Constants for RISC-V-specific program property class
0 commit comments