Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > alt.os.development > #8299
| Newsgroups | alt.os.development |
|---|---|
| Date | 2015-07-05 02:58 -0700 |
| References | (13 earlier) <op.x08ojxp5yfako5@localhost> <853c70d5-5652-42e9-ac0f-e4b832b56ca3@googlegroups.com> <op.x1ad7uijyfako5@localhost> <a4f7d2ad-2109-4cf9-ac92-fc660efbdeed@googlegroups.com> <op.x1am9mo9yfako5@localhost> |
| Message-ID | <1399541c-e62d-4a64-9f68-011365509d53@googlegroups.com> (permalink) |
| Subject | Re: What form of executable or load module for your OS? |
| From | "Alexei A. Frounze" <alexfrunews@gmail.com> |
On Sunday, July 5, 2015 at 2:28:21 AM UTC-7, Rod Pemberton wrote: > On Sun, 05 Jul 2015 03:47:12 -0400, Alexei A. Frounze > <...@gmail.com> wrote: ... > > ----8<---- > > ; file: br.asm > > ; compile (with nasm 2.10): nasm -f bin br.asm -o br.com > > ; decompile: ndisasm -b 16 -o 0x100 br.com > > CPU 8086 > > org 0x100 > > bits 16 > > > > jz lab > > times 256 nop > > lab: > > ret > > ----8<---- > > Assembles without errors. > > > > Disassembly: > > ----8<---- > > 00000100 7503 jnz 0x105 > > 00000102 E90001 jmp word 0x205 > > 00000105 90 nop > > 00000106 90 nop > > 00000107 90 nop > > 00000108 90 nop > > ... > > 00000200 90 nop > > 00000201 90 nop > > 00000202 90 nop > > 00000203 90 nop > > 00000204 90 nop > > 00000205 C3 ret > > ----8<---- > > > > So, NASM 2.10 (or maybe all the way back to 2.03) is doing just fine. > > Are you saying NASM actually compiles that for the 8086 source? Yes, as you can see. :) > It clearly DID NOT do what it was told to do ... Bad assembler! GOOD assembler! Here, have a treat! :) > So, that's rather surprising to me, since NASM is so "pedantic". > > Let's check: > > yes 2.09.04 64-bit Linux > yes 2.06rc8 to 2.10.01 32-bit DOS (5 versions) > no 0.98.39 32-bit DOS > > The classic 0.98.39 version of NASM reports an error on line 5: > "... error short jump is out of range" > > James was concerned with Jcc with an offset greater than 8-bits > for 8086 code. The 8086 only supported the 8-bit offset for Jcc > instruction. So, as long as James doesn't need compatibility > with NASM 0.98.39 or some other older intermediate version, he's > all set. NASM does what I suggested as a fix for short branches, > for the more recent versions. We just learned a new thing. Made a discovery. In something we use often. :) I guess, the fireworks were quite appropriate. :) Alex
Back to alt.os.development | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-06-25 21:20 -0700
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-01 10:36 +0100
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-01 21:07 -0700
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-02 23:35 -0700
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-03 08:35 +0100
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-03 02:49 -0700
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-03 11:27 +0100
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-03 16:54 -0400
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-03 22:45 +0100
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-03 17:56 -0400
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-03 15:28 -0700
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-03 23:48 +0100
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-03 21:52 -0700
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-04 04:00 -0400
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-04 04:42 -0700
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-05 02:12 -0400
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-05 00:47 -0700
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-05 05:28 -0400
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-05 02:58 -0700
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-06 06:21 -0400
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-07 01:44 -0700
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-07 05:40 -0400
Re: What form of executable or load module for your OS? "Kerr Mudd-John" <admin@127.0.0.1> - 2015-07-07 14:02 +0100
Re: What form of executable or load module for your OS? "wolfgang kern" <nowhere@never.at> - 2015-07-07 18:13 +0200
Re: What form of executable or load module for your OS? "Kerr Mudd-John" <notsaying@invalid.org> - 2015-07-08 12:54 -0100
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-09 13:19 +0100
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-07 22:10 -0700
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-08 08:48 +0100
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-08 23:53 -0700
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-09 17:29 +0100
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-10 01:01 -0700
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-10 13:46 +0100
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-10 00:59 -0700
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-08 03:52 -0400
Re: What form of executable or load module for your OS? "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-08 06:46 -0700
Re: What form of executable or load module for your OS? "James Harris" <james.harris.1@gmail.com> - 2015-07-09 13:16 +0100
Re: What form of executable or load module for your OS? "s_dubrovich@yahoo.com" <s_dubrovich@yahoo.com> - 2015-07-11 09:57 -0700
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-13 02:47 -0400
Re: What form of executable or load module for your OS? "s_dubrovich@yahoo.com" <s_dubrovich@yahoo.com> - 2015-07-14 07:39 -0700
Re: What form of executable or load module for your OS? "Rod Pemberton" <boo@fasdfrewar.cdm> - 2015-07-15 02:37 -0400
Code insanity "Mike Gonta" <mikegonta@gmail.com> - 2015-07-03 03:47 -0400
Re: Code insanity "Alexei A. Frounze" <alexfrunews@gmail.com> - 2015-07-03 02:57 -0700
Re: Code insanity (was: What form of executable or load module for your OS?) "James Harris" <james.harris.1@gmail.com> - 2015-07-03 11:35 +0100
csiph-web