demR = Compile[{{p1, _Real, 0}}, Min[100 p1, 2500],
Parallelization -> True, RuntimeAttributes -> {Listable}];
t = With[{demR = demR},
Compile[{},
Module[{k2}, k2 = RandomReal[10, {10}]; demR[#] & /@ k2],
Parallelization -> True, RuntimeAttributes -> {Listable},
CompilationOptions -> {"InlineCompiledFunctions" -> True}]
]; CompilePrint[t]