Simultaneous wireless information and power transfer (SWIPT) has been advocated as a highly promising technology for enhancing the capabilities of 5G and 6G devices. However, the challenge of dealing with large propagation path loss poses a significant hurdle. To address this issue, massive multiple-input multiple-output (MIMO) is employed to enhance the efficiency of SWIPT in cellular-based networks with multiple small cells, and especially increase the energy for cell-edge users. In addition, by leveraging a large set of spatially distributed base stations to collaboratively serve SWIPT-enabled user equipment, the cell-free massive MIMO has the potential to provide even better performance than the conventional small-cell systems. In this work, we extend the investigation to include the application of SWIPT technology with alternating current (AC) logic in the cell-free networks and the small-cell networks and propose joint beamforming and power splitting optimization frameworks to maximize the system sum-rate, subject to the constraints on harvested energy, AC logic energy supply, and total transmit power. The optimization problem is shown to be non-convex, posing a significant challenge. To address this challenge, we resort to a two-stage decomposition approach. Specifically, we first introduce quadratic transform-based fractional programming (FP) algorithms to iteratively solve the non-convex optimization problems in the first stage, achieving near-optimal solutions with low time complexities. To further reduce the complexities, we also incorporate conventional schemes such as zero forcing, maximum ratio transmission, and signal-to-leakage-and-noise ratio for the design of beamforming vectors. Second, to determine the optimal power splitting ratio within the framework, we develop a one-dimensional (1-D) search algorithm to tackle the single variable optimization problem reduced in the second stage. These algorithms are then evaluated in the context of cell-free MIMO and small-cell networks with numerical experiments. The results show that the FP-based algorithms can consistently outperform those utilizing the conventional beamforming schemes, and the solutions of this work can achieve up to fivefold improvement in the system sum-rate than the small-cell counterpart while providing different but comparable performance trends in energy harvesting (EH).