Skip to content

Document GNU_PROPERTY_X86_XXX

H.J. Lu requested to merge usr/hjl/property into master

The .note.gnu.property section with NT_GNU_PROPERTY_TYPE_0 has been added to Linux Extensions to gABI:

https://gitlab.com/x86-psABIs/Linux-ABI.git

GNU_PROPERTY_X86_XXX are processor-specific program property types for i386 and x86-64, which are used to support Indirect Branch Tracking (IBT) and Shadow Stack (SHSTK) as documented in Chapter 18 CONTROL-FLOW ENFORCEMENT TECHNOLOGY (CET) in Intel64 and IA-32 Architectures Software Developer’s Manual Volume 1 from:

https://software.intel.com/en-us/articles/intel-sdm

GNU_PROPERTY_X86_FEATURE_2_USED, GNU_PROPERTY_X86_FEATURE_2_NEEDED, GNU_PROPERTY_X86_ISA_1_USED and GNU_PROPERTY_X86_ISA_1_NEEDED can be used together to describe instruction sets and processor features contained in x86 ELF binaries.

  1. GNU_PROPERTY_X86_UINT32_AND_LO..GNU_PROPERTY_X86_UINT32_AND_HI A bit in the output pr_data field is set only if it is set in all relocatable input pr_data fields. If all bits in the the output pr_data field are zero, this property should be removed from output.

If the bit is 1, all input relocatables have the feature. If the bit is 0 or the property is missing, the info is unknown.

  1. GNU_PROPERTY_X86_UINT32_OR_LO..GNU_PROPERTY_X86_UINT32_OR_HI A bit in the output pr_data field is set if it is set in any relocatable input pr_data fields. If all bits in the the output pr_data field are zero, this property should be removed from output.

If the bit is 1, some input relocatables have the feature. If the bit is 0 or the property is missing, the info is unknown.

  1. GNU_PROPERTY_X86_UINT32_OR_AND_LO..GNU_PROPERTY_X86_UINT32_OR_AND_HI A bit in the output pr_data field is set if it is set in any relocatable input pr_data fields and this property is present in all relocatable input files. A missing property implies that its bits have unknown values. When all bits in the the output pr_data field are zero, this property should not be removed from output to indicate it has zero in all bits.

If the property is in output, all input relocatables have the property. If the bit is 1, some input relocatables have the feature. If the bit is 0, none of input relocatables have the feature.

* Makefile (INCLUDES): Add cet.tex.
* abi.tex: Include cet.
* cet.tex: New file.
* dl.tex: Document GNU_PROPERTY_X86_UINT32_AND_LO,
GNU_PROPERTY_X86_UINT32_AND_HI, GNU_PROPERTY_X86_UINT32_OR_LO,
GNU_PROPERTY_X86_UINT32_OR_HI, GNU_PROPERTY_X86_UINT32_OR_AND_LO,
GNU_PROPERTY_X86_UINT32_OR_AND_HI, GNU_PROPERTY_X86_FEATURE_1_AND,
GNU_PROPERTY_X86_FEATURE_2_USED, GNU_PROPERTY_X86_FEATURE_2_NEEDED,
GNU_PROPERTY_X86_ISA_1_USED, GNU_PROPERTY_X86_ISA_1_NEEDED,
GNU_PROPERTY_X86_FEATURE_1_IBT, GNU_PROPERTY_X86_FEATURE_1_SHSTK,
GNU_PROPERTY_X86_ISA_1_XXX and GNU_PROPERTY_X86_FEATURE_2_XXX.

The PDF file is here.

Edited by H.J. Lu

Merge request reports

Loading