The optical properties of porous Si (p-Si) are compared to those of siloxene and its derivatives in order to gain more insight into the mechanism of the luminescence observed in p-Si. We report new results of photoluminescence (PL), photoluminescence excitation (PLE), time-dependent and pressure-dependent photoluminescence, and optically detected magnetic resonance (ODMR). Important information about the structural, electronic, and microscopic nature of the two classes of materials are deduced from these experiments. Annealed siloxene and p-Si show very similar properties, suggesting that siloxene-related structures, e.g. electrically isolated Si6-rings, might be responsible for the luminescence in p-Si. The Si-planes in as-prepared siloxene, with their green luminescence, are metastable and are readily oxidized into red-luminescent siloxene configurations.