flat assembler
Message board for the users of flat assembler.
![]() Goto page Previous 1, 2, 3 |
Author |
|
decard 27 Sep 2003, 09:53
Oh.... now I understand
![]() btw: one suggestion for the proc macros: maybe you could change them that they will not generate 'push ebp/mov ebp,esp' if function has no parameters nor local variables... regards |
|||
![]() |
|
JohnFound 27 Sep 2003, 10:02
decard wrote: btw: one suggestion for the proc macros: maybe you could change them that they will not generate 'push ebp/mov ebp,esp' if function has no parameters nor local variables... I will. ![]() |
|||
![]() |
|
scientica 27 Sep 2003, 12:01
JohnFound wrote: I mean (and I think scientica too) following: Correct ![]() I'm soon redy to post my draft -- last minute adjsutments. _________________ ... a professor saying: "use this proprietary software to learn computer science" is the same as English professor handing you a copy of Shakespeare and saying: "use this book to learn Shakespeare without opening the book itself. - Bradley Kuhn |
|||
![]() |
|
decard 27 Sep 2003, 16:09
I've uploaded current version of StrLib (with John's fixes). What's new:
- added two new low-level NumToStr routines: NumToStrF and NumToStrUF (by John Found) - NumToStr was rewriten - some bugfixes & modifications were done. - added StrExtract Actually it is not a new version, I just have done some bugfixes... By now it doesn't use new set of macros (but it uses "if used" statements). I will add those macros in new version ![]() regards, Decard |
|||
![]() |
|
decard 29 Sep 2003, 14:24
That's version 1.1.4 of StrLib...
- library was rewtiten to use John Found's stdcall macros - added two new low-level NumToStr routines: NumToStrF and NumToStrUF - NumToStr rewriten - some small bugfixes & modifications - added StrExtract (it's a requested SubStr routine, but wanted all names in lib begin with 'Str', and StrSub didn't sound nice to me ![]() ![]() [EDIT]outdated attachment removed. Now StrLib can be found in Fresh Package.[/EDIT][/b] Last edited by decard on 18 Oct 2003, 17:56; edited 2 times in total |
|||
![]() |
|
scientica 29 Sep 2003, 17:31
Something has changed, and it causes me to get an "unexpected" output.
With verison 1.1.3 I get this out put: Code: [D:\Dev\FASM\harsyra]harsyra -Harsyra- v0.1 Copyright (C) Fredrik Klasson (aka scientica) 2003. ®®DEBUG¯¯ struc TFile{ .spFile dd 00000001h (1) => 00072E08h (470536) => "test.asm",0 .spName dd 00000000h (0) => FFFFFFFFh (-1) => "[NULL POINTER!]",0 .spDescription dd 00000000h (0) => FFFFFFFFh (-1) => "[NULL POINTER!]",0 .ddFileSize dd 000008B1h (2225) .ddLines dd 00000000h (0) .ddComments dd 00000000h (0) .lpComments dd 000751E8h (479720) .lpRaw dd 00074928h (477480) } ®®DEBUG¯¯ ®®DEBUG¯¯ struc TComment{ .pThis dd 004040CCh (4210892) .pNextTC dd 00000000h (0) .pPreviousTC dd 00000000h (0) .ddStarLine dd 00000000h (0) .ddEndLine dd 00000000h (0) .pFile dd 00000001h (1) => 00072E08h (470536) => "test.asm",0 .RawOffset dd 00000000h (0) } ®®DEBUG¯¯ ®®DEBUG¯¯ ESI: 0007492Dh (477485): Test File®®DEBUG¯¯ ®®DEBUG¯¯ ESI: 0007493Dh (477501): ; This is a test File (and a test description) ; it spans a few lines for ; fun :®®DEBUG¯¯ ®®DEBUG¯¯ struc TFile{ .spFile dd 00000001h (1) => 00072E08h (470536) => "test.asm",0 .spName dd 00000002h (2) => 00075AA8h (481960) => "Test File",0 .spDescription dd 00000003h (3) => 00075AC8h (481992) => "; This is a test File (and a test description) ; it spans a few lines for ; fun :)",0 .ddFileSize dd 000008B1h (2225) .ddLines dd 00000000h (0) .ddComments dd 00000000h (0) .lpComments dd 000751E8h (479720) .lpRaw dd 00074928h (477480) } ®®DEBUG¯¯ but with version 1.1.4: Code: -Harsyra- v0.1 Copyright (C) Fredrik Klasson (aka scientica) 2003. ®®D®®D®®D I'll run a diff on the strlib and see what has changed - it wouldn't suprise me if the error is in my code (using some bug/"un-doc-feature" to work). Does any other experiance somethig similar? btw, yes the output is from harsyra, as you can see I'm using the strlib :) the source is a mayham - still got remains of the old non-strlib code, which soon will "disappear". _________________ ... a professor saying: "use this proprietary software to learn computer science" is the same as English professor handing you a copy of Shakespeare and saying: "use this book to learn Shakespeare without opening the book itself. - Bradley Kuhn |
|||
![]() |
|
decard 29 Sep 2003, 18:15
I've really no idea what could cause this strange output
![]() ![]() regards, decard |
|||
![]() |
|
scientica 29 Sep 2003, 20:06
decard wrote: Unfortunately I can't do it today as I have to learn for tomorrow's German test (Arghhhhh I know, rember them, but luckily Swedish has some similarities with German (so I could guess the meaning of some germain words). Good luck ![]() With risc of this beeing to little, but these are what I've used (I've excluded a few calls which are basically the same as the listed). I haven't had time to check the code again (a few RL matters to tend to), but I'm about to take look now. Code: Functions from strlib.asm used by Harsyra.asm: call InitStrings call FreeStrings stdcall StrPos, esi, szFileComment ; search for ';<<<'... stdcall StrNew, [ebx+TFile.spName] stdcall StrCopy, eax, esi ; copy/set the filename stdcall StrPtr, [ebx+TFile.spFile] section '.data' data readable writeable ... StrTable TStrTable _________________ ... a professor saying: "use this proprietary software to learn computer science" is the same as English professor handing you a copy of Shakespeare and saying: "use this book to learn Shakespeare without opening the book itself. - Bradley Kuhn |
|||
![]() |
|
decard 30 Sep 2003, 13:18
It was a VERY stupid bug in StrLen
![]() Now it should work OK... |
|||
![]() |
|
scientica 03 Oct 2003, 14:10
Ok, works fine now. (a few days late but, I thought it was best to sya that it works
![]() _________________ ... a professor saying: "use this proprietary software to learn computer science" is the same as English professor handing you a copy of Shakespeare and saying: "use this book to learn Shakespeare without opening the book itself. - Bradley Kuhn |
|||
![]() |
|
decard 04 Oct 2003, 06:39
Well.... better later than never
![]() ![]() ![]() Nice to hear that scientica, and thanks for the bug raport ![]() |
|||
![]() |
|
0x004549554F4C 18 Mar 2004, 06:00
newb questions:
Whats the string handle is it different from a pointer how? |
|||
![]() |
|
JohnFound 18 Mar 2004, 07:06
0x004549554F4C wrote: newb questions: Hi. This library handles dynamic strings - they can be dynamically resized during runtime. The main idea for string handles instead of pointers is that handle remains constant, while the pointer may be changed when the string length is changed. Of course, the most of StrLib functions work fine with static pointers as well. You have to read "freshguide.chm" from Fresh package for more details. There is very good description of whole library by Decard. Regards. |
|||
![]() |
|
0x004549554F4C 19 Mar 2004, 04:30
do you have a mid string function to take only part of a string (ie in the middle)
str1 db 'BlaH',0 strbuffer rb 0xF000 MIDSTR str1, 3, 2, strbuffer strbuffer = 'a','H' MIDSTR Mstr, Start, Len, Buffer Mov ESI, Mstr Mov EBX, Buffer Add ESI, Start Mov ECX, FFFFFFFFh LBL1: Inc ECX Mov AL, byte[ESI+ECX] Mov [EBX+ECX], AL Cmp ECX, Len JL LBL1 Something along those lines [pretty sure the above will NOT compile] |
|||
![]() |
|
aaro 19 Mar 2004, 10:06
You could also have a look at my try for fasm standard library, there's currently 23 string functions if i counted them right. Including StrMid.
http://board.flatassembler.net/topic.php?t=1107 |
|||
![]() |
|
0x004549554F4C 20 Mar 2004, 04:48
aaro your library is great, keep up the good work. Just skimming through it i've learned tons about assembler.
the most impressive part of it is the efficiency in the code. you squeezed every byte ![]() |
|||
![]() |
|
mario29 06 Nov 2010, 19:39
Can someone please post the download link for this.
|
|||
![]() |
|
revolution 06 Nov 2010, 22:25
mario29 wrote: Can someone please post the download link for this. decard wrote: [EDIT]outdated attachment removed. Now StrLib can be found in Fresh Package.[/EDIT][/b] http://board.flatassembler.net/topic.php?p=121677#121677 |
|||
![]() |
|
Goto page Previous 1, 2, 3 < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2023, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.