News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

Recent posts

#11
The Laboratory / Re: Invoke, call, jump. Simple...
Last post by jj2007 - July 03, 2025, 12:41:36 AM
Quote from: daydreamer on July 02, 2025, 06:58:12 PM32bit fastcall transfer data in registers vs 32 bit invoke pushing data would be most fair to test

Yep, you can save a cycle :thumbsup:

AMD Athlon Gold 3150U with Radeon Graphics      (SSE4)

400    cycles for 100 * proc aligned 16
400    cycles for 100 * proc aligned 16+3
417    cycles for 100 * aligned push+pop
273    cycles for 100 * aligned reg32

405    cycles for 100 * proc aligned 16
409    cycles for 100 * proc aligned 16+3
426    cycles for 100 * aligned push+pop
276    cycles for 100 * aligned reg32

409    cycles for 100 * proc aligned 16
402    cycles for 100 * proc aligned 16+3
422    cycles for 100 * aligned push+pop
290    cycles for 100 * aligned reg32

403    cycles for 100 * proc aligned 16
406    cycles for 100 * proc aligned 16+3
426    cycles for 100 * aligned push+pop
278    cycles for 100 * aligned reg32

406    cycles for 100 * proc aligned 16
416    cycles for 100 * proc aligned 16+3
421    cycles for 100 * aligned push+pop
281    cycles for 100 * aligned reg32

15      bytes for proc aligned 16
19      bytes for proc aligned 16+3
24      bytes for aligned push+pop
20      bytes for aligned reg32
#12
The Laboratory / Re: Invoke, call, jump. Simple...
Last post by daydreamer - July 02, 2025, 06:58:12 PM
Today with old 32bit arguments vs 64 bit fastcall, put data in registers would be more interesting
32bit fastcall transfer data in registers vs 32 bit invoke pushing data would be most fair to test
#13
The Orphanage / Re: No more Blue screen of dea...
Last post by daydreamer - July 02, 2025, 06:54:45 PM
Actually an alternative black screen of death has been possible since laptops existed in the way of "dead battery" :smiley:
#14
Basic variants / Re: Some 'links' to Alternate ...
Last post by daydreamer - July 01, 2025, 05:56:11 PM
I sometimes get an idea and write TI basic on my Ti calculator before asm version, I can write it anywhere instead of have to wait until I get home to PC

Unfortunatly I never had a Z80 based BASIC, which got enhanced by writing Z80 machine instructions in data sets, so I never managed to write a TI calculator asm program  :sad:
#15
BCX / Dll to Poasm 64 bit include fi...
Last post by Vortex - July 01, 2025, 04:54:16 AM
DllToInc64 tool converting DLLs to Poasm 64-bit include files. The zip file includes the .c and .bas files.

D:\BCX>DllToInc64.exe
Usage : DllToInc64.exe DllFile.dll [optional -u]
Version 1.0
-u : Create include file for UNICODE API functions.

Example :

DllToInc64.exe kernel32.dll
#16
FreeBASIC / Re: Small test
Last post by Vortex - July 01, 2025, 04:41:55 AM
Hi Timo,

Here is how to build the small sized 32-bit version :

\FreeBASIC\fbc32 -nodeflibs -c GetPublicIP.bas

\FreeBASIC\bin\win32\ld -e _mainCRTStartup -subsystem console -o GetPublicIP.exe GetPublicIP.o -L\FreeBASIC\lib\win32 -lkernel32 -luser32 -lgdi32 -lWininet -lmsvcrt -s

Turning off the run-time library, you can create small FreeBASIC executables.
#17
FreeBASIC / Small test
Last post by TimoVJL - June 30, 2025, 07:48:57 PM
I liked this small test with fbc, but can't remember, where it came.
' Example of retrieving the WAN IP adress from an external source :
'
' GetPublicIP.exe http://whatismyip.akamai.com
' GetPublicIP.exe https://ipecho.net/plain
'
' If no command line option is specified then the application
' defaults to the address http://icanhazip.com

' Source code compiled with FreeBASIC Compiler - Version 1.09.0 (2021-12-31)

#include "windows.bi"
#include "win\wininet.bi"

Declare Function __getmainargs Cdecl Alias "__getmainargs" (Byval As Integer Ptr,_
                 Byval As Zstring Ptr Ptr Ptr,Byval As Zstring Ptr Ptr Ptr,_
                 Byval As Integer,Byval As LPSTARTUPINFO) As Integer


Public Function StdOut ( Zstr As Zstring Ptr) As Integer

Dim As HANDLE hOutput
Dim As DWORD bWritten

hOutput=GetStdHandle(STD_OUTPUT_HANDLE)

WriteFile(hOutPut,Zstr,lstrlen(ZStr),@bWritten,NULL)

Function=bWritten

End Function


Function main () As Integer

Dim As Integer i,RetVal
Dim As HINTERNET hInt,hUrl
Dim As WINBOOL Irf
Dim As DWORD BuffSize
Dim As LPCSTR url
Dim As ZString * 128 App
Dim As ZString * 68 IpAddr
Dim As ZString Ptr Buffer=@IpAddr

Dim As Integer argc
Dim As ZString Ptr Ptr argv
Dim As ZString Ptr Ptr env
Dim As Integer sinfo=0

__getmainargs(@argc,@argv,@env,0,Cast(LPSTARTUPINFO,@sinfo))

If argc=1 Then
   
    url=Cast(ZString Ptr,@"http://icanhazip.com")
   
Else

    url=argv[1]
   
End If


GetModuleFileName(0,@App,128)

hInt=InternetOpen(@App,INTERNET_OPEN_TYPE_PRECONFIG,0,0,0)

If hInt=0 Then Return 1

hUrl=InternetOpenUrl(hInt,url,0,0,0,0)


If hUrl=0 Then
   
    InternetCloseHandle(hInt)
    Return 2
   
End If


Irf=InternetReadFile(hUrl,@IpAddr,64,@BuffSize)

InternetCloseHandle(hUrl)


If Irf=0 Then
   
    InternetCloseHandle(hInt)
    Return 3
   
End If

*Cast(Ubyte Ptr,Buffer+BuffSize)=0


For i=1 To BuffSize
   
    If *Cast(Ubyte Ptr,Buffer)<32 Then *Cast(Ubyte Ptr,Buffer)=32
   
    Buffer+=1
   
Next i

StdOut IpAddr

InternetCloseHandle(hInt)

Return 0

End Function

Sub mainCRTStartup Cdecl Alias "mainCRTStartup"()

    ExitProcess(main())

End Sub
#19
Basic variants / Re: A Possible New inclusion -...
Last post by Vortex - June 30, 2025, 05:23:51 AM
Hi Stewart,

Great addition, many thanks :thumbsup:
#20
Basic variants / Re: Some 'links' to Alternate ...
Last post by stoo23 - June 29, 2025, 11:12:46 PM
Yes as well as the Superb SORD BasicII, which we had supplied with our SORD M68K, which was a very fast and  compilable Basic for the Z80 cpu in the 68k :)
In fact they don't list Any of the SORD Basics provided for their other earlier machines or for the later SORD M5 unit.

It was just a site I found that listed a Lot of BASIC Variants :)
There are undoubtedly more, .... Like AMOS (my namesake Basic), https://en.wikipedia.org/wiki/AMOS_(programming_language)
Which was used extensively on the Commodore Amiga platform.
:)