Hi, is there a way to create a giant consolidated c++ code without each AOT context having their own code (starting with # AOT ID: )? This is for running on only CPU. My code is as below.
from torch._inductor.utils import run_and_get_cpp_code
t = torch.compile(model, backend="inductor")
result, code = run_and_get_cpp_code(t, input_data)
logger.debug(f"result: {result}")
logger.debug(f"code: {code}")
And some version information:
Python 3.9.21 (main, Dec 11 2024, 16:24:11)
[GCC 11.2.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> torch.__version__
'2.5.1+cu124'
If I am doing something wrong, please fix me. Any guidance would be appreciated.
Thank you