Re: [go-nuts] How to run a go method on multiple cores ?

2019-05-08 Thread Kurtis Rader
On Wed, May 8, 2019 at 10:17 PM Nitish Saboo wrote: > Yes, I want (exactly) two instances of syslog-ng engines running since I > initialised the engine twice.And I guess it is possible only when the > syslog-ng engines are running on two different processors.I might be wrong > here, please

Re: [go-nuts] How to run a go method on multiple cores ?

2019-05-08 Thread Nitish Saboo
Hi Michael, Yes, I want (exactly) two instances of syslog-ng engines running since I initialised the engine twice.And I guess it is possible only when the syslog-ng engines are running on two different processors.I might be wrong here, please correct me if my understanding is not right. My goal

Re: [go-nuts] Re: A question about A sync.Once implementation.

2019-05-08 Thread White Pure
Hi, You are right, I did some modification to your code and make it able to reproduce everytime: https://play.golang.org/p/y6vxC_DNjp9 Thanks! 在 2019年5月8日星期三 UTC+8下午7:15:26,rog写道: > > It seems clear to me that C ("can run but has not implemented the > singleton pattern, function f may

Re: [go-nuts] Could someone tell me how to build gollvm?

2019-05-08 Thread Yuan Ting
Oh, my mistake. I can successfully build gollvm now, thank you so much! On Thursday, May 9, 2019 at 11:07:37 AM UTC+8, Than McIntosh wrote: > > There was a recent checkin related to -fdebug-go-optimization in both > repos-- I think the failure you're seeing is just build skew. > Try doing a "git

Re: [go-nuts] Could someone tell me how to build gollvm?

2019-05-08 Thread 'Than McIntosh' via golang-nuts
There was a recent checkin related to -fdebug-go-optimization in both repos-- I think the failure you're seeing is just build skew. Try doing a "git pull" in llvm/tools/gollvm and llvm/tools/gollvm/gofrontend to make sure everything is up to date. Thanks, Than *From: *Ting Yuan *Date: *Wed, May

[go-nuts] Type safe and modularize way to generate html on server side.

2019-05-08 Thread Felix Sun
https://github.com/theplant/htmlgo A few benefits with this approach than html/template - Compiled type safe - Fast as go itself - Not possible to generate unmatched html tags - No need to manage template files, and caring about it's path etc - Easier to modularize, any component can be purely

Re: [go-nuts] Could someone tell me how to build gollvm?

2019-05-08 Thread Ting Yuan
Hi Than, It turned out to be the problem of shell. By SHELL=/bin/sh I can build gollvm in the right way, but I still failed on a compile error: [2066/3237] Building CXX object tools/gollvm/bridge/CMakeFiles/ LLVMCppGoFrontEnd.dir/__/gofrontend/go/go.cc.o FAILED:

Re: [go-nuts] How to run a go method on multiple cores ?

2019-05-08 Thread Michael Jones
Can you share a little more of your motivation for saying: “I want two instances of syslog-ng engine running on two different processors.” Do you mean (minimum) that you want two independent instances, or (maximum) that you want to prove that there are two instances, two physical processors, and

Re: [go-nuts] Re: Does fmt.Fprint use WriteString ?

2019-05-08 Thread Marvin Renich
[Sorry for the late reply; I was having technical difficulties!] * Louki Sumirniy [190503 10:39]: > A lot of people clearly don't know this, also - there is a builtin print() > and println() function in Go. If the output is stdout, these are probably > the most efficient ways to thow strings

Re: [go-nuts] Could someone tell me how to build gollvm?

2019-05-08 Thread 'Than McIntosh' via golang-nuts
Agree, the embedded space looks fishy. I also note that your shell is set to zsh -- you might try instead using SHELL=/bin/sh to see if that works better. Thanks, Than On Wed, May 8, 2019 at 12:04 PM Ting Yuan wrote: > OK, I got something like > ... >

Re: [go-nuts] Could someone tell me how to build gollvm?

2019-05-08 Thread Ting Yuan
OK, I got something like ... /home/yt/LLVMsvn/llvm/tools/gollvm/gotools/CMakeLists.txt(55): if(NOT EXISTS /home/yt/LLVMsvn/llvm/tools/gollvm/gofrontend/libgo/go/cmd/buildid ) /home/yt/LLVMsvn/llvm/tools/gollvm/gotools/CMakeLists.txt(57): else()

Re: [go-nuts] Could someone tell me how to build gollvm?

2019-05-08 Thread 'Than McIntosh' via golang-nuts
Hmm, OK, sounds like 'sed' is not the issue. >>I found there are only two files (CMakeLists.txt and gotestprogram.sh) under the llvm/tools/gollvm/gotools/. Should the missing files (e.g. buildid.go) be there? No, this is expected. The Go sources for 'buildid' will be pulled from

Re: [go-nuts] Change in virtual memory patterns in Go 1.12

2019-05-08 Thread 'Michael Knyszek' via golang-nuts
I'm glad to hear it! What went into Go 1.12.5 should supersede that patch anyway. On Wed, May 8, 2019 at 3:48 AM Rémy Oudompheng wrote: > Hello, > > I didn't have time to try the patch, but as Go 1.12.5 is out with another > fix, I can confirm with high certainty that the problem is now gone,

Re: [go-nuts] Could someone tell me how to build gollvm?

2019-05-08 Thread Ting Yuan
Hi Than, On my system the version of sed is 4.4. Is the version mismatch? I found there are only two files (CMakeLists.txt and gotestprogram.sh) under the llvm/tools/gollvm/gotools/. Should the missing files (e.g. buildid.go) be there? Thanks. On Wednesday, May 8, 2019 at 8:50:23 PM UTC+8,

[go-nuts] Re: the Dominance of English in Programming Languages

2019-05-08 Thread K.S. Bhaskar
For historical reasons, languages and activities tend to be associated. Is the need for programmers to know relevant English technical terms any different from opera singers needing to know relevant Italian technical terms or fencers needing to know relevant French technical terms? Regards –

Re: [go-nuts] Could someone tell me how to build gollvm?

2019-05-08 Thread 'Than McIntosh' via golang-nuts
Hi, >From the error output it sounds like something went wrong with the initial cmake run -- the error from match.sh seems nonsensical (it suggests that the script is looking for gotools sources in the wrong location). One possibility would be that you don't have "sed" installed on your system?

Re: [go-nuts] How many Go compilers are out there?

2019-05-08 Thread Harald Weidner
Hello, On Thu, Apr 25, 2019 at 08:54:57AM -0700, Ian Lance Taylor wrote: > On Thu, Apr 25, 2019 at 8:29 AM JuciÊ Andrade wrote: > > > > These are the ones I am aware of: > > > > . GC toolchain > > . GCC > > . gopherjs > > > > By Go compiler I mean any tool that understands Go source files and >

Re: [go-nuts] Re: A question about A sync.Once implementation.

2019-05-08 Thread roger peppe
It seems clear to me that C ("can run but has not implemented the singleton pattern, function f may run multi times") is not the correct answer, because I'm pretty sure that f cannot run more than once. However, it's still not a correct Once implementation, because as has already been pointed

[go-nuts] Re: How many Go compilers are out there?

2019-05-08 Thread JuciÊ Andrade
One of the reasons I like Go is the very professional approach to its development. Work is well done since the inception. Having a language specification appears to be a simple matter, yet many other languages doesn't have such document. It turns out that this very artefact is essential for

Re: [go-nuts] How to run a go method on multiple cores ?

2019-05-08 Thread Nitish Saboo
Hi Marvin, Thanks for your response. "Do you mean "log/syslog" from the standard library? What does initialize do?" >>I have installed syslog-ng parser on my Linux box and I am planning you use syslog-ng parser and wanted to initialise it's engine for parsing the data. so initialise() method

Re: [go-nuts] How to detect source of a dependency in go.mod

2019-05-08 Thread Dan Kortschak
Try github.com/sirupsen/logrus@v1.4.1 At some point the capitalisation was changed. On Tue, 2019-05-07 at 19:16 -0700, tamal wrote: > I am trying to convert https://github.com/appscode/voyager from glide > to go  > mod. > > I am getting an error like below: > ``` > go:

Re: [go-nuts] Change in virtual memory patterns in Go 1.12

2019-05-08 Thread Rémy Oudompheng
Hello, I didn't have time to try the patch, but as Go 1.12.5 is out with another fix, I can confirm with high certainty that the problem is now gone, and I am pretty much confident that the situation is even better than Go 1.11, which is consistent with the fact that the bug was already there,

[go-nuts] Re: Need help to make autocert working

2019-05-08 Thread 'alex' via golang-nuts
> This site can’t be reached > site took too long to respond. Where is this coming from, some kind of a client? > How come the autocert TLS handshake trying to connect my home IP address autocert doesn't connect anywhere except the ACME directory, Let's Encrypt being most common I guess. Most

Re: [go-nuts] How to run a go method on multiple cores ?

2019-05-08 Thread Nitish Saboo
Hi Marvin, Thanks for your response. "Do you mean "log/syslog" from the standard library? What does initialize do?" >>I have installed syslog-ng parser on my Linux box and I am planning you use syslog-ng parser and wanted to initialise it's engine for parsing the data. so initialise() method