home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / os / msdos / programm / 9113 < prev    next >
Encoding:
Internet Message Format  |  1992-09-08  |  2.0 KB

  1. Path: sparky!uunet!cs.utexas.edu!swrinde!ringer!mlevis
  2. From: mlevis@ringer.cs.utsa.edu (Mike Levis)
  3. Newsgroups: comp.os.msdos.programmer
  4. Subject: Re: studying executables
  5. Message-ID: <1992Sep7.034936.28892@ringer.cs.utsa.edu>
  6. Date: 7 Sep 92 03:49:36 GMT
  7. References: <ARA.92Sep6131908@camelot.ai.mit.edu> <1992Sep6.232408.11684@zooid.guild.org>
  8. Distribution: comp
  9. Organization: University of Texas at San Antonio
  10. Lines: 36
  11.  
  12. In article <1992Sep6.232408.11684@zooid.guild.org> ross@zooid.guild.org (Ross Ridge) writes:
  13. >ara@zurich.ai.mit.edu (Allan Adler) writes:
  14. [...]
  15. >>First, it seems to me that every compiler and every assembler must have its
  16. >>own idiosyncratic way of producing the executable. Is that true?
  17. >
  18. >For compilers yes, for assemblers no.  With assemblers every byte of
  19. >the execuatable is under the programmers control.
  20.  
  21. Actually, assemblers have their own way of producing executables, too.
  22. There is a share-ware assembler (I think it is called A86) that even
  23. says that it creates opcodes different from other assemblers.  This
  24. way, the author can sue unregistered owners for not registering.
  25. There are different ways an assembler can create a "fingerprint".
  26. One example is ``MOV BX, AX''.  An assembler can generate either
  27. ``89h C3h'' or ``8Bh D8h'' for the opcode (I don't have A86, so I
  28. don't know which opcode set it uses for ``MOV BX, AX'').
  29.  
  30. Likewise, an assembler can optimize the code for speed and/or size.
  31. For example, I have TASM, which converts a far call into the same
  32. segment into a push cs and near call.
  33.  
  34. TASM also automatically generates code for you, such as when using
  35. Language modifiers.  For example, you can call a C function from
  36. your ASM program.  TASM will push your parameters (using the C
  37. parameter passing protocol), make the call, then adjust the stack
  38. for you.
  39.  
  40. [...]
  41.  
  42.  
  43. -- 
  44. ==== Mike Levis   mlevis@ringer.cs.utsa.edu ====
  45. ::   ftp ftp.cs.widener.edu (147.31.254.132)  ::  .--.
  46. ::   for ``The Simpsons'' information.  Get   :: (OS/2)
  47. :::: ``Simpsons'' FAQL in dir /pub/simpsons ::::  ~--~
  48.