Search found 2072 matches

by coderJeff
Sep 19, 2019 2:21
Forum: Tips and Tricks
Topic: Fastest PRNG around, the XORSHIFT
Replies: 34
Views: 1065

Re: Fastest PRNG around, the XORSHIFT

fbc will optimize (x^2) to (x*x). Interesting to know, does that also apply to gas, or is it gcc only? It is an fbc optimization. C doesn't have a power operator, only 'pow` function, so fbc makes this choice to optimize before the expression is even passed to gas/gcc backend. Is this a "best&...
by coderJeff
Sep 19, 2019 1:51
Forum: Documentation
Topic: Wiki improvements
Replies: 352
Views: 36611

Re: Wiki improvements

- Or to speak about the visibility of the procedures through the different modules? My guess is that Procedure Scopes title might be reserved for this concept. - private, visible within a module - public, visible within an executable - export, visible between executables But that's just a guess bec...
by coderJeff
Sep 17, 2019 11:08
Forum: Tips and Tricks
Topic: Fastest PRNG around, the XORSHIFT
Replies: 34
Views: 1065

Re: Fastest PRNG around, the XORSHIFT

Answer: the first method is faster, than the second (the result is the same). Careful with integers if the calculation might overflow the integer type. dim x as ulongint = 4000000000 dim y as ulongint = 3000000000 print sqr( x ^ 2 + y ^ 2 ) '' 5000000000 -- correct print sqr( x * x + y * y ) '' 255...
by coderJeff
Sep 15, 2019 20:00
Forum: Tips and Tricks
Topic: Fastest PRNG around, the XORSHIFT
Replies: 34
Views: 1065

Re: Fastest PRNG around, the XORSHIFT

Perhaps, compare to a single decimal digit: - minimum value = 0 - maximum value = 9 - number of possible values = 10 - expected probability of any digit = 1/10th rnd() function returns [0,1), i.e. 0.000... to 0.999..., but never 1.0. (The number of decimal places is limited by hardware, so no, it's ...
by coderJeff
Sep 15, 2019 14:34
Forum: Community Discussion
Topic: fb 1.07 tests
Replies: 51
Views: 4482

Re: fb 1.07 tests

I still want to remember that with FB1.5 that was correct. like this oder example Constructor Comobject (ByRef varSrc As Const VARIANT) Export vt = VT_EMPTY InternalCopy (@Cast (VARIANT,varSrc)) End Constructor I made a quick fix for this in Fix a cast(string, variable) issue that can cause fbc to ...
by coderJeff
Sep 15, 2019 14:28
Forum: Community Discussion
Topic: FreeBASIC 1.07 Release Discussion
Replies: 16
Views: 1441

Re: FreeBASIC 1.07 Release Discussion

The purpose for the fbc-1.07 branch is for alternate release packages only. I have no intention of fixing bugs on multiple branches. Development and bug fixing is on fbc/master branch only. I changed my mind. I set up separate development environments for fbc/master branch and fbc/fbc-1.07 branch a...
by coderJeff
Sep 14, 2019 15:27
Forum: Community Discussion
Topic: Anonymous Functions in FreeBASIC
Replies: 2
Views: 262

Re: Anonymous Functions in FreeBASIC

gcc as a backend compiler is utilized at very low level. gcc is more like a high level assembler for fbc than a translation target. fbc understands the source code concepts & constructs in it's own representation rather than only translating to equivalent features in gcc. In other words, if fbc ...
by coderJeff
Sep 14, 2019 14:31
Forum: Community Discussion
Topic: fb 1.07 tests
Replies: 51
Views: 4482

Re: fb 1.07 tests

fxm wrote:Maybe forgotten by the developers themselves!


Yes, It's true! I forget about peek & poke. Not since C64 & Atari days did I use peek & poke. Even in QB (TM) I preferred using ASM/C routines compiled in QLB/LIB routines rather than using peek & poke.
by coderJeff
Sep 12, 2019 23:09
Forum: Documentation
Topic: Wiki improvements
Replies: 352
Views: 36611

Re: Wiki improvements

fxm wrote:
fxm wrote:New complete sub-section added in the Programmer's Guide:

Multi-Threading

Wow! I've read the new topics. They are very good with a logical progression of topics and information. Wonderful work, fxm.
by coderJeff
Sep 12, 2019 22:43
Forum: Documentation
Topic: Wiki improvements
Replies: 352
Views: 36611

Re: Wiki improvements

@admin, About 6 months ago, I proposed to close this bug report (which I had created myself), but no reaction since? #807 'ScreenSet' ordering in main thread is ignored by user threads even created after that! There are several gfxlib2 and threading bugs which may or may not be related to each othe...
by coderJeff
Sep 12, 2019 13:29
Forum: Community Discussion
Topic: fb 1.07 tests
Replies: 51
Views: 4482

Re: fb 1.07 tests

pending an improvement or fixation or something else, it seems appropriate to point out this as a mistake Unfortunate that there was no test for this in our test suite, otherwise probably would have noticed this source code compatibility break. The CONST versus CAST issue has been an on-going sourc...
by coderJeff
Sep 10, 2019 22:13
Forum: Community Discussion
Topic: fb 1.07 tests
Replies: 51
Views: 4482

Re: fb 1.07 tests

When I try it, In windows, I get a "fbc.exe has stopped working" application crash message pop-up. So yes, fbc.exe has died unexpectedly, and the ASM file, any part of it that might already be written, remains. What IDE/tool are you using to compile? I'm surprised you didn't get any indica...
by coderJeff
Sep 10, 2019 1:18
Forum: Community Discussion
Topic: FreeBASIC 1.07 Release Discussion
Replies: 16
Views: 1441

Re: FreeBASIC 1.07 Release Discussion

I've been working on next 1.07.1 release. Here's why: The 1.07.0 release was a logical necessary step. Because of some compiler changes that are coming up, it felt necessary to create a fairly stable save point and release it before making those changes. This also provides an opportunity for a branc...
by coderJeff
Sep 10, 2019 0:51
Forum: Community Discussion
Topic: FreeBASIC 1.07 Release Discussion
Replies: 16
Views: 1441

Re: FreeBASIC 1.07 Release Discussion

Thanks paul. Well, if you haven't tried it yet, there's another one coming soon. :)
by coderJeff
Sep 08, 2019 16:53
Forum: Windows
Topic: new mingw toolchain (Equation tool chain)
Replies: 9
Views: 780

Re: new mingw toolchain (Equation tool chain)

I'm glad you posted again, and I hope you continue to do so. At least you made the attempt, and I respect your courage for sharing the result. And that's important to recognize; that we have a result, and new information is learned. So, I hope you stay interested. I'm no expert. I've just been at th...

Go to advanced search