diff options
Diffstat (limited to 'llvm/docs')
-rw-r--r-- | llvm/docs/CallGraphSection.md | 18 | ||||
-rw-r--r-- | llvm/docs/CodeGenerator.rst | 7 | ||||
-rw-r--r-- | llvm/docs/QualGroup.rst | 15 | ||||
-rw-r--r-- | llvm/docs/Reference.rst | 1 |
4 files changed, 41 insertions, 0 deletions
diff --git a/llvm/docs/CallGraphSection.md b/llvm/docs/CallGraphSection.md new file mode 100644 index 0000000..8b18727 --- /dev/null +++ b/llvm/docs/CallGraphSection.md @@ -0,0 +1,18 @@ +# .callgraph Section Layout + +The `.callgraph` section is used to store call graph information for each function. The section contains a series of records, with each record corresponding to a single function. + +## Per Function Record Layout + +Each record in the `.callgraph` section has the following binary layout: + +| Field | Type | Size (bits) | Description | +| -------------------------------------- | ------------- | ----------- | ------------------------------------------------------------------------------------------------------- | +| Format Version | `uint8_t` | 8 | The version of the record format. The current version is 0. | +| Flags | `uint8_t` | 8 | A bitfield where: Bit 0 is set if the function is a potential indirect call target; Bit 1 is set if there are direct callees; Bit 2 is set if there are indirect callees. The remaining 5 bits are reserved. | +| Function Entry PC | `uintptr_t` | 32/64 | The address of the function's entry point. | +| Function Type ID | `uint64_t` | 64 | The type ID of the function. This field is non-zero if the function is a potential indirect call target and its type is known. | +| Number of Unique Direct Callees | `ULEB128` | Variable | The number of unique direct call destinations from this function. This field is only present if there is at least one direct callee. | +| Direct Callees Array | `uintptr_t[]` | Variable | An array of unique direct callee entry point addresses. This field is only present if there is at least one direct callee. | +| Number of Unique Indirect Target Type IDs| `ULEB128` | Variable | The number of unique indirect call target type IDs. This field is only present if there is at least one indirect target type ID. | +| Indirect Target Type IDs Array | `uint64_t[]` | Variable | An array of unique indirect call target type IDs. This field is only present if there is at least one indirect target type ID. | diff --git a/llvm/docs/CodeGenerator.rst b/llvm/docs/CodeGenerator.rst index 7486054..fc704a3 100644 --- a/llvm/docs/CodeGenerator.rst +++ b/llvm/docs/CodeGenerator.rst @@ -1662,6 +1662,13 @@ and stack sizes (unsigned LEB128). The stack size values only include the space allocated in the function prologue. Functions with dynamic stack allocations are not included. +Emitting function call graph information +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +A section containing metadata on function call graph will be emitted when +``TargetOptions::EmitCallGraphSection`` is set (--call-graph-section). Layout of +this section is documented in detail at :doc:`CallGraphSection`. + VLIW Packetizer --------------- diff --git a/llvm/docs/QualGroup.rst b/llvm/docs/QualGroup.rst index b45f569..5c05e4e 100644 --- a/llvm/docs/QualGroup.rst +++ b/llvm/docs/QualGroup.rst @@ -75,6 +75,16 @@ They meet the criteria for inclusion below. Knowing their handles help us keep t - capitan-davide - capitan_davide - capitan-davide + * - Jorge Pinto Sousa + - Critical Techworks + - sousajo-cc + - sousajo-cc + - sousajo-cc + * - José Rui Simões + - Critical Software + - jr-simoes + - jr_simoes + - iznogoud-zz * - Oscar Slotosch - Validas - slotosch @@ -100,6 +110,11 @@ They meet the criteria for inclusion below. Knowing their handles help us keep t - YoungJunLee - YoungJunLee - IamYJLee + * - Zaky Hermawan + - No Affiliation + - ZakyHermawan + - quarkz99 + - zakyHermawan Organizations are limited to three representatives within the group to maintain diversity. diff --git a/llvm/docs/Reference.rst b/llvm/docs/Reference.rst index 5d842d3..9b1bf1b 100644 --- a/llvm/docs/Reference.rst +++ b/llvm/docs/Reference.rst @@ -15,6 +15,7 @@ LLVM and API reference documentation. BranchWeightMetadata Bugpoint CalleeTypeMetadata + CallGraphSection CIBestPractices CommandGuide/index ContentAddressableStorage |