I think you need to put it in the global namespace (or at least that is a feasible workaround):
import torch
import torch.utils.cpp_extension

cpp_source = """
#include <torch/extension.h>

torch::Tensor base_forward(torch::Tensor x, torch::Tensor w, torch::Tensor b){
    auto o = w * x + b;
    return o;
}

PYBIND11_MODULE(TORCH_EXTENSION_NAME, m){
    m.def("forward", &base_forward, "BASE forward");
}
"""

import torch
import torch.nn as nn

base_cpp = torch.utils.cpp_extension.load_inline("base_cpp", cpp_source)

from torch.fx import Tracer

base_cpp_forward = base_cpp.forward
torch.fx.wrap('base_cpp_forward')

class M(nn.Module):
    def __init__(self):
        super().__init__()
        self.conv = nn.Conv2d(1, 1, 1)

    def forward(self, x):
        x = self.conv(x)
        out = base_cpp_forward(x, torch.randn(1), torch.randn(1))
        return out

module = M()

traced = torch.fx.symbolic_trace(module)
print (traced.code)

P.S.: Kudos for posting code, but it seems to have a lot of small typos.