S&P 500 ends up slightly, tech-related shares underperform value