a defer call generate some code like: - - v42 (8) = StaticLECall <mem> {AuxCall{runtime.deferprocStack}} [8] v36 v41 - v43 (8) = SelectN <mem> [0] v42 - Defer v42 → b2 b3 (likely) (8)
- b2: ← b1- - - v48 (7) = Copy <mem> v43 - v49 (7) = VarKill <mem> {.autotmp_0} v48 - v50 (9) = StaticLECall <mem> {AuxCall{runtime.deferreturn}} v49 - v51 (9) = SelectN <mem> [0] v50 - v52 (9) = MakeResult <mem> v51 - Ret v52 (9) - b3: ← b1- - - v44 (8) = Copy <mem> v43 - v45 (8) = StaticLECall <mem> {AuxCall{runtime.deferreturn}} v44 - v46 (8) = SelectN <mem> [0] v45 - v47 (8) = MakeResult <mem> v46 - Ret v47 (8) my question is Under what circumstances the deferprocStack return 1? some useful info: https://github.com/golang/go/blob/master/src/cmd/compile/internal/amd64/ssa.go#L1287-L1289 https://github.com/golang/go/blob/master/src/runtime/panic.go#L290-L328, in these lines it seems deferprocStack always return 0. i think i have miss some thing, please help me to find when it get to branch return 1. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/4e6aaf04-f78e-42b1-9ac7-44652ac7f370n%40googlegroups.com.