| delorie.com/archives/browse.cgi | search |
| From: | "Alexandre Devaure" <Alexandre DOT Devaure AT leroy-autom DOT com> |
| Newsgroups: | comp.os.msdos.djgpp |
| References: | <34AK4.1308$Uy5 DOT 1641536 AT nnrp6 DOT proxad DOT net> <8desvh$ilo$1 AT nets3 DOT rz DOT RWTH-Aachen DOT DE> |
| Subject: | Re: djgpp equivalent of borland __emi__ function |
| Lines: | 28 |
| X-Priority: | 3 |
| X-MSMail-Priority: | Normal |
| X-Newsreader: | Microsoft Outlook Express 5.00.2615.200 |
| X-MimeOLE: | Produced By Microsoft MimeOLE V5.00.2615.200 |
| Message-ID: | <L%TK4.1124$127.4836436@nnrp1.proxad.net> |
| Date: | Tue, 18 Apr 2000 07:19:07 GMT |
| NNTP-Posting-Host: | 194.51.236.59 |
| X-Complaints-To: | abuse AT proxad DOT net |
| X-Trace: | nnrp1.proxad.net 956042347 194.51.236.59 (Tue, 18 Apr 2000 09:19:07 MEST) |
| NNTP-Posting-Date: | Tue, 18 Apr 2000 09:19:07 MEST |
| Organization: | Guest of ProXad - France |
| To: | djgpp AT delorie DOT com |
| DJ-Gateway: | from newsgroup comp.os.msdos.djgpp |
| Reply-To: | djgpp AT delorie DOT com |
Thanks for your answers Hans-Bernhard and Eli. I'll use inline assemble. Alex Hans-Bernhard Broeker <broeker AT physik DOT rwth-aachen DOT de> a écrit dans le message : 8desvh$ilo$1 AT nets3 DOT rz DOT RWTH-Aachen DOT DE... > Alexandre Devaure <Alexandre DOT Devaure AT leroy-autom DOT com> wrote: > > Hi > > I need to port Borland c code to djgpp. But in the code sources, the coder > > used the __emit__ function. This function puts opcode directly in the text > > segment. Does it exist an equivalent function with djgpp ? > > The closest equivalent would be an inline assembly statement. If my > guess that __emit__ outputs not via an assembly mnemonic, but directly > by hexcode, you can use '.byte 0xab' syntax. See sys/farptr.h for > examples (the segment overrides are code like that, there). OTOH, > chances are that recent binutils even support your opcodes as > mnemonics, removing the need for machine code. > > > > -- > Hans-Bernhard Broeker (broeker AT physik DOT rwth-aachen DOT de) > Even if all the snow were burnt, ashes would remain.
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |