flat assembler
Message board for the users of flat assembler.
Index
> Compiler Internals > bug |
Author |
|
Octavio 28 Mar 2006, 15:43
In the string table of a elf file generated with Fasm 1.64 it appears:
' .rel.text ' ,i think it should be a zero after '.rel' |
|||
28 Mar 2006, 15:43 |
|
Octavio 29 Mar 2006, 07:09
Ok, i didn´t read enought.
|
|||
29 Mar 2006, 07:09 |
|
Octavio 02 Apr 2006, 09:31
there is another strange thing on the elf file, in the symbol table,the symbol 'main' has 'stt_notype=0' that means undefined or constant value
but since the value of 'main' is related to where the code section is loaded i think it should be 'stt_section=3' type. and another question, why the clib version of fasm uses functions like: putchar,fread,lseek+ftell instead of the more simple and efficient: printf,read,filesize. |
|||
02 Apr 2006, 09:31 |
|
Tomasz Grysztar 02 Apr 2006, 10:25
Type STT_SECTION means the symbol representing whole section object, not the label inside the section. Anyway latest fasm versions changed to put STT_FUNC type for the simple labels.
See the guide about porting fasm for explanation why "lseek", "ftell", etc. are needed. |
|||
02 Apr 2006, 10:25 |
|
Octavio 02 Apr 2006, 15:31
Finally i get out that constant symbols use a especial section index
so in general the symbol type can be ignored. I don´t found the explanation in fasm internals about the use of 'fwrite' instead of 'write' or 'putchar' instead of 'printf',thats not a problem at all and i know that i can change the sources myself, but first i want to try a generic solution that could be used also for porting other software. And finally, how the assembly to ram project is going? |
|||
02 Apr 2006, 15:31 |
|
Tomasz Grysztar 02 Apr 2006, 16:01
Why write would be better than fwrite? putchar is used to implement all the functions from the display_* family - why import more functions when one is enough? And printf wouldn't work for display_block implementation, as the string is not zero-ended in that case.
|
|||
02 Apr 2006, 16:01 |
|
okasvi 03 Apr 2006, 10:33
Octavio wrote: And finally, how the assembly to ram project is going? is that the code generation library project or some project i havent heard about? _________________ When We Ride On Our Enemies support reverse smileys |: |
|||
03 Apr 2006, 10:33 |
|
Octavio 03 Apr 2006, 15:52
okasvi wrote:
i'm not sure if this is the same, what i want to do is to load directly the source code ,without using executables, i already do this with my assembler and it shoudn´t be much complicated to do the same with fasm. |
|||
03 Apr 2006, 15:52 |
|
TDCNL 25 Apr 2006, 00:13
Octavio wrote:
Why would you like to do that? _________________ :: The Dutch Cracker :: |
|||
25 Apr 2006, 00:13 |
|
Octavio 25 Apr 2006, 12:44
TDCNL wrote:
If the source is also the executable: 1: less files and disk space is needed 2: less programing tools are needed, no linker, no exe loader etc... 3: source is more portable than executables. 4: you can always take a look at the program with a txt editor to see if it includes something like 'include virus.asm ' 5: it was easy to do the same with Fasm. 6: Why would you like to use exe files? |
|||
25 Apr 2006, 12:44 |
|
vid 25 Apr 2006, 13:04
Quote: Why would you like to use exe files? 1: less files and disk space is needed 2: less tools are needed, no linker, no compiler/interpereter etc... 3: source is less portable than executables and thus more efficient for one particular implementation. 4: you cannot take a look at the program with a txt editor to see if it includes something like 'include virus.asm ' 5: it is easy to do the same with Fasm. :DDD don't take me too serious, i like the idea |
|||
25 Apr 2006, 13:04 |
|
Borsuc 25 Apr 2006, 13:05
Octavio wrote: 1: less files and disk space is needed Octavio wrote: 2: less programing tools are needed, no linker, no exe loader etc... Octavio wrote: 3: source is more portable than executables. Octavio wrote: 4: you can always take a look at the program with a txt editor to see if it includes something like 'include virus.asm ' Octavio wrote: 5: it was easy to do the same with Fasm. Octavio wrote: 6: Why would you like to use exe files? Personally, I hate text files that get executed at run-time, or something like that. For example, some years ago, when I didn't know asm at all, I compiled some scripts for Starcraft. Then, a friend asked me if I could write some AI for Warcraft III for him to play with (since he wasn't good at it). And I tried to help him with it, but I realized Warcraft 3 uses 'text' scripts (not compiled) and I hate them. It wasn't that I couldn't learn them -- in fact, I finally managed to get the AI to my friend and he was pleased, but I felt strange to know that these 'scripts' get inside the game archive and whatever, and are compiled at run-time. I just don't like it. Don't get me wrong Most people find "xml" or other text formats magical.. I simply do not understand why? On the contrary, they are even less magical. I especially hate them when they affect the run-time of a program or whatever (except customization things like .ini, of course ) |
|||
25 Apr 2006, 13:05 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.