Add a stack_bounds function to the Runtime trait

This allows inspection of the current task's bounds regardless of what the
underlying task is.

Closes #11293