Fuzz introspector
For issues and ideas: https://github.com/ossf/fuzz-introspector/issues

Project functions overview

The following table shows data about each function in the project. The functions included in this table correspond to all functions that exist in the executables of the fuzzers. As such, there may be functions that are from third-party libraries.

For further technical details on the meaning of columns in the below table, please see the Glossary .

Func name Functions filename Args Function call depth Reached by Fuzzers Runtime reached by Fuzzers Combined reached by Fuzzers Fuzzers runtime hit Func lines hit % I Count BB Count Cyclomatic complexity Functions reached Reached by functions Accumulated cyclomatic complexity Undiscovered complexity

Fuzzer details

Fuzzer: fuzz_layout

Call tree

The calltree shows the control flow of the fuzzer. This is overlaid with coverage information to display how much of the potential code a fuzzer can reach is in fact covered at runtime. In the following there is a link to a detailed calltree visualisation as well as a bitmap showing a high-level view of the calltree. For further information about these topics please see the glossary for full calltree and calltree overview

Call tree overview bitmap:

The distribution of callsites in terms of coloring is
Color Runtime hitcount Callsite count Percentage
red 0 1078 50.1%
gold [1:9] 0 0.0%
yellow [10:29] 0 0.0%
greenyellow [30:49] 0 0.0%
lawngreen 50+ 1070 49.8%
All colors 2148 100

Fuzz blockers

The following nodes represent call sites where fuzz blockers occur.

Amount of callsites blocked Calltree index Parent function Callsite Largest blocked function
110 1565 facebook::yoga::calculateLayoutImpl(facebook::yoga::Node*, float, float, facebook::yoga::Direction, facebook::yoga::SizingMode, facebook::yoga::SizingMode, float, float, bool, facebook::yoga::LayoutPassReason, facebook::yoga::LayoutData&, unsigned int, unsigned int) call site: 01565 _ZN8facebook4yoga12maxOrDefinedITkNSt3__114floating_pointEfTkNS2_14floating_pointEfEEDaT_T0_
91 1238 facebook::yoga::resolveFlexibleLength(facebook::yoga::Node*, facebook::yoga::FlexLine&, facebook::yoga::FlexDirection, facebook::yoga::FlexDirection, facebook::yoga::Direction, float, float, float, float, float, float, bool, facebook::yoga::SizingMode, bool, facebook::yoga::LayoutData&, unsigned int, unsigned int) call site: 01238 _ZN8facebook4yoga12maxOrDefinedITkNSt3__114floating_pointEfTkNS2_14floating_pointEfEEDaT_T0_
69 1881 facebook::yoga::layoutAbsoluteChild(facebook::yoga::Node const*, facebook::yoga::Node const*, facebook::yoga::Node*, float, float, facebook::yoga::SizingMode, facebook::yoga::Direction, facebook::yoga::LayoutData&, unsigned int, unsigned int) call site: 01881
66 978 facebook::yoga::StyleValuePool::getLength(facebook::yoga::StyleValueHandle) const call site: 00978 __assert_fail
56 1951 facebook::yoga::justifyAbsoluteChild(facebook::yoga::Node const*, facebook::yoga::Node*, facebook::yoga::Direction, facebook::yoga::FlexDirection, float) call site: 01951
49 2008 facebook::yoga::layoutAbsoluteChild(facebook::yoga::Node const*, facebook::yoga::Node const*, facebook::yoga::Node*, float, float, facebook::yoga::SizingMode, facebook::yoga::Direction, facebook::yoga::LayoutData&, unsigned int, unsigned int) call site: 02008 _ZN8facebook4yoga13to_underlyingITkNS0_11EnumerationENS0_4EdgeEEEDaT_
48 1046 facebook::yoga::Style::gap(facebook::yoga::Gutter) const call site: 01046 _ZN8facebook4yoga13to_underlyingITkNS0_11EnumerationENS0_4EdgeEEEDaT_
32 1483 facebook::yoga::calculateBaseline(facebook::yoga::Node const*) call site: 01483 _ZN8facebook4yoga12maxOrDefinedITkNSt3__114floating_pointEfTkNS2_14floating_pointEfEEDaT_T0_
26 559 facebook::yoga::Node::setLayoutMeasuredDimension(float, facebook::yoga::Dimension) call site: 00559 _ZN8facebook4yoga12maxOrDefinedITkNSt3__114floating_pointEfTkNS2_14floating_pointEfEEDaT_T0_
21 586 facebook::yoga::cleanupContentsNodesRecursively(facebook::yoga::Node*, bool) call site: 00586 YGNodeClone
20 1709 facebook::yoga::calculateLayoutImpl(facebook::yoga::Node*, float, float, facebook::yoga::Direction, facebook::yoga::SizingMode, facebook::yoga::SizingMode, float, float, bool, facebook::yoga::LayoutPassReason, facebook::yoga::LayoutData&, unsigned int, unsigned int) call site: 01709
19 956 facebook::yoga::resolveChildAlignment(facebook::yoga::Node const*, facebook::yoga::Node const*) call site: 00956 _ZN8facebook4yoga13to_underlyingITkNS0_11EnumerationENS0_4EdgeEEEDaT_

Runtime coverage analysis

Covered functions
292
Functions that are reachable but not covered
204
Reachable functions
773
Percentage of reachable functions covered
73.61%
NB: The sum of covered functions and functions that are reachable but not covered need not be equal to Reachable functions . This is because the reachability analysis is an approximation and thus at runtime some functions may be covered that are not included in the reachability analysis. This is a limitation of our static analysis capabilities.
Function name source code lines source lines hit percentage hit

Files reached

filename functions hit
/src/yoga/fuzz/FuzzLayout.cpp 3
/src/yoga/yoga/YGConfig.cpp 2
/src/yoga/yoga/debug/Log.cpp 5
/src/yoga/yoga/../yoga/config/Config.h 3
/src/yoga/yoga/../yoga/enums/Errata.h 2
/src/yoga/yoga/YGNode.cpp 8
/src/yoga/yoga/node/Node.cpp 32
/src/yoga/yoga/../yoga/numeric/FloatOptional.h 13
/src/yoga/yoga/../yoga/style/Style.h 80
/src/yoga/yoga/../yoga/style/StyleValueHandle.h 12
/src/yoga/yoga/../yoga/style/GridStyle.h 4
/src/yoga/yoga/../yoga/style/StyleValuePool.h 8
/src/yoga/yoga/../yoga/style/SmallValueBuffer.h 5
/src/yoga/yoga/../yoga/node/LayoutResults.h 17
/src/yoga/yoga/../yoga/style/StyleSizeLength.h 16
/src/yoga/yoga/debug/AssertFatal.cpp 3
/src/yoga/yoga/../yoga/enums/LogLevel.h 1
/src/yoga/yoga/config/Config.cpp 7
/src/yoga/yoga/../yoga/node/Node.h 38
/src/yoga/yoga/../yoga/event/event.h 18
/src/yoga/yoga/event/event.cpp 1
/src/yoga/yoga/YGNodeStyle.cpp 7
/src/yoga/yoga/../yoga/enums/FlexDirection.h 1
/src/yoga/yoga/../yoga/numeric/Comparison.h 9
/src/yoga/yoga/../yoga/enums/Gutter.h 1
/src/yoga/yoga/../yoga/style/StyleLength.h 11
/src/yoga/yoga/../yoga/enums/Direction.h 1
/src/yoga/yoga/algorithm/CalculateLayout.cpp 29
/src/yoga/yoga/../yoga/enums/YogaEnums.h 4
/src/yoga/yoga/../yoga/algorithm/FlexDirection.h 9
/src/yoga/yoga/algorithm/Cache.cpp 4
/src/yoga/yoga/algorithm/PixelGrid.cpp 2
/src/yoga/yoga/../yoga/algorithm/BoundAxis.h 3
/src/yoga/yoga/../yoga/algorithm/SizingMode.h 1
/src/yoga/yoga/../yoga/enums/MeasureMode.h 1
/src/yoga/yoga/../yoga/node/LayoutableChildren.h 15
/src/yoga/yoga/../yoga/algorithm/Align.h 4
/src/yoga/yoga/algorithm/FlexLine.cpp 1
/src/yoga/yoga/../yoga/algorithm/FlexLine.h 1
/src/yoga/yoga/algorithm/Baseline.cpp 2
/src/yoga/yoga/../yoga/algorithm/TrailingPosition.h 3
/src/yoga/yoga/algorithm/AbsoluteLayout.cpp 8

Fuzz engine guidance

This sections provides heuristics that can be used as input to a fuzz engine when running a given fuzz target. The current focus is on providing input that is usable by libFuzzer.

/src/yoga/fuzz/FuzzLayout.cpp

Dictionary

Use this with the libFuzzer -dict=DICT.file flag


Fuzzer function priority

Use one of these functions as input to libfuzzer with flag: -focus_function name

-focus_function=['facebook::yoga::calculateLayoutImpl(facebook::yoga::Node*, float, float, facebook::yoga::Direction, facebook::yoga::SizingMode, facebook::yoga::SizingMode, float, float, bool, facebook::yoga::LayoutPassReason, facebook::yoga::LayoutData&, unsigned int, unsigned int)', 'facebook::yoga::resolveFlexibleLength(facebook::yoga::Node*, facebook::yoga::FlexLine&, facebook::yoga::FlexDirection, facebook::yoga::FlexDirection, facebook::yoga::Direction, float, float, float, float, float, float, bool, facebook::yoga::SizingMode, bool, facebook::yoga::LayoutData&, unsigned int, unsigned int)', 'facebook::yoga::layoutAbsoluteChild(facebook::yoga::Node const*, facebook::yoga::Node const*, facebook::yoga::Node*, float, float, facebook::yoga::SizingMode, facebook::yoga::Direction, facebook::yoga::LayoutData&, unsigned int, unsigned int)', 'facebook::yoga::StyleValuePool::getLength(facebook::yoga::StyleValueHandle) const', 'facebook::yoga::justifyAbsoluteChild(facebook::yoga::Node const*, facebook::yoga::Node*, facebook::yoga::Direction, facebook::yoga::FlexDirection, float)', 'facebook::yoga::layoutAbsoluteChild(facebook::yoga::Node const*, facebook::yoga::Node const*, facebook::yoga::Node*, float, float, facebook::yoga::SizingMode, facebook::yoga::Direction, facebook::yoga::LayoutData&, unsigned int, unsigned int)', 'facebook::yoga::Style::gap(facebook::yoga::Gutter) const', 'facebook::yoga::calculateBaseline(facebook::yoga::Node const*)', 'facebook::yoga::Node::setLayoutMeasuredDimension(float, facebook::yoga::Dimension)', 'facebook::yoga::cleanupContentsNodesRecursively(facebook::yoga::Node*, bool)']

Files and Directories in report

This section shows which files and directories are considered in this report. The main reason for showing this is fuzz introspector may include more code in the reasoning than is desired. This section helps identify if too many files/directories are included, e.g. third party code, which may be irrelevant for the threat model. In the event too much is included, fuzz introspector supports a configuration file that can exclude data from the report. See the following link for more information on how to create a config file: link

Files in report

Source file Reached by Covered by
[] []
/src/yoga/yoga/../yoga/enums/NodeType.h [] []
/src/yoga/yoga/../yoga/node/LayoutResults.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/LogLevel.h ['fuzz_layout'] []
/src/yoga/yoga/YGNodeStyle.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/style/GridStyle.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/YogaEnums.h ['fuzz_layout'] []
/usr/local/bin/../include/c++/v1/__exception/exception.h [] []
/src/yoga/yoga/../yoga/enums/Errata.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/BoxSizing.h [] []
/src/yoga/yoga/../yoga/enums/Justify.h [] []
/src/yoga/yoga/config/Config.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/event/event.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/style/StyleValuePool.h ['fuzz_layout'] []
/src/yoga/yoga/YGNode.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/style/StyleValueHandle.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/algorithm/TrailingPosition.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/style/GridLine.h [] []
/src/yoga/yoga/../yoga/enums/MeasureMode.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/PositionType.h [] []
/src/yoga/yoga/../yoga/style/SmallValueBuffer.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/numeric/FloatOptional.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/Direction.h ['fuzz_layout'] []
/src/yoga/yoga/node/Node.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/algorithm/Align.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/numeric/Comparison.h ['fuzz_layout'] []
/src/yoga/yoga/algorithm/PixelGrid.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/algorithm/FlexLine.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/algorithm/Baseline.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/style/StyleLength.h ['fuzz_layout'] []
/src/yoga/yoga/YGConfig.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/enums/Unit.h [] []
/src/yoga/yoga/../yoga/node/Node.h ['fuzz_layout'] []
/src/yoga/yoga/algorithm/CalculateLayout.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/style/Style.h ['fuzz_layout'] []
/usr/local/bin/../include/c++/v1/__iterator/move_iterator.h [] []
/src/yoga/yoga/../yoga/enums/Wrap.h [] []
/src/yoga/yoga/debug/Log.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/enums/Gutter.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/algorithm/FlexDirection.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/algorithm/SizingMode.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/Overflow.h [] []
/src/yoga/yoga/algorithm/AbsoluteLayout.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/algorithm/FlexLine.h ['fuzz_layout'] []
/src/yoga/yoga/event/event.cpp ['fuzz_layout'] ['fuzz_layout']
/usr/local/bin/../include/c++/v1/stdexcept [] []
/src/yoga/yoga/../yoga/style/GridTrack.h [] []
/src/yoga/fuzz/FuzzLayout.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/config/Config.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/style/StyleSizeLength.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/Align.h [] []
/src/yoga/yoga/../yoga/enums/FlexDirection.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/algorithm/BoundAxis.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/Display.h [] []
/src/yoga/yoga/algorithm/Cache.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/debug/AssertFatal.cpp ['fuzz_layout'] ['fuzz_layout']
/src/yoga/yoga/../yoga/node/LayoutableChildren.h ['fuzz_layout'] []
/src/yoga/yoga/../yoga/enums/Edge.h [] []
/src/yoga/yoga/../yoga/enums/ExperimentalFeature.h [] []

Directories in report

Directory
/src/yoga/yoga/
/src/yoga/fuzz/
/src/yoga/yoga/../yoga/numeric/
/src/yoga/yoga/config/
/src/yoga/yoga/node/
/src/yoga/yoga/../yoga/style/
/src/yoga/yoga/../yoga/event/
/src/yoga/yoga/../yoga/algorithm/
/usr/local/bin/../include/c++/v1/__exception/
/src/yoga/yoga/algorithm/
/usr/local/bin/../include/c++/v1/
/src/yoga/yoga/../yoga/enums/
/usr/local/bin/../include/c++/v1/__iterator/
/src/yoga/yoga/event/
/src/yoga/yoga/../yoga/node/
/src/yoga/yoga/../yoga/config/
/src/yoga/yoga/debug/