Re: Absolute jump without register?
From: Bx.C (invalid-email-address_at_invalid.shiragajin)
Date: 03/28/04
- Next message: lallous: "Re: Absolute jump without register?"
- Previous message: Julian Brown: "Re: Absolute jump without register?"
- In reply to: Kaelin Colclasure: "Absolute jump without register?"
- Next in thread: lallous: "Re: Absolute jump without register?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sun, 28 Mar 2004 20:36:02 +0000 (UTC)
"Kaelin Colclasure" <kaelin@bridge.com> wrote in message
news:c464d6$r25$05$1@news.t-online.com...
> Hi :)
>
> I want to to an absolute jump to an address.
>
> With the aid of a register it looks like this and jumps to the desired
> address:
>
> mov edx, 00411A30h
> call edx
>
> My question is now: Can I do this in one instruction without the
> register (or mem)?
>
> I found the following syntax...
>
> call dword ptr cs:[00411A30h]
>
> ...but it seems that it is not the same. It crashes my app with an
> access violation.
>
> Why doesn't this work? Is there another way to do it without indirection?
>
> Environment: Windows XP, Visual C++ .NET Inline Assembly
your choices for operands are register, memory, or immediate... since you're not wanting
register or memory, your other choice is immediate...
now, there are two major different immediate formats... there's the FAR format, which IS an
absolute, and the SHORT/NEAR/LONG formats which are relative to $+2... ($=current eIP)
if possible, you should use the relative formats... but if necessary, use the far format... if
you need to use an immediate/absolute coding, use the FAR format... i could be wrong though, but
i believe the indirect absolute codings are faster...
what exactly are you needing?
- Next message: lallous: "Re: Absolute jump without register?"
- Previous message: Julian Brown: "Re: Absolute jump without register?"
- In reply to: Kaelin Colclasure: "Absolute jump without register?"
- Next in thread: lallous: "Re: Absolute jump without register?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|