The process of seafloor spreading is driven by convection currents in the Earth's mantle. The heat from the Earth's core causes the mantle to rise, and as it rises, it melts to form magma. The magma then rises to the surface of the Earth and erupts to form new crust. At the East Pacific Rise, the magma erupts to form the Mid-Ocean Ridge.
The process of subduction occurs when one tectonic plate moves under another tectonic plate. The plate that is being subducted sinks into the mantle and is recycled into the Earth's interior. At the Peru-Chile Trench, the Nazca Plate is being subducted under the South American Plate.
The growth of the Pacific Ocean basin is a long-term process that has been going on for millions of years. It is one of the reasons why the Pacific Ocean is the largest ocean on Earth.