The psalmist speaks of the good things God has done as though they were put together as a high building or a mountain. (See: [[rc://en/ta/man/translate/figs-metaphor]])
"The depths of the earth" here is a metaphor for where people go when they die. The psalmist had not already died, but in this exaggeration he speaks as if he had. AT: "when we are near death" (See: [[rc://en/ta/man/translate/figs-metaphor]] and [[rc://en/ta/man/translate/figs-hyperbole]])