SIGN IN SIGN UP

Add per-operator headers to XPU sources (#194688)

AT_PER_OPERATOR_HEADERS was already configured for XPU in cmake/Codegen.cmake
but never actually linked in, so native/mkldnn/xpu always compiled with the
full ATen umbrella headers. This links it in and fixes the fallout (a few
missing includes, a few files pulling in `<ATen/ATen.h>` unconditionally).

Drafted with AI assistance (Claude Code); reviewed and tested by me before
opening.

Pull Request resolved: https://github.com/pytorch/pytorch/pull/194688
Approved by: https://github.com/guangyey, https://github.com/Skylion007
Y
Yuanyuan Chen committed
915f357159e2a4ea15b9476ebe1c87fa6207f567
Parent: c51a5fa
Committed by PyTorch MergeBot <pytorchmergebot@users.noreply.github.com> on 8/25/2026, 11:18:14 PM