Re: [go-nuts] How to check whether a variable is unreachable?

2021-09-22 Thread Cholerae Hu
Thanks, I see. How about this one? I use a temp variable to store sh.Data, sh/ds/data are all no longer mentioned at the point when unsafe.Slice is called. Do I need to use runtime.KeepAlive? package main import ( "fmt" "reflect" "runtime" "unsafe" ) var b []byte func f(data interface{}) { s

Re: [go-nuts] How to check whether a variable is unreachable?

2021-09-22 Thread Ian Lance Taylor
On Wed, Sep 22, 2021 at 1:22 AM Cholerae Hu wrote: > > https://play.golang.org/p/WJTH-lUukeb > > Do I need to uncomment line 23? IMHO, variable data and ds will not be used > after line 16, so they can be collected in runtime.GC. But running it with > gccheckmark=1 and clobberfree=1 doesn't show

[go-nuts] RFC7634 and go implementation of ChachaPoly AEAD

2021-09-22 Thread Deepak Dandekar
Hello, Not sure how to reach to the authors/contributors involved in ChaChaPoly implementation. So, sending this here. Please redirect as appopriate. I am implementing "GO" utility (using gopacket) for decrypting IPsec ESP tunnel packets that are encrypted using ChachPoly. For my testing, I use

Re: [go-nuts] gollvm for LLVM13

2021-09-22 Thread Khanh TN
I will try that. Thanks for your support! Khanh On Wednesday, September 22, 2021 at 10:21:41 PM UTC+8 th...@google.com wrote: > Hi, > > I've been in the process of updating gollvm to sync with the recently > submitted Go 1.17 changes in gofrontend. I just checked in a couple of CLs > that sho

Re: [go-nuts] What is the total max size of embed content?

2021-09-22 Thread Howard C. Shaw III
Before the addition of binary packaged assets into Go as a standard library feature, there were various tools to accomplish the same task. Some of them, such as https://github.com/GeertJohan/go.rice , could use an alternate embedding. Basically, instead of having the binary files packaged as Go

Re: [go-nuts] What is the total max size of embed content?

2021-09-22 Thread Tamás Gulácsi
Go back to the venerable SFX zip archives: Append the file as a (uncompressed?) ZIP file to the Go binary. That binary can then open itself as a ZIP and read/use the database, and every other program will see it as a zip file. Or just simply append the database and its uint64 size to the go bina

Re: [go-nuts] What is the total max size of embed content?

2021-09-22 Thread Amnon
A cloud DB looks like a great option here. The cost/complication would be trivial compared to the cost/complication fixing the tool chain to handle enormous executables, and of shipping these around. On Tuesday, 21 September 2021 at 20:41:42 UTC+1 glen@gmail.com wrote: > Hello Ian, > > Yes,

[go-nuts] Re: What is up with memo.com?

2021-09-22 Thread David Taylor
I've just been made aware of this, and we're looking into getting it fixed. I apologize for the unwanted emails — it should not be happening. Would anyone care to forward me what we're sending you if you have the chance? Dave On Tuesday, September 21, 2021 at 1:19:06 PM UTC-7 Brian Candler wr

Re: [go-nuts] gollvm for LLVM13

2021-09-22 Thread 'Than McIntosh' via golang-nuts
Hi, I've been in the process of updating gollvm to sync with the recently submitted Go 1.17 changes in gofrontend. I just checked in a couple of CLs that should help. Please sync your gollvm client ; if you build with 0f0479aa582cfa3bd9c17bd7d41d2e2bc9991958 for gollvm (plus tip of gofrontend and

[go-nuts] Re: Creating a MQTT library

2021-09-22 Thread jfcg...@gmail.com
Did you take a look at: https://github.com/eclipse/paho.mqtt.golang https://github.com/eclipse/paho.golang On Friday, September 17, 2021 at 12:17:14 AM UTC+3 yba...@gmail.com wrote: > Hello everyone, > > I am trying to design a new library to encode/decode MQTT messages. I > began the work, and

[go-nuts] How to check whether a variable is unreachable?

2021-09-22 Thread Cholerae Hu
https://play.golang.org/p/WJTH-lUukeb Do I need to uncomment line 23? IMHO, variable data and ds will not be used after line 16, so they can be collected in runtime.GC. But running it with gccheckmark=1 and clobberfree=1 doesn't show any problems. Are there any documents about the details or be

[go-nuts] Re: A team using Go won ISUCON10

2021-09-22 Thread mattn
Sorry. last list is wrong. 2011 ISUCON1 Perl 2012 ISUCON2 Perl 2013 ISUCON3 Perl 2014 ISUCON4 Perl 2015 ISUCON5 Perl 2016 ISUCON6 Go 2017 ISUCON7 Go 2018 ISUCON8 Go 2019 ISUCON9 Ruby 2020 ISUCON10 Go 2021 ISOCON11 Go 2021年9月22日水曜日 13:42:15 UTC+9 mattn: > As usual on the each years, in this year