1. 6
  1.  

  2. 4

    I’ve used this technique with Java, using jstack. Also ^\ helps. I’ve written a bit more about the sad state of Java tooling, partly with an eye to figuring out how to improve it.