Perhaps you believe assembly is standardized...Hobbes wrote:Last note: "call far es:ax" is illegal. Make it "call far [es:bx]".
How to access BIOS Interrupt without using "INT" instuction
- Love4Boobies
- Member
- Posts: 2111
- Joined: Fri Mar 07, 2008 5:36 pm
- Location: Bucharest, Romania
Re: How to access BIOS Interrupt without using "INT" instuct
"Computers in the future may weigh no more than 1.5 tons.", Popular Mechanics (1949)
[ Project UDI ]
[ Project UDI ]
Re: How to access BIOS Interrupt without using "INT" instuct
Okay, please point me "call far es:ax" in the Intel manuals.Love4Boobies wrote:Perhaps you believe assembly is standardized...
- Owen
- Member
- Posts: 1700
- Joined: Fri Jun 13, 2008 3:21 pm
- Location: Cambridge, United Kingdom
- Contact:
Re: How to access BIOS Interrupt without using "INT" instuct
Please point me to an assembler which implements pure Intel syntax (and not some modified version of it). Besides Intel's defunct asm386, good luck.
Re: How to access BIOS Interrupt without using "INT" instuct
Owen, this is not about syntax. There is no such instruction as "call far es:ax" no matter what syntax.
Re: How to access BIOS Interrupt without using "INT" instuct
Hi,
Cheers,
Brendan
That looks like it was meant to be "call far [es:ax]" (NASM syntax). I'm not sure how that'd look in AT&T syntax (maybe "es: lcall (%ax)"); or how it'd look in MASM, TASM, etc.Hobbes wrote:Owen, this is not about syntax. There is no such instruction as "call far es:ax" no matter what syntax.
Cheers,
Brendan
For all things; perfection is, and will always remain, impossible to achieve in practice. However; by striving for perfection we create things that are as perfect as practically possible. Let the pursuit of perfection be our guide.
Re: How to access BIOS Interrupt without using "INT" instuct
Right. AX cannot be used for addressing. Perhaps it was meant to be EAX and "call far es:eax" which is valid?Hobbes wrote:Owen, this is not about syntax. There is no such instruction as "call far es:ax" no matter what syntax.
Re: How to access BIOS Interrupt without using "INT" instuct
I see you have figured it out. It was meant to be "push current segment+ip and transfer control to code at segment:offset". And yes, accumulator cannot be used here, it was a bad habit of mine (using accumulator all the time). Change it to another register and you'll be fine.
- Owen
- Member
- Posts: 1700
- Joined: Fri Jun 13, 2008 3:21 pm
- Location: Cambridge, United Kingdom
- Contact:
Re: How to access BIOS Interrupt without using "INT" instuct
Really? Are you sure there is no assembler out there which takes "call far es:ax" as an operand? And are you sure you know what square brackets mean in all "Intel syntax" assemblers?Hobbes wrote:Owen, this is not about syntax. There is no such instruction as "call far es:ax" no matter what syntax.
- Combuster
- Member
- Posts: 9301
- Joined: Wed Oct 18, 2006 3:45 am
- Libera.chat IRC: [com]buster
- Location: On the balcony, where I can actually keep 1½m distance
- Contact:
Re: How to access BIOS Interrupt without using "INT" instuct
a) it is true intel syntax as per the manuals and as386Are you sure there is no assembler out there which takes "call far es:ax" as an operand?
b) it is masm compatible
c) it is tasm compatible
d) is it fasm-compatible
e) is it nasm/yasm-compatible
f) is it att syntax
I'm going for g) none of the above. Which makes your point moot, really.
All offtopicness together, I think this "right syntax" thing is just over the top. All sane assemblers use [ ] when there is an explicit variable memory operand in effect, and nobody will become better if you have to introduce a new assembly language for the sake of just winning a debate over syntax correctness.
Now can we at least pretend to be friendly and go back to assuming nasm unless specified otherwise. Most OP's won't appreciate it if someone points out an error and the next one comes by and says that it actually works differently according to some StoopidASM.
Something reminds me about language wars and forum rules. Therefore, lock requested.