No, you cannot safely perform stackwalks in native code. That's only possible in managed code, it provides stack frame layout guarantees. Required by the garbage collector and CAS checks. C compilers have optimizers that remove such guarantees. They can because the language doesn't support nor require stackwalks.
Even if you de-tune the optimizer, you'll still have the significant obstacle of walking through the stack frames of the pinvoke marshaller and mapping a guessed address of just-in-time generated machine code to an assembly. Only the CLR knows how to do that. You cannot make this work.