Re: Please , can we stop spams?
I'm not saying that having a GitHub account should be a _requirement_ for joining, but it could be a part of the "business logic" for new account validation. It's very easy to implement. If you're an established Nim developer, the forum rolls out a red carpet. If you're not, your first X posts are hidden until a moderator validates them. Or something like that. Linking forum profiles to GitHub is a good idea for a number of other reasons as well: keeping track of who is who, who wrote what, etc.
Re: Please , can we stop spams?
The admins have to set some rules about posting.
Re: Please , can we stop spams?
I agree that requiring a GitHub account will do more harm than good. It may be worth hooking in to the StopForumSpam API which would help block bots (but not much help for humans). Realistically, human spam is very difficult to combat without impacting the user experience for legitimate users.
Nim with gcc 5.4 SIMD auto-vectorization
Yesterday I did a very short test. Generally SIMD (Single instruction, multiple data) may work best with 16 byte aligned data and restrict modifier to indicate non overlapping data. But even without there is some SIMD available in Nim indeed. First we make gcc output visible with &> output redirection and enable vectorization: cat nim.cfg path:"$projectdir" nimcache:"/tmp/$projectdir" gcc.options.speed = "-save-temps -pipe -march=native -O3 -ftree-vectorize -fopt-info-vec -fno-strict-aliasing &> gcc.log" We may also specify "-fopt-info-vec-missed" to see where vectorization failed, but that will generate much noise for all the libs. "-march=native" is used to ensure optimization for current CPU, and "-save-temps" outputs assembler listings. Test with import random proc test = var a: array[128, int] for i in 0 .. random(128): a[i] = i echo a[7] test() cat gcc.log gcc: warning: -pipe ignored because -save-temps specified /tmp//home/stefan/simd/simd.c:59:8: note: loop vectorized cat simd.s callrandom_99297_4293377359 testq %rax, %rax js .L13 leaq-3(%rax), %rcx leaq1(%rax), %rdi shrq$2, %rcx addq$1, %rcx cmpq$3, %rax leaq0(,%rcx,4), %rdx jle .L14 vmovdqa .LC1(%rip), %ymm0 xorl%esi, %esi vmovdqa .LC3(%rip), %ymm1 "vmovdqa" seems to be SIMD instructions. So even with a non fixed upper bound for the for loop it works. I don't know if there is any benefit in real life :)
Re: Sequence is unchangeable when passed to a spawned proc
Thank you for your posts. I think the behavior is a matter of the Nim compiler. aSeq is deepcopied into aSeqPar and aSeqPar behaves as if it is declared locally within workerTread as "let aSeqPar = aSeq". But I would prefer: "var aSeqPar = aSeq". Obviously there exists no suitable pragma too.
Re: Please , can we stop spams?
Having a GitHub account should not be required to participate in the community and I think it's harmful to make people with few original Nim code second-class citizens.
Re: Please , can we stop spams?
Another idea is GitHub integration. Make each new user authenticate with GitHub, scan his/her repos for original Nim code, assign reputation rank based on star count. 8)