Does this issue reproduce with the latest release?
As I tested with 1.14.15 and 1.15.13, in 1.15 there was the exact same issue but in 1.14 it was less visible
What operating system and processor architecture are you using (go env)?
Windows 10 Pro 64bit (version 21H1)
Also code checked on Ubuntu 20.04 btw
go env Output
$ go env
set GOROOT=C:\Program Files\Go
set GOTOOLDIR=C:\Program Files\Go\pkg\tool\windows_amd64
set CGO_CFLAGS=-g -O2
set CGO_CXXFLAGS=-g -O2
set CGO_FFLAGS=-g -O2
set CGO_LDFLAGS=-g -O2
set GOGCCFLAGS=-m64 -mthreads -fmessage-length=0 -fdebug-prefix-map=C:\Users\mrali\AppData\Local\Temp\go-build3682471824=/tmp/go-build -gno-record-gcc-switches
I expected 0 ram usage because it was useless at that moment and function was closed,
Also, yes I can accept the first ~60 MiB Ram usage, but the second time I don't think could be normal
What did you see instead?
The first time used ~60 MiB ram even function was closed and I didn't use that image,
The second time it used ~60 MiB more ram, And Third, Fourth, ... time had the same usage as the second time.
What you want now?
I am a newbie Go developer, so I don't know a lot of things...
If there is a way to fix my code, please suggest to I use it, I have more than 1GB Ram usage only because of this.
In my opinion, it would be cool if something like .Close() to force removing the whole image from memory be added in the next updates, or... I don't know...
Thanks for reading and helps.
The text was updated successfully, but these errors were encountered: