goloader
goloader copied to clipboard
Errors on Go 1.11
As you probably saw in the Travis builds, something isn't quite right when using Goloader with Go 1.11. Here is the output of running the 'base' example with the example loader:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
unknown gcobj:
Load error: offset overflow sym: runtime.writeBarrier
{1 2}
{1 2} &{1 2} {1 0} {0 0}
main.Vertex{X:1, Y:2} &main.Vertex{X:1, Y:2} main.Vertex{X:1, Y:0} main.Vertex{X:0, Y:0}
print &{1 2}
[John Paul George Ringo]
[{2 true} {3 false}]
map[Bell Labs:{40 -74} Google:{37 -122}]
Don't know type string
I'm a bool
runtime stack:
runtime.Stack.func1()
/home/travis/.gimme/versions/go1.11.2.linux.amd64/src/runtime/mprof.go:798 +0xdd
goroutine 1 [running]:
runtime.systemstack_switch()
/home/travis/.gimme/versions/go1.11.2.linux.amd64/src/runtime/asm_amd64.s:311 fp=0xc000381528 sp=0xc000381520 pc=0x4560e0
runtime.Stack(0xc0000e8400, 0x400, 0x400, 0xc0000e8400, 0x400)
/home/travis/.gimme/versions/go1.11.2.linux.amd64/src/runtime/mprof.go:790 +0xec fp=0xc000381598 sp=0xc000381528 pc=0x42746c
<autogenerated>(...)
/home/travis/gopath/src/github.com/dearplain/goloader/examples/base/base.go:115
fatal error: index out of range
panic during panic
runtime stack:
runtime.Stack.func1()
/home/travis/.gimme/versions/go1.11.2.linux.amd64/src/runtime/mprof.go:798 +0xdd
I'm posting the log from the Travis build because I'm on mobile atm, but I have tried it on my own box with Go 1.11 on Windows and gotten exactly the same result.
I'm really curious as to why goloader breaks in Go 1.11, as the moduledata struct shouldn't have been modified...
@dearplain do you have any plans on updating this package?
@dobegor No. Unfortunately, I don't have time to maintain this project.
It is probably related to the change: https://github.com/golang/go/commit/9f95c9db23d9e137bc30c206b67b58cc325a8c7e#diff-13e58c7b55d786f6adf3ea94bad47ccd
@capnspacehook I try to fix the error, push a commit https://github.com/pkujhd/goloader/commit/6a48a780e1c095a23ae8ea1549fcd10c3d9280b7, but only test on Linux
有没有高手继续修正支持1.13的?
可以用go自带的plugin模式替代吗
可以用go自带的plugin模式替代吗
可以,但是自带的plugin无法unload,如果加载很多不同的.so的话,会导致内存增加过多
有没有高手继续修正支持1.13的?
i already fix bugs on golang1.13, always only test on Linux. you can checout it https://github.com/pkujhd/goloader
有没有高手继续修正支持1.13的?
i already fix bugs on golang1.13, always only test on Linux. you can checout it https://github.com/pkujhd/goloader
thanks very much! 高手啊
有没有高手继续修正支持1.13的?
i already fix bugs on golang1.13, always only test on Linux. you can checout it https://github.com/pkujhd/goloader
@dearplain Would you consider archiving this repository and redirecting to https://github.com/pkujhd/goloader, who seems to have taken over maintenance of this project?
I nearly overlooked the fact that this up-to-date fork exists!
@pkujhd Thanks for doing this. 🙂
有没有高手继续修正支持1.13的?
i already fix bugs on golang1.13, always only test on Linux. you can checout it https://github.com/pkujhd/goloader
@dearplain Would you consider archiving this repository and redirecting to https://github.com/pkujhd/goloader, who seems to have taken over maintenance of this project?
I nearly overlooked the fact that this up-to-date fork exists!
@pkujhd Thanks for doing this. 🙂
@lthibault With pleasure I have fixed some bugs on golang 1.11, and release tag 0.0.3, you should update it