Constraining the formation processes of small solar system bodies is crucial for gaining insights into planetesimal formation. Their bulk densities, determined by their compressive strengths, offer valuable information about their formation history. In this paper, we utilize a formulation of the compressive strength of dust aggregates obtained from dust N-body simulations to establish the relation between the bulk density and diameter. We find that this relation can be effectively approximated by a polytrope with an index of 0.5, coupled with a formulation of the compressive strength of dust aggregates. The lowest-density trans-Neptunian objects (TNOs) and main-belt asteroids (MBAs) are well reproduced by dust aggregates composed of 0.1 μm sized grains. However, most TNOs, MBAs, comets, and near-Earth asteroids (NEAs) exhibit higher densities, suggesting the influence of compaction mechanisms such as collision, dust grain disruption, sintering, or melting, leading to further growth. We speculate that there are two potential formation paths for small solar system bodies. One involves the direct coagulation of primordial dust grains, resulting in the formation of first-generation planetesimals, including the lowest-density TNOs, MBAs, and the parent bodies of comets and NEAs. In this case, comets and NEAs are fragments or rubble piles of first-generation planetesimals, and the objects themselves or the rubble are composed of 0.1 μm sized grains. The other path involves the further potential fragmentation of first-generation planetesimals into the compact dust aggregates observed in protoplanetary disks, resulting in the formation of second-generation planetesimals composed of compact dust aggregates, which may contribute to explaining another formation process of comets and NEAs.