Search found 1227 matches

by SARG
Dec 10, 2020 16:50
Forum: General
Topic: Compile times
Replies: 23
Views: 942

Re: Compile times

jj2007 wrote:That made the trick, thanks. I've added timings for your FB version above - compliments!

Thank you.

jj2007 wrote: Which Windows version is yours?
Windows 10, version 2004. Atom functions need at least W2000 so not the reason.
by SARG
Dec 10, 2020 14:54
Forum: General
Topic: Compile times
Replies: 23
Views: 942

Re: Compile times

fbc64_gas64 (20 Nov 2020) barks at me: gcc.exe: error: CreateProcess: No such file or directory No problem on my side. Did you add -gen gas64 ? gcc is not used. I tried TimeWithAtom but got 2 errors : @echo off TimeWithAtom.exe set twa=%ERRORLEVEL% D:\laurent_divers\freebasic64bit\fbc64_gas64 -s co...
by SARG
Dec 07, 2020 11:47
Forum: Community Discussion
Topic: fbc compilation complete message
Replies: 7
Views: 476

Re: fbc compilation complete message

Maybe you are doing something wrongly for crashing fbide. But what ???
Try adding -v (verbose mode) when compiling with fbc like that there is always something to display.
by SARG
Dec 07, 2020 11:09
Forum: Community Discussion
Topic: fbc compilation complete message
Replies: 7
Views: 476

Re: fbc compilation complete message

If you are using a batch file you can test %errorlevel%
Compilation successful --> %errorlevel% = 0 otherwise --> %errorlevel% = 1

IF %ERRORLEVEL% NEQ 0 Echo An error was found
IF %ERRORLEVEL% EQU 0 Echo No error found

Use goto to skip lines
by SARG
Dec 06, 2020 10:32
Forum: General
Topic: intrinsic: __FB_WIN32__
Replies: 9
Views: 608

Re: intrinsic: __FB_WIN32__

Hi speedfixer,

WIN32 doesn't refer to Windows 32bit but just windows API so 32bit or 64bit, it's like that everywhere, not only in fbc. Win64 is almost never used.
In a same way you don't have __FB_LINUX32__ and __FB_LINUX64__

So the way of doing is correct : testing Win32 and Is64bit.
by SARG
Dec 05, 2020 18:27
Forum: Beginners
Topic: How to use a pointer for a ulong number
Replies: 13
Views: 1002

Re: How to use a pointer for a ulong number

If you want to retrieve byte by byte you need to define a byte pointer. To avoid warning just cast it dim as byte ptr numptr NumPtr = cast(byte ptr,@Number) If you don't do that you get an integer value (4 bytes if under 32bit) and every time you add 1 to the pointer the real value is increased by 4...
by SARG
Dec 05, 2020 7:31
Forum: Beginners
Topic: How to use a pointer for a ulong number
Replies: 13
Views: 1002

Re: How to use a pointer for a ulong number

You must use a byte ptr instead an integer ptr otherwise an integer is retrieved every turn in the loop.... Just add a 'print numptr' to see that. Dim Number as uLong Dim NumPtr as byte ptr ''<------------------------ Dim Index as byte Number = &H12345678 NumPtr = CInt(@Number) 'If I want to see...
by SARG
Dec 03, 2020 23:47
Forum: Beginners
Topic: Trying to get union to work
Replies: 3
Views: 345

Re: Trying to get union to work

There is a syntax error "union ends" should be "end union". union VariableValueParted union first type FirstLoByteValue As UByte 'lowbyte SecondLoByteValue As UByte 'highbyte end type LoWordSizevalue as UShort end union union second type FirstHiByteValue As UByte 'low byte part o...
by SARG
Dec 03, 2020 15:27
Forum: General
Topic: When to use Integer and when not to
Replies: 33
Views: 1908

Re: When to use Integer and when not to

To say it more clearly. All the additions below should take the same amount of time with a 64 bit processor: You have to take in account also the compiler : 32bit or 64bit. With the 64bit version of fbc the additions (and other operations) are done using 64bit integer so it's necessary to convert b...
by SARG
Dec 02, 2020 16:31
Forum: Projects
Topic: Profiling (with gas64)
Replies: 0
Views: 422

Profiling (with gas64)

Profiling allows to know how much CPU time is used by every procedure for eventually choose where optimize. It's experimental. Give me your opinion. Use : - compile your code as usually with the provided exe. Just add the option -profile (don't forget -gen gas64). http://users.freebasic-portal.de/sa...
by SARG
Nov 30, 2020 14:17
Forum: Documentation
Topic: Wiki improvements
Replies: 565
Views: 108053

Re: Wiki improvements

I read also this but it's more like an example for finding an explicit name.
by SARG
Nov 30, 2020 14:07
Forum: Documentation
Topic: Wiki improvements
Replies: 565
Views: 108053

Re: Wiki improvements

GetCurrentThread Windows's API :-)

"handle" thanks
by SARG
Nov 30, 2020 13:58
Forum: Documentation
Topic: Wiki improvements
Replies: 565
Views: 108053

Re: Wiki improvements

The meaning of ThreadSelf is not obvious, at least for me.
ThreadGetHandle() (a bit long) or ThreadHandle() seem clearer.

And keep "handle" everywhere as it's its purpose.
by SARG
Nov 23, 2020 23:45
Forum: Projects
Topic: Gas64 (no more use of gcc, only gas) WDS / LNX
Replies: 401
Views: 49811

Re: Gas64 (no more use of gcc, only gas) WDS / LNX

Hi robert, I don't use makefiles so my answer is what I understand after looking them. For fbc preferably use ALLFBCFLAGS += -gen gas64 As FBFLAGS is also used for linking. You could add -R and if you see a64 files the compiler uses gas64. For the tests use the option 'GEN' with makefile for selecti...
by SARG
Nov 20, 2020 20:36
Forum: General
Topic: Crash in recursion
Replies: 3
Views: 297

Re: Crash in recursion

Hi UEZ,

Put this line like before the test

Code: Select all

print cos(x) , Sin(y - n / 2): Flip  :sleep 010

You will see values reaching limits --> undefined.
I guess (no time to go deeper) that the order of the values for the test is important.

Go to advanced search