flat assembler
Message board for the users of flat assembler.
![]() Goto page Previous 1, 2 |
Author |
|
Madis731 21 May 2008, 06:20
Address space - now there's a whole different subject!? It has nothing to do with numbering of interrupts.
P.S. http://board.flatassembler.net/topic.php?t=6544&start=0 - I haven't noticed it before. (UHCI done - I haven't booted it yet, but if it delivers, what promised, I'm REALLY amazed) |
|||
![]() |
|
revolution 22 May 2008, 00:58
The numbers are arbitrary, why care whether catmeow is 0 or 12 or 3654569? I think you are trying to solve a problem that doesn't exist. If you use symbolic constants then the "problem" completely disappears, just assign any new functions the next available number.
|
|||
![]() |
|
Madis731 22 May 2008, 05:24
Would it satisfy if the numbers used weren't consecutive, but like this:
Code: ;First we agree, that higher functions take higher bit sets in a register: ; - then we get rax=func shl 16+subfunc ; - as you perfectly demonstrated, here is a similar solution Cat = 0 meow = 0 scratch = 1 eat = 2 Dog = 1 pee = 0 woof = 1 Sheep = 2 shear = 0 ;Calling a function is a matter of constructing one mov eax,Dog.woof ; by using some sort of macro set ;OR plainly mov eax,Dog shl 16+woof The fact that eax(rax) holds 65537 is transparent to the user. |
|||
![]() |
|
daniel.lewis 22 May 2008, 10:07
It certainly satisfies the user, but you tend not to be able to calculate the offset, you need a jump table (or worse, a set of cmp; je's) for your switch.
Meh. Whatever. ![]() They're right, it's really not important. I would worry more about the fact that the comparison revealed a lack of any memory utilities apart from the "resize" function or USB support. :p _________________ dd 0x90909090 ; problem solved. |
|||
![]() |
|
Madis731 22 May 2008, 12:57
Yes - the memory manager problem has risen before. Like with many other things: "we're working on it"...
|
|||
![]() |
|
Goto page Previous 1, 2 < Last Thread | Next Thread > |
Forum Rules:
|
Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.
Website powered by rwasa.