If I haven't made any mistakes then your code appears equivalent to this simplified version
b = 0.9999998593355306`;
?1 = 0; ?2 = 2 Pi; n? = 40; step? = (?2-?1)/n?;
kt[n_] = n*7.729837371051386*^14;
g[t_, n_, w_, ?_, ?_] = << "C:/Desktop/gt.m";
f1[n1_, w1_] := (pw=Table[
If[w1 < kt[n1]/(1+b) || w1 > kt[n1]/(1-b),
cn = dn = 0,
(*else*)
?m = ?1 + (k-1) step?; ?1 = ArcCos[(1-kt[n1]/w1)/b];
cn = 1.2302418268992892`*^14* NIntegrate[g[t, n1, w1, ?m, ?1], {t,0,8.12848318220823`*^-15}, WorkingPrecision->5];
dn = Abs[cn.cn] - Abs[{Sin[?1] Cos[?m], Sin[?1] Sin[?m], Cos[?1]}.cn]^2;
If[dn<=1, 1.4399610959418586`*^-17/(2*Pi*0.000059156065864457335`)*Abs[dn]*8*w1/b, 0]
],
{k, 1, n?+1}
];
step?*(Total[pw]-1/2(pw[[1]]+pw[[n?+1]]))
);
data = Table[{w, Sum[f1[n,w], {n,1,1}]}, {w, 3.86491895735408`*^14, 2.747615443937921`*^22, 2.7476154052887314`*^20}] // AbsoluteTiming
All the computation time is spent evaluating the f1 function which produces the Total of the Table pw.
For each entry in your pw Table, if the parameters are out of range then cn, dn and the entry in your Table are zero, but cn and dn are not actually used in this case.
If the parameters are in range then cn is found from NIntegrate of your 2200 kilobyte interpolating function g, dn is found from cn and the entry in your Table is found from dn.
You do 41 iterations to construct that Table and each iteration is independent of all the other iterations. Thus if you replace that Table with ParallelTable and you ensure that all the parameters and your g interpolating function are available for each iteration of the ParallelTable and you have a license which allows multiple parallel cores and you have a processor with multiple cores and you have sufficient memory to support multiple parallel cores then you might be able to speed up your code.
Please check all this very carefully to make certain that I have not made any mistakes