Recently I read some go source code and when I read the noescape function 
in runtime/stubs.go, I have a doubt about it.

// noescape hides a pointer from escape analysis.  noescape is
// the identity function but escape analysis doesn't think the
// output depends on the input.  noescape is inlined and currently
// compiles down to zero instructions.
func noescape(p unsafe.Pointer) unsafe.Pointer {
   x := uintptr(p)
   return unsafe.Pointer(x ^ 0)

I don't know what's the purpose of the exclusive or operation? Does it 

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 

Reply via email to