flat assembler
Message board for the users of flat assembler.
Index
> Main > Detect bitness (FASM-specific, probably) |
Author |
|
ouadji 14 Sep 2010, 20:21
some time ago, I switched in unprotected mode (physical addressing) with Windows XP and i did a real "mov eax, [0]" ... even if everything was perfectly normal, It is still amazing to be able to execute such a instruction. |
|||
14 Sep 2010, 20:21 |
|
windwakr 14 Sep 2010, 20:34
Neat.
Code: macro get_bitness bitness { virtual at 0 mov eax, [0]; depends on FASM choosing shorter (r/m rip-relative) encoding bitness = 1 shl $ end virtual } ;;;;My test code below macro disp_smallnum string, num ;Only works properly for 0-99...must be updated when 128bit comes out. :P { display string , (num / 10)+'0', num mod 10+'0',0xD,0xA } use16 get_bitness bits disp_smallnum 'use16: ', bits use32 get_bitness bits disp_smallnum 'use32: ', bits use64 get_bitness bits disp_smallnum 'use64: ', bits Display wrote:
|
|||
14 Sep 2010, 20:34 |
|
LocoDelAssembly 14 Sep 2010, 20:36
Marvelous!
|
|||
14 Sep 2010, 20:36 |
|
edfed 14 Sep 2010, 22:14
now, the same for every instructions, anywhere, with ascii string to return listing of the instruction?
|
|||
14 Sep 2010, 22:14 |
|
baldr 14 Sep 2010, 23:42
edfed,
flat disassembler? |
|||
14 Sep 2010, 23:42 |
|
revolution 15 Sep 2010, 01:42
That is a nice find.
|
|||
15 Sep 2010, 01:42 |
|
cod3b453 15 Sep 2010, 17:07
wow that is a neat trick
(I'll stick with my wrapper macros though ) |
|||
15 Sep 2010, 17:07 |
|
guignol 16 Sep 2010, 09:27
Erm?..
|
|||
16 Sep 2010, 09:27 |
|
edfed 17 Sep 2010, 02:32
what can be nice is to know the count of instructions, and other things, at compilation time
display wrote:
|
|||
17 Sep 2010, 02:32 |
|
< Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.