flat assembler
Message board for the users of flat assembler.
![]() |
Author |
|
LocoDelAssembly
In other words, you need to "execute" FPU instructions at compile time? If not you should, that is a very good idea
![]() |
|||
![]() |
|
Azu
LocoDelAssembly wrote: In other words, you need to "execute" FPU instructions at compile time? If not you should, that is a very good idea ![]() |
|||
![]() |
|
Borsuc
Well that's pretty unlikely to be possible in any assembler, FASM included. Also FASM floating point constants capability is limited.
|
|||
![]() |
|
LocoDelAssembly
Borsuc, but the interpreter layer language is powerful enough to implement a processor, and although it doesn't support floating point operations, you could still implement them in the same way FPU emulators did at the time where the FPU unit was not guaranteed to be present.
|
|||
![]() |
|
Tomasz Grysztar
Quite a few years ago (about the time of fasm 1.3x, I think) I was trying to design some kind of "plugin" functionality that would allow you to write a kind of macros for assembly layer using the x86 assembly as well (since fasm itself cannot be ported to other architecture than x86, that wouldn't be any problem to execute such code). However I gave up because of the security problems that would arise from such feature.
|
|||
![]() |
|
LocoDelAssembly
Oh damn, I forgot a very important instruction that would be hard to emulate (if not completely impossible), JMP/Jxx... But well, you could still use if, repeat, while from fasm and put inside of the control structures bodies the non-branching emulated instructions.
Here a very simple instruction to emulate: Code: ; Some code to init the pseudo-registers macro em_bswap reg { virtual ; Test the instruction is valid bswap reg end virtual @#reg = @#reg shl 24 + (@#reg shl 8) and $FF0000 + @#reg shr 24 + (@#reg shr 8) and $FF00 } |
|||
![]() |
|
baldr
Tomasz Grysztar,
May be some kind of *nix backtick functionality? I.e. replace `expr round(2*$pi*$r)` with output of that command (pi and r replaced with actual values). Separate process, almost safe bet. |
|||
![]() |
|
LocoDelAssembly
Like `del c:\boot.ini`?
![]() |
|||
![]() |
|
Azu
I didn't know *nix had c: or boot.ini.
|
|||
![]() |
|
LocoDelAssembly
Quote:
Me neither, where you take that from? |
|||
![]() |
|
Azu
![]() LocoDelAssembly wrote: Like `del c:\boot.ini`? |
|||
![]() |
|
LocoDelAssembly
Yep, you misunderstood your source.
|
|||
![]() |
|
Azu
I thought it meant delete the file called "boot.ini" in the "c:\" directory.
What did it really mean? ![]() |
|||
![]() |
|
LocoDelAssembly
Yes, I meant that, using FASM under Windows, obviously. (The computer won't explode for using a feature borrowed from Unix, I can even use it right now by using bash for Windows)
|
|||
![]() |
|
Azu
LocoDelAssembly wrote: Yes, I meant that, using FASM under Windows, obviously. (The computer won't explode for using a feature borrowed from Unix, I can even use it right now by using bash for Windows) ![]() |
|||
![]() |
|
Borsuc
You could still, you know, delete the source code if not just boot.ini (which is easily replaced), and all your work goes to trash.
![]() |
|||
![]() |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.
Website powered by rwasa.