Long Sleep Duration, Cognitive Performance, and the Moderating Role of Depression: A Cross-Sectional Analysis in the Framingham Heart Study. We investigated whether depression modified the associations between sleep duration and cognitive performance.