Results 1 to 5 of 5

Thread: Update from August 11

  1. #1
    Super Moderator Petr Schreiber's Avatar
    Join Date
    Aug 2005
    Location
    Brno - Czech Republic
    Posts
    7,153
    Rep Power
    736

    Update from August 11

    Hi Charles,

    update from Monday looks very good from the feature list, thanks.
    Any demos ?


    Petr
    Learn 3D graphics with ThinBASIC, learn TBGL!
    Windows 10 64bit - Intel Core i5-3350P @ 3.1GHz - 16 GB RAM - NVIDIA GeForce GTX 1050 Ti 4GB

  2. #2

    Re: Update from August 11

    The only additional instructions are: / and /+

    They are used to align tables or set them to specific locations in the binary code string


    Simple examples:

    jmp long ok
    o2 /0c
    .ok
    ret

    produces:

    0000: e9 07 00 00 00
    0002: 00 00 00 00 00 00 00
    000C: c3

    jmp long ok
    o2 /+4
    .ok
    ret


    produces

    0000: e9 03 00 00 00
    0005: 00 00 00
    0008: c3


    you can see how this is applied in the import section of an EXE.
    There is some fiddly pointering going on here, but the tables can be kept aligned to the correct boundaries.

    ga produces the 4 byte offset for a specified label. (start of code string=0)

    [code=thinbasic]
    ; IMPORT DIRECTORY ENTRY RECORD
    ; -----------------------------

    /+1000
    .imports

    ga name_list ; 00001C00 dw RVA Function Name List 0000C040
    hl00000000 ; 00001C04 dw Useless 1 00000000
    hl00000000 ; 00001C08 dw Useless 2 00000000
    ga module_name ; 00001C0C dw RVA Module Name 0000C244
    ga proc_address_list ; 00001C10 dw RVA Function Address List 0000C0A8

    ; Function List (declare_order and name)
    ; ---------------------------------------
    ; 00001CB0 0000C0A0 0001 FreeLibrary
    ; 00001CBC 0000C0A4 0002 GetProcAddress
    ; 00001CC0 0000C0A8 0003 LoadLibraryA


    /+4
    .proc_address_list

    ga FreeLibrary
    ga GetProcAddress
    ga LoadLibraryA

    /+4
    .module_name `KERNEL32.DLL` 00 00


    /+4
    .name_list

    /+4 .FreeLibrary hw0001 `FreeLibrary` 00 00
    /+4 .GetProcAddress hw0002 `GetProcAddress` 00 00
    /+4 .LoadLibraryA hw0003 `LoadLibraryA` 00 00

    [/code]

  3. #3
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    68
    Posts
    3,865
    Rep Power
    405

    Re: Update from August 11

    My studies in Assembly are going slow, but I keep plugging away. With all the capabilities Charles is providing it is incentive to keep studying. I Can see now that once it is learned you can do anything, since Charles is developing the compiler and already his module can be used to create your own language in a way. And all of this can be done via thinbasic and the modules, it is incredible!

    But being the moth drawn to light of higher level languages I wander off of assembly in search of the light to often!
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

  4. #4

    Re: Update from August 11


    Hi Kent,
    I hope we will be able to build higher levels with the h2o project soon. I am trying to crack the hardest nuts first - hence working on Hash tables, operator precedence, PE formats etc.


  5. #5
    thinBasic MVPs kryton9's Avatar
    Join Date
    Nov 2006
    Location
    Naples, Florida & Duluth, Georgia
    Age
    68
    Posts
    3,865
    Rep Power
    405

    Re: Update from August 11

    Sounds good Charles, thanks for all the effort!
    Acer Notebook: Win 10 Home 64 Bit, Core i7-4702MQ @ 2.2Ghz, 12 GB RAM, nVidia GTX 760M and Intel HD 4600
    Raspberry Pi 3: Raspbian OS use for Home Samba Server and Test HTTP Server

Similar Threads

  1. Hi all ,you should update your SMF
    By hackchasers in forum General
    Replies: 1
    Last Post: 03-12-2009, 08:54

Members who have read this thread: 0

There are no members to list at the moment.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •