[ATen] Exclude CUDA tests when running `basic` under valgrind (#34181)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/34181
Test Plan: CI
Reviewed By: orionr, seemethere
Differential Revision: D20241021
fbshipit-source-id: a7371afc45acc2c07a36c8216036338e14170a56