Given a provided block of SQL code, identify performance bottlenecks and tune the queries to run efficiently under high data volumes.