Hi,
I’m not sure to understand your goal?
You want to benchmark the runtime of a single op ?
If so, you can do:
base = torch.rand(10, requires_grad=True)
a = base + 1 # The backward of this is an identity so as fast as it can get

a *= b

a.backward(a)

But note that you’re mostly going to measure the overhead of the autograd here.
You can use the autograd profiler though to get a more precise idea without the autograd overhead.