Article View: pl.comp.lang.asm
Article #105Re: AT&T i call
From: Lopez
Date: Sun, 05 Feb 2006 21:59
Date: Sun, 05 Feb 2006 21:59
48 lines
1965 bytes
1965 bytes
Bogdan (bogdro) napisał(a): > Bogdan (bogdro) napisał(a): > >>Lopez napisał(a): >> >>>Witam >>> >>>Mam instrukcje w skladni intela >>> >>>call dword [table+eax*4] >>> >>>to w at&t to bedzie >>> >>>call *table(,%eax,4) >>>czy >>>call table(,%eax,4) >>> >>>bo nie mam pewnosci. > > [...] > Dobra, potestowałem trochę. Oto wyniki: > > call *table(,%eax,4) > daje (ndisasm -u -e 0x34): > FF148500000000 call near [eax*4+0x0] > > Rzecz jasna, zera zostałyby zastąpione prawidłowym adresem na etapie > linkowania. > > Tymczasem: > call table(,%eax,4) > daje: > Warning: indirect call without `*' > > Niemniej, kod się kompiluje, a skompilowane bajty ... wychodzą takie > same, jak poprzednio. Ale najwyraźniej bardziej zgodna ze składnią > AT&T jest ta pierwsza wersja. > Najlepiej to by było sprawdzić po linkowaniu. Rownolegle przeprowadzilem te same testy i wrzucilem dzialajacy przyklad. Niemniej jednak mam kod, w ktorym mi cos nie gra i musialem sie upewnic, ze akurat tu jest ok. Dzieki. -- Pozdrawiam Lopez
Technical Details
Message-ID:
<ds5sfl$7as$1@inews.gazeta.pl>Path:
mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!not-for-mailReferences:
<ds5ct5$hog$1@inews.gazeta.pl> <ds5j3r$h04$1@inews.gazeta.pl> <ds5m46$2nt$1@inews.gazeta.pl>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.gazeta.pl!not-for-mail From: Lopez <rtlopezREMOVE@gazeta.pl> Newsgroups: pl.comp.lang.asm Subject: Re: AT&T i call Date: Sun, 05 Feb 2006 22:59:21 +0100 Organization: "Portal Gazeta.pl -> http://www.gazeta.pl" Lines: 48 Message-ID: <ds5sfl$7as$1@inews.gazeta.pl> References: <ds5ct5$hog$1@inews.gazeta.pl> <ds5j3r$h04$1@inews.gazeta.pl> <ds5m46$2nt$1@inews.gazeta.pl> NNTP-Posting-Host: user10.53.udn.pl Mime-Version: 1.0 X-Trace: inews.gazeta.pl 1139176758 7516 82.139.10.53 (5 Feb 2006 21:59:18 GMT) X-Complaints-To: usenet@agora.pl NNTP-Posting-Date: Sun, 5 Feb 2006 21:59:18 +0000 (UTC) In-Reply-To: <ds5m46$2nt$1@inews.gazeta.pl> X-Accept-Language: pl, en-us, en X-User: rtlopez User-Agent: Mozilla Thunderbird 1.0.2 (X11/20051002) Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit