home *** CD-ROM | disk | FTP | other *** search
/ AMIGA PD 1 / AMIGA-PD-1.iso / Programme_zum_Heft / Programmieren / Kurztests / Barfly / Docs / Barfly.man < prev    next >
Text File  |  1995-03-14  |  185KB  |  6,347 lines

  1. This file documents Barfly, a development system for AmigaOS V2.04 or
  2. newer.
  3.  
  4.  
  5.  
  6.                               Barfly 1.0
  7.  
  8.        An Intuition controled Debugger and Optimizing Assembler
  9.  
  10.                   Copyright (c) 1989-94 Ralph Schmidt
  11.  
  12.                              - Shareware -
  13.  
  14. Basic Informations
  15. ******************
  16.  
  17. Copyright and other legal stuff
  18. ===============================
  19.  
  20.    Copyright (c) 1989-94 Ralph Schmidt
  21.  
  22.    Permission is granted to make and distribute verbatim copies of this
  23. manual provided the copyright notice and this permission notice are
  24. preserved on all copies.
  25.  
  26.    No guarantee of any kind is given that the programs described in
  27. this document are 100% reliable. You are using this material at your
  28. own risk. The author *can not* be made responsible for any damage which
  29. is caused by using these programs.
  30.  
  31.    Permission is granted to include this package in Public-Domain
  32. collections, especially in Fred Fishs Amiga Disk Library (including
  33. CD-ROM versions of it).  The distribution file may be uploaded to
  34. Bulletin Board Systems or FTP servers. If you want to distribute this
  35. program you *must* use the original distribution archive `Barfly.lha'.
  36.  
  37.    *None* of the programs may be included or used in commercial programs
  38. unless by written permission from the author.
  39.  
  40.    *None* of the programs may be modified in any way. This especially
  41. includes changing the copyright notices or removing any of the Shareware
  42. restrictions.
  43.  
  44.    *None* of the programs may be used on any machine which is used for
  45. the research, development, construction, testing or production of
  46. weapons or other military applications. This also includes any machine
  47. which is used for training persons for *any* of the above mentioned
  48. purposes.
  49.  
  50.    *None* of the programs may be used by more than the registrated
  51. owner.
  52.  
  53. Registration
  54. ============
  55.  
  56.    As you may have noticed in the copyright I'm working for five years
  57. at Barfly. It has always consumed and will continue to consume a large
  58. amount of my time.
  59.  
  60.    I cannot afford just working for fun. Thus, I decided to release
  61. Barfly as Shareware. I had already tried to release Barfly as a
  62. commercial product but the story behind it is more than sad. To sum
  63. it...german Amiga software companys aren't worth any time...`they suck'.
  64. Some people may think the price is too high for a Shareware product but
  65. i think that BAsm is as powerful as the 2 main available commercial
  66. Assemblers...if not more powerful if you compare the speed and the
  67. optimize functions;there's no commercial Debugger available that can
  68. compete with BDebug.  I've used Barfly myself for commercial Amiga
  69. applications.  Cyberstorm 060, Z3-Fastlane device, CDRive,
  70. SCSIConfig,...
  71.  
  72.    The unregistered version of Barfly pops up the About requester at
  73. the start and has some functions disabled:
  74.      Assembler:
  75.       o only 8192Bytes large code possible
  76.       o the Section commands aren't available
  77.      Debugger:
  78.       o Only 1 Window per Object
  79.       o Enforcer,CyberGuard Catch not available
  80.       o Task Catch not available
  81.       o Crashed Task Catch not available
  82.       o Limited Step count(about 150-200 Steps)
  83.  
  84.    Registered users will be shipped a disk with the newest public
  85. release of Barfly, along with a personalized, so-called "keyfile". It
  86. enables all the missing features and disables the Shareware reminders.
  87. This keyfile will work with all future releases of Barfly, so you can
  88. simply download the latest version from your local bulletin board
  89. without having to wait weeks for your update passing through the slow
  90. mail channels. The keyfile `must not' be distributed in any way.
  91.  
  92. The fee for a Barfly registration is
  93.       70.- DM  (D-Mark),
  94.       70.- SFr (Schweizer Franken),
  95.      230.- FF  (French Francs),
  96.       50.- US$ (US Dollar)
  97.  
  98.    The fastest, cheapest and easiest way to register is put the money
  99. together with the filled registration form into a letter and send it to
  100.  
  101.    Please allow 2-5 weeks delivery for the registrated version.
  102.  
  103.      Ralph Schmidt
  104.      Kleiner Hellweg 4
  105.      33154 Salzkotten
  106.      FR Germany
  107.      Phone: +49-5258-5637
  108.      E-Mail: laire@uni-paderborn.de
  109.         Irc: Laire on #amiga,#amigager
  110.  
  111. Introduction
  112. ************
  113.  
  114. Purpose
  115. =======
  116.  
  117.    BDebug is an Intuition controled multi-task system Debugger for OS
  118. 2.04 and newer.
  119.  
  120.    You can use BDebug to debugging your programs, catching tasks,
  121. reseach Enforcer and CyberGuard hits, follow Source-Level Informations
  122. and other advanced functions.  The Debugger supports assemblers, SAS C,
  123. Dice and GCC.
  124.  
  125. Some of BDebug's features are:
  126.  
  127.    * font-sensitive, resizable and Style Guide compliant GadTools GUI
  128.  
  129.    * Object-Oriented that results in a low learning curve
  130.  
  131.    * Supports 68000...68060 and the FPUs
  132.  
  133.    * Can debug multiple tasks at the same time
  134.  
  135.    * Not limited by the amount of window objects.
  136.  
  137.    * highly configurable
  138.  
  139.    * keyboard support
  140.  
  141.    BAsm is a very fast optimizing Assembler for OS 2.04 and newer.
  142.  
  143. Some of BAsm's features are:
  144.  
  145.    * 68000-68060, 6888x
  146.  
  147.    * Very Fast
  148.  
  149.    * Include and Incbin Cache
  150.  
  151.    * Strong Optimizer with Multi-Pass Optimizing
  152.  
  153.    * High Level Macros
  154.  
  155.    * ARexx
  156.  
  157.    * Supports OS 2.04 and OS 3.0 Hunks
  158.  
  159.    * SAS D1 Source Level Format
  160.  
  161. System requirements
  162. ===================
  163.  
  164.    Barfly requires Amiga operating system version 2.04 or better.
  165.  
  166.    Kickstart 1.3 is *not* supported; this operating system is considered
  167. obsolete.
  168.  
  169.    Barfly requires at least one megabyte of RAM to run.  A hardisk or a
  170. faster CPU is not required but increase performances and comfort, of
  171. course.
  172.  
  173. Installation
  174. ============
  175.  
  176.    It is really easy to install Barfly:
  177.  
  178.    1. Copy the the binary and the icon (called "BDebug" and
  179. "BDebug.info")   to any directory.
  180.  
  181.    2. Copy the the binary and the icon (called "BAsm" and "BAsm.info")
  182. to any directory.
  183.  
  184.    Then copy the supplied configuration files from "s/Barfly/#?" to "S:"
  185. directory of your system partition or create env:Barflypath with the
  186. path to a directory that contains Barfly/#?.
  187.  
  188. Other topics
  189. ************
  190.  
  191. Updates
  192. =======
  193.  
  194.    Whenever a new release of Barfly gets released, I will post some
  195. information in the appropriate newsgroups of some electronic networks.
  196. The new archive will soon be available on many bulletin boards and on
  197. all `AmiNet' FTP servers. Major releases will also come with some PD
  198. disks, especially on Fred Fish's collection.
  199.  
  200.    As mentioned above, registered users will neither need a new keyfile
  201. nor a special personalized program version. They can use all new
  202. features immediately.
  203.  
  204. Support
  205. =======
  206.  
  207.    If you have some questions, comments, suggestions or even flames,
  208. please feel free to contact me at one of the following addresses. If
  209. you send your letter via e-mail, there's a good chance for getting a
  210. quick reply.
  211.  
  212.      Snailmail: Ralph Schmidt
  213.                 Kleiner Hellweg 4
  214.                 33154 Salzkotten
  215.                 FR Germany
  216.      
  217.          Phone: +49-5258-5637
  218.      
  219.         E-Mail: laire@uni-paderborn.de
  220.            Irc: Laire on #amiga, #amigager
  221.  
  222. History
  223. =======
  224.  
  225.    * 0.0 - 1.0
  226.      not released
  227.  
  228. Future
  229. ======
  230.  
  231. Here are some ideas for future versions of BDebug:
  232.  
  233.    * Full Source Level support for GCC and perhaps SAS.
  234.  
  235.    * Better BDebug Arexx support...the current one is a bad excuse.
  236.  
  237.    * Mungwall Trace methods.
  238.  
  239.    * Automatic Refresh of some Windows(Task Window...)
  240.  
  241.    * Amigaguide file mode in the autodocs functions.
  242.  
  243.    * Highlight changed registers
  244.  
  245.    * Better documentation.
  246.  
  247.    * BAsmOption for the easy BAsm options configuration.
  248.  
  249.    * Other things i'm too lazy to mention now.
  250.  
  251. Important:
  252.      There is absolutely NO guarantee that these features will ever be
  253.      implemented. So don't be disappointed, if they aren't in the next
  254.      version.
  255.  
  256. Acknowledegments
  257. ================
  258.  
  259. Thanks must go to:
  260.  
  261.    - Dirk Leschner, Frank Jakobs
  262.  
  263.      for being my best friends
  264.  
  265.    - Matthias Scheler
  266.  
  267.      for his manual design and Filer.
  268.  
  269.    - S.Schaem, Børge Nøst, Alexis Wilke, Michael B. Smith, Marc Heuler
  270.  
  271.      for their superb betatesting efforts
  272.  
  273.    - Mike Schwartz
  274.  
  275.      for a lot suggestions to improve basm. Sad he has left the Amiga
  276.      community 2 years ago.
  277.  
  278.    - Stefan Becker
  279.  
  280.      for Toolmanager and being a nice guy.
  281.  
  282.    - Christoph Wolf
  283.  
  284.      for DynamiCache and being a nice guy.
  285.  
  286.    - Brian Cerveny(Redwine)
  287.  
  288.      for Grapevine and being a nice guy.
  289.  
  290.    - All my IRC friends.
  291.  
  292.      for many great hours. Thanks!
  293.  
  294.      Andrew Denton(Guardian), Kenneth Dyke(Nyx), Bill Coldwell(Cryo),
  295.      Brian Cerveny(Redwine), Joseph Hillenburg(xterm), Scott
  296.      Ellis(ScottE), Chris Wichura(Caw), John Wiederhirn(John\_W), Mike
  297.      Schwartz(mykes), Markus Illenseer(ill), Petra Zeidler(stargazer),
  298.      Michael van Elst(mlelstv), Holger Lubitz(holgi), Ralph
  299.      Babel(rbabel), Seth Harman(Budha) and a lot guys i haven't
  300.      mentioned here.
  301.  
  302.    - Chris Schneider and Urban D. Mueller
  303.  
  304.      for some suggestions 2-3 years ago and installing Aminet.
  305.  
  306.    - Michael "billy" Böhnisch
  307.  
  308.      for his cleanup on MakeBarflyFD 2-3 years ago.
  309.  
  310.    - Steve Wright
  311.  
  312.      for designing the icons 2 years ago.
  313.  
  314. And of course to all the other Beta testers and registered users.
  315.  
  316.    The V40 Includes can be ftp'ed from the FTP-Server.
  317.  
  318.    ftp.rz.uni-wuerzburg.de: pub/amiga/frozenfish/bbs/com
  319.  
  320.    A superb Linker "lk" by Alex Wilke should be soon availble on Aminet.
  321.  
  322.                               BDebug 1.0
  323.  
  324.                     An Intuition controled Debugger
  325.  
  326.                   Copyright (c) 1989-94 Ralph Schmidt
  327.  
  328.                              - Shareware -
  329.  
  330. Usage of BDebug
  331. ***************
  332.  
  333. The Command Window
  334. ==================
  335.  
  336. Debugger Philosophy
  337. ===================
  338.  
  339.    BDebug is a multitasking Debugger that supports the Motorola
  340. processors 68000...68060 and 68881...68882.  The Debugger allows to
  341. debug unlimited tasks parallel.  Because of the Debugger's complexity
  342. BDebug was designed in an object-oriented way to allow an easy and
  343. comfortable way to use it.  The register window `REGWindow' is the Root
  344. class of the task object that can be expanded by several subclass
  345. windows.  Every subclass window has privat menus and inherits the
  346. public menus of its father object.
  347.  
  348. Debug Methods
  349. =============
  350.  
  351.    The Debugger offers a variety of different Debug methods that can be
  352. activated by menu or gadget.
  353.  
  354. Debug Task
  355. ..........
  356.  
  357.    is used to select a task you wann to debug. If you doubleclick on a
  358. task a `REGWindow' and a couple of information windows opens.  Which
  359. type and how many are opened depends on the current configuration.
  360. After the task could be stopped the contents of the `REGWindow' and all
  361. other information windows gets refreshed.  If the task is in the `Wait'
  362. state the task is stopped when it gets a signal.
  363.  
  364.                          Task Listview Layout
  365.  
  366.                                    
  367.   Taskaddress      &     Priority     &     Status     &     [!]Name
  368.  
  369.                                    
  370.        A process is marked by `!' at the beginning of the name.
  371.  
  372.    You should know what task you can stop and what kind of task should
  373. never be stopped. For example the Input.device should never be stopped.
  374.  
  375. Debug File
  376. ..........
  377.  
  378.    is used to load and stop a program.  This function is equal to the
  379. bdebug cli startup with the exception that you can enter the parameter
  380. in a requester.  If no error occur all configurated windows are opened
  381. and the PC stops at the defined programstart breakpoint that normally
  382. points to the first command of the program.
  383.  
  384. Debug Next Task
  385. ...............
  386.  
  387.    is used to debug the next task that is opened.  The Debugger waits
  388. until another task is created by AddTask and a couple of information
  389. windows opens.  Which type and how many are opened depends on the
  390. current configuration.  After the new task was caught the pc points to
  391. the beginning of the task and `Catch Next Task' is disactivated.  To
  392. catch a program that is started from the WV you have to use `Debug Next
  393. Task' to catch the WB Startup Task `WBL' that starts the program.  Now
  394. you have to activate `Debug Next Task' again and let the current task
  395. run.  After a short time the task `WBL' ends and the program's task is
  396. caught.
  397.  
  398.      You should avoid to start a new task between the 2 `Debug Next
  399.      Task' phases because it's easy to catch the wrong one.
  400.  
  401.  
  402.      You should notice that `AddTask' is patched and points to a new
  403.      routine. Thus you should be careful with programs that also patch
  404.      `AddTask'. Furthermore it's useful to know in what sequences these
  405.      patches have to be removed.  The Debugger can only be closed when
  406.      all patched system function that were installed after the Debugger
  407.      was started are removed.
  408.  
  409.  
  410.      If you start a program in the shell without `c:Run' no new task is
  411.      created. Instead the program is run as a subroutine in shell's
  412.      task so you can't catch the task that easy.
  413.  
  414.  
  415. Debug Crashed Task
  416. ..................
  417.  
  418.    is used to catch tasks that crash so you track down the bug location
  419. a lot easier. If the system itself doesn't run anymore you shouldn't
  420. expect that bdebug still runs because it depends on a working system.
  421. If a task crashes and the option `Debug Crashed Task' is activated a
  422. couple of information windows opens. Which type and how many are opened
  423. depends on the current configuration.  `Task Held Requester'.
  424.  
  425. Catch Enforcer Hit
  426. ..................
  427.  
  428.    is used to tell the Debugger to stop the task it controls when an
  429. Enforcer or CyberGuard hit happens.  Unfortunately the Debugger can't
  430. always stop the task at exactly the same location where the hit
  431. happened.  Mostly the hit command is 1-2 instructions above the stopped
  432. task's PC.
  433.  
  434.    This function needs Enforcer V37.x by M. Sinz or CyberGuard V1.x and
  435. it must be installed before BDebug is launched.  Please read the
  436. documentation.
  437.  
  438. Select Display Mode
  439. ...................
  440.  
  441.    This function allows you to choose Screen Mode for the Debugger.
  442.  
  443. How to start ?
  444. ==============
  445.  
  446.    If you only want to debug a program you have to start bdebug with
  447. the program's name and parameters or by using `Debug Program' in the
  448. command window.  Another method is to move a program's icon on the
  449. command window or specify BDebug as in the icon as the `DefaultTool'.
  450.  
  451.    `Name:'
  452.  
  453.      BDEBUG - The CLI Startup
  454.  
  455.  
  456.    `Synopnis:'
  457.  
  458.      BDEBUG [?] [<Program> [Argument] ]
  459.  
  460.  
  461.    `Function:'
  462.  
  463.      BDebug activates the Debugger, loads and stops the optionally
  464.      entered program. If it can find a local config file with  the
  465.      suffix *.bdebug it loads it.
  466.  
  467.  
  468.    `Inputs'
  469.  
  470.         * ? shows an information message
  471.  
  472.         * program name If no program name is entered BDebug looks for
  473.           env:BDebugProgram and loads the program instead that the env:
  474.           points to.
  475.  
  476.         * argument line of the program. If there are spaces in
  477.           parameters you have to enclose the argument with `""'.
  478.  
  479.  
  480. Usage of BDebug
  481. ***************
  482.  
  483. The Register Window
  484. ===================
  485.  
  486. Register Window
  487. ---------------
  488.  
  489.    The register window is the most important control layer of the
  490. Debugger and every debugged task has one.  You can link unlimited other
  491. information windows to the `REGWindow' or you can tell the Debugger to
  492. give up controling the task.  In the title line of the window you can
  493. see the ID number of the task, so you can recognize what information
  494. window belongs to this task.  Furthermore the title line also contains
  495. the task address, the state, `RUN', `WAIT' or `STOP' and the name of
  496. the task.  The task is in the `RUN' state if the task has the control
  497. at the moment instead of the traphandler; the task is in the `STOP'
  498. state when the task waits and the traphandler controls what happens.
  499. The task is the `WAIT' state only when the Debugger has to wait to
  500. catch a task by a `Debug Task'.  In the upper area of the window you
  501. see the normal data and address registers where the address register
  502. also have additional information fields.  To change a register or to
  503. watch memory where the register points to you only need to doubleclick
  504. on the register or on the register's memory contents.  Furthermore you
  505. may change other usermode registers by this method.  Supervisor
  506. register can't be changed because that doesn't make much sense for a
  507. system Debugger.
  508.  
  509.                            `68000 Registers'
  510.  
  511.              D0=xxxxxxxx yyyy A0=xxxxxxxx   Arg1 Arg2 [!]
  512.  
  513.              D1=xxxxxxxx yyyy A1=xxxxxxxx   Arg1 Arg2 [!]
  514.  
  515.              D2=xxxxxxxx yyyy A2=xxxxxxxx   Arg1 Arg2 [!]
  516.  
  517.              D3=xxxxxxxx yyyy A3=xxxxxxxx   Arg1 Arg2 [!]
  518.  
  519.              D4=xxxxxxxx yyyy A4=xxxxxxxx   Arg1 Arg2 [!]
  520.  
  521.              D5=xxxxxxxx yyyy A5=xxxxxxxx   Arg1 Arg2 [!]
  522.  
  523.              D6=xxxxxxxx yyyy A6=xxxxxxxx   Arg1 Arg2 [!]
  524.  
  525.              D7=xxxxxxxx yyyy A7=xxxxxxxx   Arg1 Arg2 [!]
  526.  
  527.            USP=xxxxxxxx  SSP=xxxxxxxx  PC=xxxxxxxx  SR=xxxx
  528.  
  529.    * [!] shows if the address register points on an odd address.
  530.  
  531.    * if the address register points on an illegal memory area the char
  532.      `*' is shown in Arg1 and Arg2 to avoid crashes by reading non
  533.      readable io-addresses.  You can config the readable memory areas.
  534.  
  535.    * if the address register points on the following system structures
  536.      the name of the Node is shown in Arg1 and the Name of the
  537.      structure in Arg2.
  538.  
  539.         * Library
  540.  
  541.         * Device
  542.  
  543.         * Port
  544.  
  545.         * Task
  546.  
  547.         * Resource
  548.  
  549.         * MemHead
  550.  
  551.    * if the address register points to the custom chip area the name of
  552.      the register is shown in Arg1 and the ID-Word CUSTOM is shown in
  553.      Arg2.  Custom register map is $dff000-$dff200.
  554.  
  555.    * if the address register points to a symbol the symbol and the
  556.      contents is shown.
  557.  
  558.    * Otherwise 8Bytes of the memory are shown where the register points
  559.      to.  The 8 Bytes are shown hexadecimal in Arg1 and ascii in Arg2.
  560.  
  561.                            `68010 Registers'
  562.  
  563.                VBR=xxxxxxxx  SFC=xxxxxxxx  DFC=xxxxxxxx
  564.  
  565.                            `68020 Registers'
  566.  
  567.                VBR=xxxxxxxx  SFC=xxxxxxxx  DFC=xxxxxxxx
  568.  
  569.         MSP=xxxxxxxx  ISP=xxxxxxxx CACR=xxxxxxxx CAAR=xxxxxxxx
  570.  
  571.                            `68030 Registers'
  572.  
  573.                VBR=xxxxxxxx  SFC=xxxxxxxx  DFC=xxxxxxxx
  574.  
  575.         MSP=xxxxxxxx  ISP=xxxxxxxx CACR=xxxxxxxx CAAR=xxxxxxxx
  576.  
  577.                CRP=xxxxxxxxxxxxxxxx SRP=xxxxxxxxxxxxxxxx
  578.  
  579.            TT0=xxxxxxxx  TT1=xxxxxxxx   TC=xxxx PSR=xxxxxxxx
  580.  
  581.                            `68040 Registers'
  582.  
  583.                VBR=xxxxxxxx  SFC=xxxxxxxx  DFC=xxxxxxxx
  584.  
  585.                MSP=xxxxxxxx  ISP=xxxxxxxx CACR=xxxxxxxx
  586.  
  587.           URP=xxxxxxxx  SRP=xxxxxxxx   TC=xxxx  PSR=xxxxxxxx
  588.  
  589.         ITT0=xxxxxxxx ITT1=xxxxxxxx DTT0=xxxxxxxx DTT1=xxxxxxxx
  590.  
  591.                            `68060 Registers'
  592.  
  593.                VBR=xxxxxxxx  SFC=xxxxxxxx  DFC=xxxxxxxx
  594.  
  595.               CACR=xxxxxxxx  PCR=xxxxxxxx BUSCR=xxxxxxxx
  596.  
  597.           URP=xxxxxxxx  SRP=xxxxxxxx   TC=xxxx  PSR=xxxxxxxx
  598.  
  599.         ITT0=xxxxxxxx ITT1=xxxxxxxx DTT0=xxxxxxxx DTT1=xxxxxxxx
  600.  
  601.                            Type  Information
  602.  
  603.               xxxxxxxx  [Symbol] Mnemonic operand1[,...]]
  604.  
  605.             (EA): [Address1=Contents]...[Address2=Contents]
  606.  
  607.      In the `(EA)' line you can see the addresses and their contents
  608.      the current command accesses.  The contents of illegal addresses
  609.      aren't shown.
  610.  
  611. Local Menus
  612. -----------
  613.  
  614.    * Close Window
  615.  
  616.      closes the `REGWindow', all connected windows and disactivates the
  617.      Debugger for this task.  To disactivate the Debugger you have to
  618.      choose if the task should keep running so it's the task's business
  619.      to stop.  Furthermore you can end the task by runing the cleanup
  620.      routine of the task or just removing the task from the list but
  621.      this can cause sideeffects you can't always oversee.  If the task
  622.      is a process then the Remove option is equal to the Cleanup option.
  623.      If it's only a task the Cleanup option is equal to the Cleanup
  624.      option.  Note that the Remove option doesn't free any resources of
  625.      the task.
  626.  
  627.           You should really know what you're doing if you, for example,
  628.           remove a task from the system.
  629.  
  630.  
  631.    * ZOOM Windows
  632.  
  633.      expands all windows of the task.
  634.  
  635.    * Log File
  636.  
  637.      activates or disactivates the loging of the register and PC
  638.      changes.
  639.  
  640.    * Big View
  641.  
  642.      shrinks the `REGWindow' to a 68000 register layout or expands it
  643.      back to the full layout.
  644.  
  645.    * Open DissWindow
  646.  
  647.      opens a DissWindow with the configured dimensions.
  648.  
  649.    * Open MemWindow
  650.  
  651.      opens a MemWindow with the configured dimensions.
  652.  
  653.    * Open FPUWindow
  654.  
  655.      opens a FPUWindow with the configured dimensions.  The menu is
  656.      only available if a FPU is installed.
  657.  
  658.    * Open BreakWindow
  659.  
  660.      opens a BreakpointWindow with the configured dimensions.
  661.  
  662.    * Open CoppWindow
  663.  
  664.      opens a CoppWindow with the configured dimensions.
  665.  
  666.    * Open StructWindow
  667.  
  668.      opens a StructWindow with the configured dimensions.
  669.  
  670.    * Open SnoopWindow
  671.  
  672.      opens a SnoopWindow with the configured dimensions.
  673.  
  674.    * Open WatchWindow
  675.  
  676.      opens a WatchpointWindow with the configured dimensions.
  677.  
  678.    * Open ChecksumWindow
  679.  
  680.      opens a ChecksumWindow with the configured dimensions.
  681.  
  682.    * Save Window Settings
  683.  
  684.      saves the positions and count of all window the current task
  685.      controls.  The saved file then contains the appropriate commands
  686.      you have to enter yourself into the configuration file.  Because
  687.      of the Debugger's window concept it doesn't make sense to save a
  688.      complete configuration file.
  689.  
  690. Public Menus
  691. ------------
  692.  
  693.    * Step 1
  694.  
  695.      runs the current command and stops the task afterwords.
  696.  
  697.    * Step X
  698.  
  699.      runs X commands and stops the task afterwards.
  700.  
  701.    * Step Debug Line
  702.  
  703.      runs commands until the PC encounters another source line.  If the
  704.      PC is outside the program or if no debug informations are
  705.      available a single step i used.  The command enters subroutines.
  706.  
  707.    * Trace Debug Line
  708.  
  709.      is similar to `Step Debug Line' with the exception that it runs
  710.      subroutines.
  711.  
  712.    * Trace over Calls
  713.  
  714.      runs the current command or subroutine and stops the task
  715.      afterwards.  Depending on the configuration and the memory area a
  716.      breakpoint or single steps are used.  If a crash happens in
  717.      certain program parts you should remove the command `Tracebreak'
  718.      from the configuration.
  719.  
  720.           You should avoid to use `Tracebreak' in Libraries and Devices
  721.           which are located in the ram.  If another task accesses the
  722.           routine at the same time you can expect an illegal exception.
  723.  
  724.  
  725.           Some Amiga MMU Setups don't like programs writing to the
  726.           kickstart rom. For example when breakpoints are set.
  727.  
  728.  
  729.    * Trace X over Calls
  730.  
  731.      runs X commands or subroutines and stops the task afterwards.
  732.      Depending on the configuration and the memory area a breakpoint or
  733.      single steps are used.
  734.  
  735.    * Trace Work
  736.  
  737.      is similar to the command `Trace over Calls' with the exception
  738.      that all commands are run.  This function is useful to trace loops.
  739.  
  740.  
  741.           Example:
  742.                      moveq        #10,d0
  743.                  0$:
  744.                      dbra         d0,0$
  745.  
  746.           If you use the function on the command `dbra' the Debugger
  747.           sets a breakpoint after the dbra and runs the task. It drops
  748.           back to single step when it hits a `Jmp', `bra', `rts'....
  749.  
  750.  
  751.    * Trace over OS-Calls
  752.  
  753.      runs the current command or the OS function and stops the task
  754.      afterwards.
  755.  
  756.    * Trace on Flow
  757.  
  758.      stops the task when a PC direction occurs.  This means the PC is
  759.      stopped when it hits a `Jsr', `Jmp', `bcc', `rts'....
  760.  
  761.    * Trace on Address
  762.  
  763.      runs the task until the PC is equal to the entered address.  This
  764.      function is not very fast because the task is running in single
  765.      step mode and after each instruction the PC is compared with the
  766.      address.
  767.  
  768.    * Trace out of OS
  769.  
  770.      runs the task until the PC is outside of the kickstart.  This
  771.      function is useful when you catch a task inside the OS and you
  772.      want to get as fast as possible back to the program's code.  It
  773.      works similar as `Trace on address'.
  774.  
  775.           You shouldn't use this command if your task only runs in the
  776.           kickstart.
  777.  
  778.  
  779.    * (PC)++
  780.  
  781.      jumps over the current command.  Useful to jump over `Illegal'
  782.      breakpoints used for debugging purposes in your program.
  783.  
  784.    * PC-2
  785.  
  786.      subtracts 2 Bytes from the PC.
  787.  
  788.    * Write Nop
  789.  
  790.      overwrites the current command with a `Nop'.
  791.  
  792.    * Write Illegal
  793.  
  794.      overwrites the current command with an `Illegal'.
  795.  
  796.    * Run Task
  797.  
  798.      runs the task and stops only on exceptions.
  799.  
  800.    * Run Watched Task
  801.  
  802.      runs the task in trace mode and stops when a WatchPoint condition
  803.      is true.  If there are no watchpoints the command behaves like
  804.      `Run Task'.
  805.  
  806.    * Run History Task
  807.  
  808.      runs the task in trace mode and saves the registers each step into
  809.      the history stack.
  810.  
  811.    * Stop Task
  812.  
  813.      stops the task.
  814.  
  815.    * Send Signal
  816.  
  817.      sends a signal to the task.  Default Signal is CTRL-C = 12
  818.  
  819.    * Undo Level
  820.  
  821.      sets the undobuffer's depth.
  822.  
  823.    * Undo
  824.  
  825.      undos the last changes in the registerframe.
  826.  
  827.    * View Refresh
  828.  
  829.      activates and disactivates the copperlist refresh after each trace
  830.      operation. This function is help for debugging programs which
  831.      install own copperlists.
  832.  
  833.    * Show (EA)
  834.  
  835.      activates and disactivates the output of the address and address
  836.      contents which are accessed by the current assembler command.
  837.  
  838.    * Symbol
  839.  
  840.      activates and disactivates the use of symbols in the `REGWindow'.
  841.  
  842.    * Delete Symbols
  843.  
  844.      erases all symbols of the task.
  845.  
  846.    * Copy Symbols
  847.  
  848.      can copy a symbol list of the task to a different task.  This
  849.      function is helpful if your task is started from another task and
  850.      you want to keep the symbol list.
  851.  
  852.    * Load Symbols
  853.  
  854.      loads the symbols of a program where you can select an alternative
  855.      process's segmentlist for calculating the symbol and debug
  856.      informations.  Normally you choose the same process but sometimes
  857.      it's helpful to select a different process.  For example, if the
  858.      task you debug is created in a program, you have to choose the
  859.      program's task to get the correct symbol addresses.
  860.  
  861.    * Set Hunklist
  862.  
  863.      sets a new segment list for the SourceWindow and some other hunk
  864.      related functions.  Because the position in the SourceWindow
  865.      depends on the segments sometimes help to load new symbols and
  866.      debug informations for this task.  If you load an alternative
  867.      Hunklist by selecting a custom task when you use `Load Symbols'.
  868.  
  869.    * Reset Hunklist
  870.  
  871.      removes the alternative hunklist.
  872.  
  873.    * Show Value
  874.  
  875.      shows the value of an argument.
  876.  
  877.    * Show Last Exception
  878.  
  879.      shows the last exception.
  880.  
  881.    * Open Task Window
  882.  
  883.      opens a window showing the task structure of the task.
  884.  
  885.    * Open System Window
  886.  
  887.      opens a window showing the ExecBase structure.
  888.  
  889.    * Open Proces Window
  890.  
  891.      opens a window showing the process structure of the process.
  892.  
  893.    * Open CLI Window
  894.  
  895.      opens a window showing the cli structure of the process.
  896.  
  897.    * Open Hunk Window
  898.  
  899.      opens a window showing the hunks of the process.
  900.  
  901.    * Open Symbol Window
  902.  
  903.      opens a window showing the symbols of the process.  If you
  904.      doubleclick on a symbol you get the hunk where the symbol is
  905.      located.
  906.  
  907.    * Open Library Window
  908.  
  909.      opens a window showing the libraries.  If you doubleclick on a
  910.      library entry it opens a `FD:' window that shows all functions of
  911.      the library when the library is defined in the `Barfly.FD' file.
  912.      Furthermore if you doublelick on a function you have the choice to
  913.      see the function in a `DissWindow' or the autodocs documentation.
  914.  
  915.    * Open Device Window
  916.  
  917.      opens a window showing the devices.
  918.  
  919.    * Open Resource Window
  920.  
  921.      opens a window showing the resources.
  922.  
  923.    * Open Port Window
  924.  
  925.      opens a window showing the public ports.
  926.  
  927.    * Open Resident Window
  928.  
  929.      opens a window showing the resident modules.
  930.  
  931.    * Open Interrupt Window
  932.  
  933.      opens a window showing the interrupts.
  934.  
  935.    * Open AutoDocs Window
  936.  
  937.      opens a filerequester which lets you choose the needed autodocs
  938.      information of a library.  This opens a window which shows all
  939.      functions of the chosen autodoc file.  If you now click on a
  940.      function another window is opened showing the function
  941.      documentation.
  942.  
  943.    * Open History Window
  944.  
  945.      opens a HistoryWindow showing the last saved registerframes of the
  946.      undobuffer. The undobuffer is organized in a way to make the first
  947.      entry become the last entry in the HistoryWindow.  The
  948.      HistoryWindow isn't updated automaticlly.
  949.  
  950.    * Stack Check
  951.  
  952.      controls the stack check. A warning is displayed if the register
  953.      A7 points out of the stack bounds or points on an odd address.
  954.      The Debugger only checks the task when the task gives back the
  955.      control to the traproutine, so it's not possible to notice every
  956.      stack problem.
  957.  
  958.           You should be aware that this function doesn't work with a
  959.           WShell task because the `WShell' doesn't set the correct
  960.           stack task values.
  961.  
  962.  
  963.    * Find Task of address
  964.  
  965.      tries to find the task which belongs to the entered address.  The
  966.      command checks if the address is in the task, process, cli,
  967.      mementry structure and the hunks.  It's not safe to assume that
  968.      the function can check all cases.
  969.  
  970.    * Load Binary
  971.  
  972.      loads a file with an optional length into a memory area.  If you
  973.      want the Debugger to automaticlly allocate the memory block you
  974.      have to close the memory requester.
  975.  
  976.    * Save Binary
  977.  
  978.      saves a memory area into a file.
  979.  
  980.    * Freeze Task
  981.  
  982.      freezes a selectable task.  When bdebug ends the frozen tasks are
  983.      awakened again.
  984.  
  985.    * Warm up Task
  986.  
  987.      warms up a frozen task.
  988.  
  989.    * Kill Task
  990.  
  991.      kills a selectable task.
  992.  
  993.           You should know which task you can kill.  For example, don't
  994.           kill the input.device or your filesystem.
  995.  
  996.  
  997.    * Show Task
  998.  
  999.      shows the task structure of a selectable task.
  1000.  
  1001.    * Show Prozess
  1002.  
  1003.      shows the process structure of a selectable process.
  1004.  
  1005.    * Show CLI
  1006.  
  1007.      shows the cli structure of a selectable process.
  1008.  
  1009.    * Show Hunk
  1010.  
  1011.      shows the hunks of a selectable process.
  1012.  
  1013.    * Send Task Signal
  1014.  
  1015.      sends a signal to a selectable task.
  1016.  
  1017.    * Set Task Priority
  1018.  
  1019.      sets a priority of a selectable task.
  1020.  
  1021.    * Refresh Code Cache
  1022.  
  1023.      refreshes the Code Cache.
  1024.  
  1025.    * Refresh Data Cache
  1026.  
  1027.      refreshes the Data Cache
  1028.  
  1029. Usage of BDebug
  1030. ***************
  1031.  
  1032. The FPU Window
  1033. ==============
  1034.  
  1035. FPU Window
  1036. ----------
  1037.  
  1038.    The FPU Window shows the FPU register FP0 to FP7 in the 96Bit
  1039. Extended format and the registers FPCR, FPSR and FPIAR in hexadecimal.
  1040. You can only open this window if a FPU is available.
  1041.  
  1042.      Register Window Layout
  1043.  
  1044.                            FP0=FloatingPoint
  1045.  
  1046.                            FP1=FloatingPoint
  1047.  
  1048.                            FP2=FloatingPoint
  1049.  
  1050.                            FP3=FloatingPoint
  1051.  
  1052.                            FP4=FloatingPoint
  1053.  
  1054.                            FP5=FloatingPoint
  1055.  
  1056.                            FP6=FloatingPoint
  1057.  
  1058.                            FP7=FloatingPoint
  1059.  
  1060.                       FPCR=xxxxxxxx FPSR=xxxxxxxx
  1061.  
  1062.                             FPIAR=xxxxxxxx
  1063.  
  1064. Local Menus
  1065. -----------
  1066.  
  1067.    * Close Window
  1068.  
  1069.      closes the window.
  1070.  
  1071. Usage of BDebug
  1072. ***************
  1073.  
  1074. The Disassembler Window
  1075. =======================
  1076.  
  1077. Disassembler window
  1078. -------------------
  1079.  
  1080.    The `DissWindow' shows the memory contents in assembler mnemonics.
  1081. The address of the window's view can be absolute or relative.  In
  1082. absolut mode, the window shows the contents of a fixed address,
  1083. indicated by the window title `No Link'.  In relative mode the window
  1084. is connected to a register causing the window to update when the the
  1085. register value changes.  This is indicated by the window title which
  1086. reads `Link to *', where * represents the register name.  The PC is
  1087. shown by the colour pen 2.  If the linked register value is outside of
  1088. the window's view area the whole contents of the window will be
  1089. refreshed.  You can change size of the window and scroll through the
  1090. memory area by using the cursors.  In the title you see an ID-String
  1091. with the format `\#x.y' where `X' represents the `REGWindow' number and
  1092. `y' the number of the `MemWindow'.  Doubleclicking a line of the window
  1093. sets or remove a breakpoint.  You can disable this function in the
  1094. configuration.
  1095.  
  1096. Local Menus
  1097. -----------
  1098.  
  1099.    * Close Window
  1100.  
  1101.      closes the window.
  1102.  
  1103.    * Shrink Window
  1104.  
  1105.      shrinks the window.
  1106.  
  1107.    * Expand Window
  1108.  
  1109.      expands the window to screen size.
  1110.  
  1111.    * Link to Register
  1112.  
  1113.      links the window with a register.  If you enter the string `NO' it
  1114.      switches to absolute mode.
  1115.  
  1116.    * Change address
  1117.  
  1118.      changes the view address of the window.
  1119.  
  1120.    * Clear address
  1121.  
  1122.      resets the view address of the window.
  1123.  
  1124.    * Refresh Window
  1125.  
  1126.      refreshes the window.
  1127.  
  1128.    * .W Branches
  1129.  
  1130.      activates and disactivates the output of the old branch width size.
  1131.  
  1132.    * Neg. Offsets
  1133.  
  1134.      activates and disactivates the output of negative values in
  1135.      indirect address modes with offset.
  1136.  
  1137.    * Neg. Data
  1138.  
  1139.      activates and disactivates the output of negative values in direct
  1140.      address mode.
  1141.  
  1142.    * Opcode Data
  1143.  
  1144.      activates and disactivates the additional output of the command
  1145.      bytes.
  1146.  
  1147.    * Auto Refresh
  1148.  
  1149.      activates and disactivates the global refresh of the window after
  1150.      each step.
  1151.  
  1152.    * Symbols
  1153.  
  1154.      activates and disactivates the symbol output in the window.
  1155.  
  1156.    * Show Lib Call
  1157.  
  1158.      activates and disactivates the symbolic output of library
  1159.      functions so all library functions that are defined in the
  1160.      configuration file `<BarflyPath>/Barfly/BARFLY.FD' are recognized.
  1161.  
  1162.    * Guess Lib Call
  1163.  
  1164.      activates and disactivates the guessing of function call names.
  1165.      This only works in connection with the option `Show Lib Call'.
  1166.      Unfortunately you can't expect that the function names always fit
  1167.      because the library base register A6 can change until the program
  1168.      counter meets the function.
  1169.  
  1170.    * Mark Block End
  1171.  
  1172.      activates and deactivates marking after the instruction `JMP',
  1173.      `BRA', `RTS', `RTE', `RTD' and `RTR' to make program blocks more
  1174.      visible.
  1175.  
  1176.    * Set/Clear Breakpoint
  1177.  
  1178.      sets/removes a breakpoint on the first entry in the window.
  1179.      Breakpoints are shown by changing the pen from colour 1 to colour
  1180.      3 and the char `>' at the beginning of a line.
  1181.  
  1182.    * Pick/Clear Breakpoint
  1183.  
  1184.      sets/removes a breakpoint through a symbol list.
  1185.  
  1186.    * Disassemble to File
  1187.  
  1188.      disassembles a memory area into a file.
  1189.  
  1190. Usage of BDebug
  1191. ***************
  1192.  
  1193. The Memory Window
  1194. =================
  1195.  
  1196. Memory window
  1197. -------------
  1198.  
  1199.    The `MemWindow' shows the memory contents hexadecimal and in
  1200. ascii.You can change size of the window and scroll through the memory
  1201. area whith the cursor keys.  In the title you see an ID-String with the
  1202. format `\#x.y' where `X' represents the `REGWindow' number and `y' the
  1203. number of the `MemWindow'.
  1204.  
  1205. Local Menus
  1206. -----------
  1207.  
  1208.    * Close Window
  1209.  
  1210.      closes the window.
  1211.  
  1212.    * Shrink Window
  1213.  
  1214.      shrinks the window.
  1215.  
  1216.    * Expand Window
  1217.  
  1218.      expands the window to screen size.
  1219.  
  1220.    * Link to Register
  1221.  
  1222.      links the window with a register.  If you enter the string `NO' it
  1223.      switches to absolute mode.
  1224.  
  1225.    * Change address
  1226.  
  1227.      changes the view address of the window.
  1228.  
  1229.    * Clear address
  1230.  
  1231.      resets the view address of the window.
  1232.  
  1233.    * Refresh Window
  1234.  
  1235.      refreshes the window.
  1236.  
  1237.    * Memory Offset Step
  1238.  
  1239.      defines the data format in the window.  The following options can
  1240.      be selected: `None', `Byte', `Word' and `Long'.
  1241.  
  1242.    * Edit
  1243.  
  1244.      activates edit mode of the `MemWindow'.  In edit mode you can
  1245.      switch between hex and ascii input by the key `RETURN'. With `ESC'
  1246.      you can leave edit mode. Only the cursor right and left are
  1247.      changed to the normal.  With these both keys you can access each
  1248.      Byte.  In edit mode you can't change the size of the window.
  1249.  
  1250.    * Copy
  1251.  
  1252.      copies a memory area into another memory area.  The function uses
  1253.      `CopyMem' so it doesn't handle memory areas that overlap.
  1254.  
  1255.    * Fill
  1256.  
  1257.      fills a memory area with a value of a certain data-width.
  1258.  
  1259.    * Compare
  1260.  
  1261.      compares a memory area with another memory area.
  1262.  
  1263.    * Search
  1264.  
  1265.      searches a value of a certain data-width in a memory area.  If the
  1266.      value is found, the address and the value are displayed and you
  1267.      can goon with `Search Next' to find the next address.
  1268.  
  1269.    * Search Next
  1270.  
  1271.      Search the next value. Look at `Search'
  1272.  
  1273.    * Pred
  1274.  
  1275.      sets the address of the window tn the preceding entry of the list.
  1276.      If the node points on an odd, illegal or NULL address the command
  1277.      has no effect.  The next node is equal to `LN_PRED', the second
  1278.      longword of the memory view.
  1279.  
  1280.    * Succ
  1281.  
  1282.      sets the address of the window to the next entry of the list.  If
  1283.      the node points on an odd, illegal or NULL address the command has
  1284.      no effect.  The next node is equal to `LN_SUCC', the first longword
  1285.      of the memory view.
  1286.  
  1287. Usage of BDebug
  1288. ***************
  1289.  
  1290. The Copper Window
  1291. =================
  1292.  
  1293. CopperWindow
  1294. ------------
  1295.  
  1296.    The `CopperWindow' shows the memory contents as copper commands.
  1297. The window is sizeable, and you can use the cursor keys to scroll
  1298. through the memry area.  In the title you see an ID-String with the
  1299. format `\#x.y' where `X' represents the `REGWindow' number and `y' the
  1300. number of the `CoppWindow'.
  1301.  
  1302. Local Menus
  1303. -----------
  1304.  
  1305.    * Close Window
  1306.  
  1307.      closes the window.
  1308.  
  1309.    * Shrink Window
  1310.  
  1311.      shrinks the window.
  1312.  
  1313.    * Expand Window
  1314.  
  1315.      expands the window to screen size.
  1316.  
  1317.    * Link to Register
  1318.  
  1319.      links the window with a register.  If you enter the string `NO' it
  1320.      switches to absolute mode.
  1321.  
  1322.    * Change address
  1323.  
  1324.      changes the view address of the window.
  1325.  
  1326.    * Clear address
  1327.  
  1328.      resets the view address of the window.
  1329.  
  1330.    * Refresh Window
  1331.  
  1332.      refreshes the window.
  1333.  
  1334.    * Goto Into List
  1335.  
  1336.      sets the window list on the standard copperlist
  1337.      `GfxBase->gb_copinit'.
  1338.  
  1339. Usage of BDebug
  1340. ***************
  1341.  
  1342. The Structure Window
  1343. ====================
  1344.  
  1345. StructWindow
  1346. ------------
  1347.  
  1348.    opens window which can be connected with a structure.  You can use
  1349. new structure entries by expanding the the
  1350. `<BarflyPath>/Barfly/Barfly.Include' file or loading a new custom file.
  1351. By a doubleclick on a structure window entry you can cause several
  1352. actions depending on the datatype.  Every datatype is connected with an
  1353. action that is normally started automaticlly.  With the configuration
  1354. command `NoAutoStructAction' you can change this behaviour so that an
  1355. action type requester is opened.
  1356.  
  1357.    The following datatypes are available.
  1358.  
  1359.    * APTR opens a MemWindow.
  1360.  
  1361.    * CSTR shows a string.
  1362.  
  1363.    * BPTR opens a MemWindow at the address BPTR*4.
  1364.  
  1365.    * BSTR shows a string at the address (BPTR*4)+1
  1366.  
  1367.    * CPTR opens a DissWindow.
  1368.  
  1369.    * FPTR opens a DissWindow.
  1370.  
  1371.    * BYTE doesn't cause an action.
  1372.  
  1373.    * WORD doesn't cause an action.
  1374.  
  1375.    * LONG doesn't cause an action.
  1376.  
  1377.    * FLOAT doesn't cause an action.
  1378.  
  1379.    * DOUBLE doesn't cause an action.
  1380.  
  1381.    * EXTENDED doesn't cause an action.
  1382.  
  1383.    * RPTR doesn't cause an action.
  1384.  
  1385.    The following action types are available.
  1386.  
  1387.    * MemWindow opens a MemWindow.
  1388.  
  1389.    * DissWindow opens a DissWindow.
  1390.  
  1391.    * CoppWindow opens a CoppWindow.
  1392.  
  1393.    * StructWindow opens a StructWindow.
  1394.  
  1395.    * NewStruct sets a new structure.
  1396.  
  1397. Structure Macro Fileformat
  1398. --------------------------
  1399.  
  1400.    This section describes the file format of structure macros.  In the
  1401. beginning you define the root directory entries with the first Macro
  1402. `Menudir'.  The first parameter is the name of the entry, then the
  1403. address of the parent directory and then the address of the
  1404. subdirectory.  In the root directory the parent address is obviously
  1405. NULL.  The last entry of the directory is defined by the Macro
  1406. `MENUDIREND'.
  1407.  
  1408.      `Label                   ListViewMacro           Link'
  1409.      RootDir:
  1410.                              .
  1411.                              .
  1412.                              MENUDIR                 exec,0,Exec_Dir
  1413.                              .
  1414.                              .
  1415.      MYCUSTOMENTRY:
  1416.                              MENUDIREND              CUSTOM,0,0
  1417.  
  1418.    The design of a subdirectory only differs from the root directory
  1419. entries only by a parent directory address.
  1420.  
  1421.      `Label                   ListViewMacro           Link'
  1422.      Exec_Dir:
  1423.                              .
  1424.                              .
  1425.                              MENUDIR                 nodes.i,RootDir,Nodes_Dir
  1426.                              .
  1427.                              .
  1428.                              MENUDIREND              tasks.i,RootDir,Tasks_Dir
  1429.  
  1430.    to define the structure directory entries you have to use `MENUITEM'
  1431. and `MENUITEMEND'.  The first parameter in the Item Macros is the name
  1432. of the entry and also the name of the structure.  The second parameter
  1433. defines the address of the parent directory.
  1434.  
  1435.      `Label                   ListViewMacro           Link'
  1436.                              .
  1437.                              .
  1438.      Nodes_Dir:
  1439.                              MENUITEM                LN,Exec_Dir
  1440.                              .
  1441.                              .
  1442.                              MENUITEMEND
  1443.  
  1444.    To define a structure you can use the normal assembler syntax that
  1445. you probably have to adjust to your custom needs. For example you can
  1446. tell BDebug more informations about the datatype an entry represents.
  1447. By redefining `APTR' to a `CSTR' you can tell the Debugger that the
  1448. entry is a stringpointer.  Another example is defining that `APTR'
  1449. points to a structure by `APTR LN_SUCC,Node'.
  1450.  
  1451.      `Label                   IncludeTypeMacro        Name,Link'
  1452.      LN_Struct:
  1453.                              STRUCTUREB              LN,0
  1454.                              APTR                    LN_SUCC,LN
  1455.                              APTR                    LN_PRED,LN
  1456.                              UBYTE                   LN_TYPE
  1457.                              BYTE                    LN_PRI
  1458.                              CCSTR                   LN_NAME
  1459.                              LABEL                   LN_SIZE
  1460.  
  1461. Local Menus
  1462. -----------
  1463.  
  1464.    * Close Window
  1465.  
  1466.      closes the window.
  1467.  
  1468.    * Shrink Window
  1469.  
  1470.      shrinks the window.
  1471.  
  1472.    * Expand Window
  1473.  
  1474.      expands the window to screen size.
  1475.  
  1476.    * Link to Register
  1477.  
  1478.      links the window with a register.  If you enter the string `NO' it
  1479.      switches to absolute mode.
  1480.  
  1481.    * Change address
  1482.  
  1483.      changes the view address of the window.
  1484.  
  1485.    * Clear address
  1486.  
  1487.      resets the view address of the window.
  1488.  
  1489.    * Refresh Window
  1490.  
  1491.      refreshes the window.
  1492.  
  1493.    * Load Custom Struct
  1494.  
  1495.      loads additional structure files. The new structure entries are
  1496.      placed in the `CUSTOM' directory.  The format of custom structure
  1497.      files is equal to the file `BARFLY.INCLUDE'.
  1498.  
  1499.    * Select Structure
  1500.  
  1501.      opens the structure include directory requester where you can
  1502.      select the needed structure.  The parent gadget is placed in the
  1503.      upper border.
  1504.  
  1505.    * Goto Sysbase...
  1506.  
  1507.      sets the window address on the ExecBase.
  1508.  
  1509.    * Goto Gfxbase...
  1510.  
  1511.      sets the window address on the GFXBase.
  1512.  
  1513.    * Save Window....
  1514.  
  1515.      saves the contents of the window in a file.
  1516.  
  1517.    * Full Address
  1518.  
  1519.      this switch decides whether the `StructWindow' also shows the
  1520.      address of the entries.
  1521.  
  1522.    * Offset Address
  1523.  
  1524.      this switch decides wheather the `StructWindow' also shows the
  1525.      offset of the entries.
  1526.  
  1527.    * Pred
  1528.  
  1529.      sets the address of the window on the preceding entry of the list.
  1530.      If the node points on an odd, illegal or NULL address the command
  1531.      has no effect.  The next node is equal to `LN_PRED', the second
  1532.      longword of the memory view.
  1533.  
  1534.    * Succ
  1535.  
  1536.      sets the address of the window on the next entry of the list.  If
  1537.      the node points on an odd, illegal or NULL address the command has
  1538.      no effect.  The next node is equal to `LN_SUCC', the first longword
  1539.      of the memory view.
  1540.  
  1541. Usage of BDebug
  1542. ***************
  1543.  
  1544. The Structure Window
  1545. ====================
  1546.  
  1547. Source window
  1548. -------------
  1549.  
  1550.    The `SourceWindow' shows the source line that belongs to the window
  1551. address. If the program file doesn't have the needed debug informations
  1552. the `Source window' can't be opened. If the address points to an area
  1553. with no relevant debug information, for example the Kickstart or beyond
  1554. the program hunks, all you see is a small message.
  1555.  
  1556. Local Menus
  1557. -----------
  1558.  
  1559.    * Close Window
  1560.  
  1561.      closes the window.
  1562.  
  1563.    * Shrink Window
  1564.  
  1565.      shrinks the window.
  1566.  
  1567.    * Expand Window
  1568.  
  1569.      expands the window to screen size.
  1570.  
  1571.    * Link to Register
  1572.  
  1573.      links the window with a register.  If you enter the string `NO' it
  1574.      switches to absolute mode.
  1575.  
  1576.    * Change address
  1577.  
  1578.      changes the view address of the window.
  1579.  
  1580.    * Clear address
  1581.  
  1582.      resets the view address of the window.
  1583.  
  1584.    * Refresh Window
  1585.  
  1586.      refreshes the window.
  1587.  
  1588.    * Set Breakpoint
  1589.  
  1590.      sets a breakpoint on the active line.
  1591.  
  1592.    * Show HunkInfo
  1593.  
  1594.      shows the hunk of the current source line.
  1595.  
  1596. Usage of BDebug
  1597. ***************
  1598.  
  1599. The Snoop Window
  1600. ================
  1601.  
  1602. Snoop Window
  1603. ------------
  1604.  
  1605.    The `SnoopWindow' snoops the task's allocations.
  1606.  
  1607. Local Menus
  1608. -----------
  1609.  
  1610.    * Close Window
  1611.  
  1612.      closes the window.
  1613.  
  1614.    * Shrink Window
  1615.  
  1616.      shrinks the window.
  1617.  
  1618.    * Expand Window
  1619.  
  1620.      expands the window to screen size.
  1621.  
  1622.    * Refresh Window
  1623.  
  1624.      refreshes the window.
  1625.  
  1626.    * Auto Refresh
  1627.  
  1628.      activates/deactivates display refresh by an allocation.
  1629.  
  1630.    * Snoop Memory
  1631.  
  1632.      activates/deactivates snooping.
  1633.  
  1634.    * Snoop Mask
  1635.  
  1636.      sets the allocation filter mask.  If the Mask is set to , only
  1637.      allocations with the size 20 are recorded. Default -1.
  1638.  
  1639.    * Snoop Max Entries
  1640.  
  1641.      sets the maximal recordable snoop entries.
  1642.  
  1643. Usage of BDebug
  1644. ***************
  1645.  
  1646. The Breakpoint Window
  1647. =====================
  1648.  
  1649. Breakpoint window
  1650. -----------------
  1651.  
  1652.    The `BreakWindow' handles all breakpoints and contains the functions
  1653. that are needed with breakpoints.  In general, breakpoints are
  1654. addresses in the program where the task should be stopped.  The
  1655. breakpoints are handled globally so they aren't deleted when close the
  1656. window.
  1657.  
  1658. Local Menus
  1659. -----------
  1660.  
  1661.    * Toggle
  1662.  
  1663.      activates and deactivates all breakpoints.
  1664.  
  1665.    * All
  1666.  
  1667.      selects all breakpoints.
  1668.  
  1669.    * Clear
  1670.  
  1671.      unselects all breakpoints.
  1672.  
  1673.    * On
  1674.  
  1675.      activates all selected breakpoints.
  1676.  
  1677.    * Off
  1678.  
  1679.      deactivates all selected breakpoints.
  1680.  
  1681.    * Hit
  1682.  
  1683.      defines how often a breakpoint must be encountered before the
  1684.      program stops. Default is 1.
  1685.  
  1686.    * ?
  1687.  
  1688.      shows the hunk where the breakpoint is located and also shows if
  1689.      the breakpoint is equal to a symbol.
  1690.  
  1691.    * Input
  1692.  
  1693.      sets and removes a breakpoint.
  1694.  
  1695.    * Pick
  1696.  
  1697.      sets and removes a breakpoint using the symbol list.
  1698.  
  1699.    * Delete
  1700.  
  1701.      removes all selected breakpoint.
  1702.  
  1703.    * Goto
  1704.  
  1705.      opens a DissWindow for each selected breakpoint.
  1706.  
  1707.    * Run
  1708.  
  1709.      runs the program until the PC encounters a selected breakpoint.
  1710.  
  1711. Usage of BDebug
  1712. ***************
  1713.  
  1714. The Watchpoint Window
  1715. =====================
  1716.  
  1717. Watchpoint window
  1718. -----------------
  1719.  
  1720.    The `Watchwindow' allows to set breakpoints that aren't depending on
  1721. a certain PC address but on other conditions.  Every watchpoint has a
  1722. condition, data width and can have one of 3 different watchpoints
  1723. states.  The `Memory' watchpoint compares the saved contents of the
  1724. address with the current contents and dependent on the condition the
  1725. program is stopped or not.  The `Register' watchpoint compares the
  1726. saved contents of a register with the current contents and dependent on
  1727. the condition the program is stopped or not.  The `Argument' watchpoint
  1728. compares the saved value of an argument with the current contents and
  1729. dependent on the condition the program is stopped or not.  The last
  1730. watchpoint type is the most powerful because it can simulate the first
  1731. two types with the cost of a slowdown.  The use of watchpoints is very
  1732. time consuming because the whole program is run in single step mode.
  1733. In order to use watchpoi you have to run the task with `Run Watched
  1734. Task'.
  1735.  
  1736.      If an error occurs in the exception handler during the evaluation
  1737.      of a dynamic arugment, the screen flashes.
  1738.  
  1739.  
  1740. Local Menus
  1741. -----------
  1742.  
  1743.    * Toggle
  1744.  
  1745.      activates and deactivates all watchpoints.
  1746.  
  1747.    * All
  1748.  
  1749.      selects all watchpoints.
  1750.  
  1751.    * Clear
  1752.  
  1753.      unselects all watchpoints.
  1754.  
  1755.    * On
  1756.  
  1757.      activates all selected watchpoints.
  1758.  
  1759.    * Off
  1760.  
  1761.      deactivates all selected watchpoints.
  1762.  
  1763.    * Add
  1764.  
  1765.      opens a requester where the parameters for a watchpoint have to be
  1766.      adjusted and adds the new watchpoint to the list.  You can change
  1767.      the parameters simply by doubeclicking on a watchpoint.
  1768.  
  1769.    * Refresh
  1770.  
  1771.      refreshes the watchpoint arguments.
  1772.  
  1773.    * Check
  1774.  
  1775.      checks all selected watchpoints.
  1776.  
  1777.    * Delete
  1778.  
  1779.      removes all selected watchpoints.
  1780.  
  1781. Usage of BDebug
  1782. ***************
  1783.  
  1784. The Checksum Window
  1785. ===================
  1786.  
  1787. Checksum Window
  1788. ---------------
  1789.  
  1790.    The `ChecksumWindow' controls all checksum areas that are controlled
  1791. each time the task stops.  Helpful to find illegal random writes bugs.
  1792. The checkpoints are controled globally so they aren't deleted when you
  1793. close the window.
  1794.  
  1795. Local Menus
  1796. -----------
  1797.  
  1798.    * Toggle
  1799.  
  1800.      activates or deactivates all checksum areas.
  1801.  
  1802.    * All
  1803.  
  1804.      selects all checksum areas.
  1805.  
  1806.    * Clear
  1807.  
  1808.      unselects all checksum areas.
  1809.  
  1810.    * On
  1811.  
  1812.      activates all selected checksum areas.
  1813.  
  1814.    * Off
  1815.  
  1816.      deactivates all selected checksum areas.
  1817.  
  1818.    * Address
  1819.  
  1820.      adds a checksum area into the list.
  1821.  
  1822.    * Hunk
  1823.  
  1824.      adds a hunk of the current process into the checksum area list.
  1825.  
  1826.    * Task
  1827.  
  1828.      adds a hunk of selectable process into the checksum area list.
  1829.  
  1830.    * Refresh
  1831.  
  1832.      calculate a new checksum for all selected areas.
  1833.  
  1834.    * Delete
  1835.  
  1836.      removes all selected checksum areas.
  1837.  
  1838.    * Check
  1839.  
  1840.      checks all areas for checksum errors.
  1841.  
  1842. Usage of BDebug
  1843. ***************
  1844.  
  1845. Requester Arguments
  1846. ===================
  1847.  
  1848. Argument Structur
  1849. -----------------
  1850.  
  1851.    An argument can use absolut values, symbols and registers as
  1852. operands and the operators +,-,*,/,|,!,&,<<,>>,~.  Additionally to the
  1853. normal symbols, some special symbols are available.
  1854.  
  1855.    * By {Argument}.[b,w,l] you can read from a memory address, that is
  1856.      defined by the argument. An error is indicated if you specify an
  1857.      illegal address with isn't defined in the legal memory space.
  1858.  
  1859.    * \#d?  represents the address of the `Disswindows' with the ID ?
  1860.  
  1861.    * \#m?  represents the address of the `Memwindows' with the ID ?
  1862.  
  1863.    * \#c?  represents the address of the `Coppwindows' with the ID ?
  1864.  
  1865.    * \#h?  represents the address of the hunk ?.  Helpful for Enforcer
  1866.      and CyberGuard Hunk:Offset output
  1867.  
  1868.    * \#ea? represents the address of the EA with the number ?.  Check
  1869.      Register Window.
  1870.  
  1871.    * \#em? represents the contents where the address EA number ?
  1872.      points to.  Check Register Window. If the address EA is illegal an
  1873.      error is shown.
  1874.  
  1875.    * \#ls  represents the start address of a loaded binary file.
  1876.  
  1877.    * \#le  represents the end address of a loaded binary file.
  1878.  
  1879.    * \#ll  represents the length address of a loaded binary file.
  1880.  
  1881.    * \#p   represents the start address of the programs.  Only true for
  1882.      a loaded program.
  1883.  
  1884.    If you have the following Enforcer or CyberGuard hit output `Hunk
  1885. 0:$11c' you can calculate the address by entering the argument #h0+$11c.
  1886.  
  1887. Usage of BDebug
  1888. ***************
  1889.  
  1890. Technical Informations
  1891. ======================
  1892.  
  1893. Exceptions
  1894. ----------
  1895.  
  1896.    The Debugger can catch all exceptions if the system is still working.
  1897. If an exception is caused, the traphandler catches the exception and
  1898. tells the Debugger what went on so it can react on the exception.  If
  1899. the exception wasn't caused by the Debugger, the type and the possible
  1900. reason for the exception is shown.  The `Return-address' of the
  1901. debugged task points on an internal `ILLEGAL'. If the processor
  1902. encounters this `ILLEGAL' the task is closed and all windows are
  1903. removed.  You shouldn't step over this `ILLEGAL' because it increases
  1904. the possibility of a system crash.  If a task is caught by `Debug Next
  1905. Task' and notices a custom `finalPC' routine in the `Addtask()'
  1906. function, the `Return-address' isn't set on the internal `ILLEGAL'
  1907. cleanup function because the `finalPC' pointer is sometimes used for
  1908. parsing an argument.  In this case the Debugger notices that the task
  1909. ends by using the `RemTask()' function.
  1910.  
  1911.      If the task changes the `Return-address' the Debugger tries to
  1912.      determine the taskend by `RemTask'.
  1913.  
  1914.  
  1915. Exception Handler
  1916. -----------------
  1917.  
  1918.    Every task has a pointer in its task structure that points to its
  1919. exception handler, named `TC_TRAPCODE'.  When you load a program
  1920. through the Debugger, the Debugger's standard exception handler is
  1921. installed. It works basicly the same for `Catch Next Task' and `Debug
  1922. Task'.  The only difference is the `Debug Crashed Task' mode where the
  1923. Debugger sets a special catch exception handler in each task that isn't
  1924. controlled by the Debugger.  When an exception occurs and the
  1925. Debugger's exception handler is called the Debugger first checks if it
  1926. knows the task that caused it.  If this is not the case something
  1927. seriously is broken and the Deadend Alert 35000000 will be popped up.
  1928. If all goes well the registers are saved, the Debugger task gets a
  1929. message and the exception handler waits for a message by the Debugger
  1930. to go on.  When the Debugger gets the message it causes the appropriate
  1931. function. For example refreshing the windows.  If the Debugger gets a
  1932. step command it sends the exception handler the appropriate message and
  1933. the handler does a step.
  1934.  
  1935. Debug Informations
  1936. ------------------
  1937.  
  1938.    Currently the following formats are supported.
  1939.  
  1940.    * BASM Specialformat This format allows the Debugger to decide if
  1941.      the code is in the Mainpart, Includes or in a Macro.
  1942.  
  1943.    * SAS D1 This format only allows a Source-Code connection.  It
  1944.      doesn't support local variables, Structures and Macros.
  1945.  
  1946.    * GCC STABS This format is very powerful and offers all a
  1947.      source-level Debugger needs.  Unfortunately the Debugger only
  1948.      supports a simple Source-Code connection at the moment.  It's
  1949.      planned to support more in the future.
  1950.  
  1951. GCC Compiler and BDebug
  1952. -----------------------
  1953.  
  1954.    Unfortunately you can't debug programs that are using the current
  1955. `ixemul.library' because in Openlibrary() initroutine the Task field
  1956. TC_TRAPCODE is changed.  Hopefully there'll be soon an `ixemul.library'
  1957. available that doesn't change the traphandler.  If you're using GCC
  1958. with the link lib `gerlib' that is available on Aminet FTP Servers you
  1959. shouldn't experience any problems with BDebug.
  1960.  
  1961. Usage of BDebug
  1962. ***************
  1963.  
  1964. Configuration
  1965. =============
  1966.  
  1967.    The default configuration file is named `BDEBUG.Config' and is
  1968. located in the directory `<BarflyPath>/' or `s:Barfly/'.  Obviously
  1969. it's not optimal to be forced to use the same config file for different
  1970. programs. Therefore you can also specify a local config file with
  1971. program name and the suffix `.BDebug'.
  1972.  
  1973. ToolTypes
  1974. ---------
  1975.  
  1976.    The following tooltypes are supported to activate the basic
  1977. functions of the commandwindow.
  1978.  
  1979.    * CatchNextTask
  1980.  
  1981.    * CatchCrashedTask
  1982.  
  1983.    * CatchEnforcerHit
  1984.  
  1985. Barfly.FD
  1986. ---------
  1987.  
  1988.    Following steps are necessary to create a new `Barfly.FD' file with
  1989. new library functions.  First the assign `FD:' must point to the
  1990. directory containing the FD files that should be included in the new
  1991. `Barfly.FD'.  Make sure that every FD file contains the Library,
  1992. Resource and Device name in the first line in following format: `*
  1993. "foobar.libary"'.  If necessary, add the name yourself, so that a
  1994. correct FD database can be build up.  If you're more experienced with
  1995. FD files, you can yourself add new entries to the `Barfly.FD' file. The
  1996. layout of the `Barfly.FD' file pretty obvious.
  1997.  
  1998. Configuration Commands
  1999. ----------------------
  2000.  
  2001. Register window
  2002. ---------------
  2003.  
  2004. RegWindow=x/y/width/height/register
  2005. ...................................
  2006.  
  2007.    This command defines the position of a `REGWindow'.
  2008.  
  2009. RegFlags=flag[|flags...]
  2010. ........................
  2011.  
  2012.    This command defines certain flags in the `REGWindows'.
  2013.  
  2014.    * AUTOVIEWREFRESH
  2015.  
  2016.    * SYMBOLS
  2017.  
  2018.    * STACKCHECK
  2019.  
  2020.    * NOBIGVIEW
  2021.  
  2022. FPU Window
  2023. ----------
  2024.  
  2025. FpuWindow=x/y/width/height/register
  2026. ...................................
  2027.  
  2028.    This command defines the position of a `FPUWindow'.
  2029.  
  2030. OpenFPUWindows=Count
  2031. ....................
  2032.  
  2033.    This command tells the Debugger to open a `FPUWindow'.
  2034.  
  2035. Disassembler window
  2036. -------------------
  2037.  
  2038. DissWindow=x/y/width/height/register
  2039. ....................................
  2040.  
  2041.    This command defines the position,the dimension and linked register
  2042. of the `DissWindow'.
  2043.  
  2044.    Example: DISSWINDOW=0/0/300/100/PC
  2045.  
  2046. DissFlags=flag[|flags...]
  2047. .........................
  2048.  
  2049.    This command defines certain flags in the `DISSWindow'.
  2050.  
  2051.    * AUTOREFRESH
  2052.  
  2053.    * SHOWLIB
  2054.  
  2055.    * GUESSLIB
  2056.  
  2057.    * SHOWEA
  2058.  
  2059.    * WORDBRANCHES
  2060.  
  2061.    * NEGOFFSETS
  2062.  
  2063.    * NEGDI
  2064.  
  2065.    * OPCODEDATA
  2066.  
  2067.    * BLANKAFTERJMPBRA
  2068.  
  2069. OpenDissWindows=Count
  2070. .....................
  2071.  
  2072.    This command tells the Debugger to open a number of `DissWindows'.
  2073.  
  2074. Memory window
  2075. -------------
  2076.  
  2077. MemWindow=x/y/width/height/register
  2078. ...................................
  2079.  
  2080.    This command defines the position, the dimension and linked register
  2081. of the `MemWindow'.
  2082.  
  2083.    Example: MEMWINDOW=0/0/300/100/A0
  2084.  
  2085. OpenMemWindows=Count
  2086. ....................
  2087.  
  2088.    This command tells the Debugger to open a number of `MemWindows'.
  2089.  
  2090. MemoryOffsetStep=Count
  2091. ......................
  2092.  
  2093.    This command defines the Offset-Step of the `MemWindows'.
  2094.  
  2095.    * 0 no Space
  2096.  
  2097.    * 1 Space after each Byte.
  2098.  
  2099.    * 2 Space after each Word.
  2100.  
  2101.    * 4 Space after each Longword.
  2102.  
  2103. Copper window
  2104. -------------
  2105.  
  2106. CoppWindow=x/y/width/height/register
  2107. ....................................
  2108.  
  2109.    This command defines the position, the dimension and linked register
  2110. of the `CoppWindow'.
  2111.  
  2112.    Example: COPPWINDOW=0/0/300/100/A0
  2113.  
  2114. OpenCoppWindows=Count
  2115. .....................
  2116.  
  2117.    This command tells the Debugger to open a number of `CoppWindows'.
  2118.  
  2119. StructWindow
  2120. ------------
  2121.  
  2122. StructWindow=x/y/width/height/register
  2123. ......................................
  2124.  
  2125.    This command defines the position, the dimension and linked register
  2126. of the `StructWindow'.
  2127.  
  2128.    Example: StructWINDOW=0/0/300/100/A0
  2129.  
  2130. StructFlags=flag[|flags...]
  2131. ...........................
  2132.  
  2133.    This command defines certain flags for the `StructWindow'
  2134.  
  2135.    * AUTOREFRESH
  2136.  
  2137.    * ADDRESSFORMAT
  2138.  
  2139.    * OFFSETFORMAT
  2140.  
  2141.    * NEWWINDOW
  2142.  
  2143. OpenStructWindows=Count
  2144. .......................
  2145.  
  2146.    This command tells the Debugger to open a number of `StructWindows'.
  2147.  
  2148. Source window
  2149. -------------
  2150.  
  2151. SourceWindow=x/y/width/height/register
  2152. ......................................
  2153.  
  2154.    This command defines the position, the dimension and linked register
  2155. of the `SourceWindow'.
  2156.  
  2157.    Example: SOURCEWINDOW=0/0/300/100/A0
  2158.  
  2159. OpenSourceWindows=Count
  2160. .......................
  2161.  
  2162.    This command tells the Debugger to open a number of `SourceWindows'.
  2163.  
  2164. Breakpoint window
  2165. -----------------
  2166.  
  2167. BreakWindow=x/y/width/height
  2168. ............................
  2169.  
  2170.    This command defines the position of a `BreakPointWindow'.
  2171.  
  2172. OpenBreakWindows=Count
  2173. ......................
  2174.  
  2175.    This command tells the Debugger to open a `BreakPointWindow'.
  2176.  
  2177. Watchpoint window
  2178. -----------------
  2179.  
  2180. WatchWindow=x/y/width/height
  2181. ............................
  2182.  
  2183.    This command defines the position of a `WatchpoinzWindow'.
  2184.  
  2185. OpenWatchWindows=Count
  2186. ......................
  2187.  
  2188.    This command tells the Debugger to open a `WatchPointWindow'.
  2189.  
  2190. Checksum window
  2191. ---------------
  2192.  
  2193. ChecksumWindow=x/y/width/height
  2194. ...............................
  2195.  
  2196.    This command defines the position of a `ChecksumWindow'.
  2197.  
  2198. ChecksumWindows=Count
  2199. .....................
  2200.  
  2201.    This command tells the Debugger to open a `ChecksumWindow'.
  2202.  
  2203. SnoopMemory window
  2204. ------------------
  2205.  
  2206. SnoopMemWindow=x/y/width/height/register
  2207. ........................................
  2208.  
  2209.    This command defines the position of a `SnoopMemWindow'.
  2210.  
  2211. OpenSnoopMemWindow=Count
  2212. ........................
  2213.  
  2214.    This command tells the Debugger to open a `SnoopMemWindow'.
  2215.  
  2216. SnoopMask=Mask
  2217. ..............
  2218.  
  2219.    This command defines the snoop mask. The mask defines the length of
  2220. memory blocks that should be recorded.  Default is -1 so everything is
  2221. recorded.
  2222.  
  2223. SnoopMax=Count
  2224. ..............
  2225.  
  2226.    This command defines the count of snoop entries.  Default is 100.
  2227.  
  2228. HistoryEntrys=Count
  2229. ...................
  2230.  
  2231.    This command defines the count of history entries.  Default is 5.
  2232.  
  2233. Information Windows
  2234. -------------------
  2235.  
  2236. GlobalViewWindow=x/y/width/height
  2237. .................................
  2238.  
  2239.    This command defines the position and dimensions of a standard
  2240. information window. For example the Library Window belongs to this
  2241. group.
  2242.  
  2243.    Example: GLOBALVIEWWINDOW=0/0/300/100
  2244. GLOBALVIEWWINDOW=0/200/300/100
  2245.  
  2246. Other Windows
  2247. -------------
  2248.  
  2249. CommandWindow=x/y/width/height
  2250. ..............................
  2251.  
  2252.    This command defines the position of the small `CommandWindow'.
  2253. This command has no function in local configuration files.
  2254.  
  2255. FileShell=<Window Specifikation>
  2256. ................................
  2257.  
  2258.    This command defines the shell that is opened with the loaded
  2259. program. You should always open the shell on the Debugger's Public
  2260. Screen. The shell parameters are the same you know from the CLI.
  2261.  
  2262. Misc
  2263. ----
  2264.  
  2265. TaskStack=Count
  2266. ...............
  2267.  
  2268.    This command defines the stack of the loaded program.  Defaullt are
  2269. 4096 Bytes.
  2270.  
  2271. Priority=Count
  2272. ..............
  2273.  
  2274.    This command defines the Debugger's priority.
  2275.  
  2276. SetBreak=Argument
  2277. .................
  2278.  
  2279.    This command can be used to define a list of breakpoints that are
  2280. set before the program is started.  This is useful to pass the module
  2281. `Main.c' for example.  If no breakpoints are defined or if a parsing
  2282. problem occurs the standard breakpoint ( the first program instruction
  2283. ) is set.
  2284.  
  2285.    * SETBREAK=_main    ; SAS C Main Program Start
  2286.  
  2287.    * SETBREAK=_main    ; GCC C Main Program Start
  2288.  
  2289.    * SETBREAK=@main   ; DICE C Main Program Start
  2290.  
  2291.    * SETBREAK=!    ; Programstart(Default)
  2292.  
  2293. ClickBreak=State
  2294. ................
  2295.  
  2296.    This command can be used to define the action of the DissWindow on a
  2297. doubleclick.
  2298.  
  2299. `State=0'
  2300.      No Action(Default).
  2301.  
  2302. `State=1'
  2303.      Set/Clear Breakpoint and pop up a Requester for a Set.
  2304.  
  2305. `State=2'
  2306.      Set/Clear Breakpoint.
  2307.  
  2308. ShowMem=Start:End
  2309. .................
  2310.  
  2311.    defines the address areas that are legal to the Debugger so you can
  2312. look at address areas that are not in the memorylist or in the rom.
  2313. Illegal address areas are shown with `*' in the windows.  You should
  2314. `never' define the custom chip areas as legal because a read access on
  2315. a writeonly register can cause a deadly crash.
  2316.  
  2317.    Example: SHOWMEM=$e80000:$f00000          defines the Zorro 2 area
  2318. as free.
  2319.  
  2320.      By this command you can overrule the internal Enforcer or
  2321.      CyberGuard legal memory areas so you should be free of hits.
  2322.  
  2323.  
  2324. DefCommand=Key,Qualifier[|Qualifier...],Function
  2325. ................................................
  2326.  
  2327.    This commands allows to connect menu functions with key sequences.
  2328. Because of the object-oriented concept of the Debugger that allows
  2329. multiple instances of objects it's not easy to decide what object is
  2330. meant.  Therefore if the object is active it's used and if no object of
  2331. this type is active the first entry the object-type list is used.  As
  2332. the key parameter every Rawkey can be used with the exception of `TAB'
  2333. and the functionkeys that are used internally.  The key is searched
  2334. first in the local and then in the global configuration.
  2335.  
  2336.    As qualifiers you can use the following keys.
  2337.  
  2338.    * LSHIFT
  2339.  
  2340.    * RSHIFT
  2341.  
  2342.    * CAPSLOCK
  2343.  
  2344.    * CTRL
  2345.  
  2346.    * LALT
  2347.  
  2348.    * RALT
  2349.  
  2350.    * LCOMMAND
  2351.  
  2352.    * RCOMMAND
  2353.  
  2354.           Bespiel:      DEFCOMMAND=$15,CTRL,"Step 1 Position"
  2355.  
  2356.      Defines CTRL-Z as Step 1 Position
  2357.  
  2358. AutoDocDir=<Path>
  2359. .................
  2360.  
  2361.    This command sets the path for the autodocs directory.
  2362.  
  2363. AutoDocAlias=Library,File
  2364. .........................
  2365.  
  2366.    This command sets an alias for Libraries, Devices or Resources to
  2367. define the connected Autodocs file.  There's no other way because it's
  2368. impossible to build the autodocs file by knowing the library name.
  2369.  
  2370. ArexxPath=<rx-path>
  2371. ...................
  2372.  
  2373.    This command sets the Arexx-Script Start-Command.  In a normal
  2374. system the path should be <sys:Rexxc/rx>.
  2375.  
  2376. ArexxInput=<File>
  2377. .................
  2378.  
  2379.    This command sets the Arexx-Command Input-File.  If you don't
  2380. specify the file, NIL: is used.
  2381.  
  2382. ArexxOutput=<File>
  2383. ..................
  2384.  
  2385.    This command sets the Arexx-Command Output-File.  If you don't
  2386. specify the file, NIL: is used.
  2387.  
  2388. ArexxCommand=[1...10],<Pfad>
  2389. ............................
  2390.  
  2391.    This command sets the 10 entries in the Arexx-Menu.  You specify the
  2392. number and the path of the Arexx-Script.
  2393.  
  2394.    ArexxCommand=1,"Rexx:Example.rexx"
  2395.  
  2396. ExecuteCommand=<File>
  2397. .....................
  2398.  
  2399.    this command can set up a list of programs that should be run before
  2400. the debugged program's task is started.  This parameter only works with
  2401. programs which are loaded by the Debugger. You also have to make sure
  2402. that the loaded programs have to `end' otherwise the task can't be
  2403. started.  For example you could use this command to set breakpoints
  2404. with Arexx-Scripts.
  2405.  
  2406. LoadInclude
  2407. ...........
  2408.  
  2409.    tells the Debugger to load the structure information file
  2410. `Barfly.Include'.
  2411.  
  2412. AddStructFile=Filename
  2413. ......................
  2414.  
  2415.    tells the Debugger to load a custom structure information file and
  2416. adds it into the CUSTOM/ subtree.
  2417.  
  2418. ClicktoFront
  2419. ............
  2420.  
  2421.    activates the Debugger's own `ClicktoFront' handler.  This function
  2422. should only be used if you don't use an own `Commodity' for this task.
  2423.  
  2424. CenterWindow
  2425. ............
  2426.  
  2427.    activates centering mode for all stringrequester windows.
  2428.  
  2429. ScreenInFront
  2430. .............
  2431.  
  2432.    activates `ScreenToFront' mode that pops the screen to front after
  2433. every trace operation.
  2434.  
  2435. OpenScreen[=width,height,depth,mode]
  2436. ....................................
  2437.  
  2438.    tells the Debugger to open its own screen.  If you don't enter
  2439. dimension parameters the wb screen is cloned. For the mode string you
  2440. string you can see in `Prefs/ScreenMode' requester.  This command has
  2441. no function in local configuration files.
  2442.  
  2443.    OPENSCREEN=1448,560,2,PAL:HighRes Interlace
  2444.  
  2445. OpenPubScreen=Name
  2446. ..................
  2447.  
  2448.    tells the Debugger to open on the Pubscreen with the specified name.
  2449. This command has no function in local configuration files.
  2450.  
  2451. ScreenFont=fontname/Height
  2452. ..........................
  2453.  
  2454.    defines a font for a Debugger screen.  This command has no function
  2455. in local configuration files.
  2456.  
  2457. QuietException=Exception Nummer
  2458. ...............................
  2459.  
  2460.    masks off certain exceptions for the exception requester so that
  2461. only a `DisplayBeep' is caused instead of a textrequest.  With the
  2462. value -1 you can mask off every exception and for example with the
  2463. value 4 you mask off the `Illegal' exception.
  2464.  
  2465. DisableXPointer
  2466. ...............
  2467.  
  2468.    deactivate the Wait-Pointer.
  2469.  
  2470. TraceBreak
  2471. ..........
  2472.  
  2473.    tells the Debugger to use breakpoints in the `Subroutine' Traces
  2474. instead of single steps.  The advantage is a speed up and the
  2475. disadvantage is that you can cause crashes while you step through
  2476. resident/reentry code.
  2477.  
  2478. CrashedTask
  2479. ...........
  2480.  
  2481.    activates `CatchCrashedTask' mode.
  2482.  
  2483. CatchEnforcerHit
  2484. ................
  2485.  
  2486.    activates `CatchEnforcerHit' mode.
  2487.  
  2488. DoNotCacheFullFile
  2489. ..................
  2490.  
  2491.    tells the Debugger not to cache program files while reading the
  2492. Symbol/Debug informations to save memory.  Obviously the parsing speed
  2493. will decrease.
  2494.  
  2495. DoNotPopPathRequest
  2496. ...................
  2497.  
  2498.    tells the Debugger to ignore errors from opening source files and
  2499. not to open a path requester.
  2500.  
  2501. NoAutoStructAction
  2502. ..................
  2503.  
  2504.    tells the Debugger to open a type-requester by an action in the
  2505. Structure Window.
  2506.  
  2507. NoBreakpointErrors
  2508. ..................
  2509.  
  2510.    tells the Debugger to ignore SETBREAK= errors that cause the
  2511. Debugger to always set an error on the program start.
  2512.  
  2513. Usage of BDebug
  2514. ***************
  2515.  
  2516. Arexx
  2517. =====
  2518.  
  2519. Commands
  2520. --------
  2521.  
  2522. SIMPLEREQUEST "
  2523. ...............
  2524.  
  2525.    * RC: -
  2526.  
  2527.    * result: 'OK'
  2528.  
  2529. TWOGADREQUEST "
  2530. ...............
  2531.  
  2532.    * RC: -
  2533.  
  2534.    * result: 'OK','FALSE'
  2535.  
  2536. TRIGADREQUEST "
  2537. ...............
  2538.  
  2539.    * RC: -
  2540.  
  2541.    * result: 'OK','FALSE','RESUME'
  2542.  
  2543. NEXT_ROOTWINDOW
  2544. ...............
  2545.  
  2546.    * RC: -
  2547.  
  2548.    * result: 'OK','FALSE'
  2549.  
  2550. NEXT_SUBWINDOW
  2551. ..............
  2552.  
  2553.    * RC: -
  2554.  
  2555.    * result: 'OK','FALSE'
  2556.  
  2557. FIRST_DISSWINDOW
  2558. ................
  2559.  
  2560.    * RC: -
  2561.  
  2562.    * result: 'OK','FALSE'
  2563.  
  2564. FIRST_MEMWINDOW
  2565. ...............
  2566.  
  2567.    * RC: -
  2568.  
  2569.    * result: 'OK','FALSE'
  2570.  
  2571. FIRST_COPPWINDOW
  2572. ................
  2573.  
  2574.    * RC: -
  2575.  
  2576.    * result: 'OK','FALSE'
  2577.  
  2578. FIRST_FPUWINDOW
  2579. ...............
  2580.  
  2581.    * RC: -
  2582.  
  2583.    * result: 'OK','FALSE'
  2584.  
  2585. FIRST_BREAKPOINTWINDOW
  2586. ......................
  2587.  
  2588.    * RC: -
  2589.  
  2590.    * result: 'OK','FALSE'
  2591.  
  2592. FIRST_STRUCTWINDOW
  2593. ..................
  2594.  
  2595.    * RC: -
  2596.  
  2597.    * result: 'OK','FALSE'
  2598.  
  2599. FIRST_SOURCEWINDOW
  2600. ..................
  2601.  
  2602.    * RC: -
  2603.  
  2604.    * result: 'OK','FALSE'
  2605.  
  2606. FIRST_SNOOPWINDOW
  2607. .................
  2608.  
  2609.    * RC: -
  2610.  
  2611.    * result: 'OK','FALSE'
  2612.  
  2613. FIRST_WATCHWINDOW
  2614. .................
  2615.  
  2616.    * RC: -
  2617.  
  2618.    * result: 'OK','FALSE'
  2619.  
  2620. ACTIVATE_ROOTWINDOW
  2621. ...................
  2622.  
  2623.    * RC: -
  2624.  
  2625.    * result: 'OK','FALSE'
  2626.  
  2627. ACTIVATE_SUBWINDOW
  2628. ..................
  2629.  
  2630.    * RC: -
  2631.  
  2632.    * result: 'OK','FALSE'
  2633.  
  2634. OPEN_DISSWINDOW '@REG' | 'Argument'
  2635. ...................................
  2636.  
  2637.    * RC: -
  2638.  
  2639.    * result: -
  2640.  
  2641. OPEN_MEMWINDOW '@REG' | 'Argument'
  2642. ..................................
  2643.  
  2644.    * RC: -
  2645.  
  2646.    * result: -
  2647.  
  2648. OPEN_COPPWINDOW '@REG' | 'Argument'
  2649. ...................................
  2650.  
  2651.    * RC: -
  2652.  
  2653.    * result: -
  2654.  
  2655. OPEN_SOURCEWINDOW '@REG' | 'Argument'
  2656. .....................................
  2657.  
  2658.    * RC: -
  2659.  
  2660.    * result: -
  2661.  
  2662. OPEN_STRUCTWINDOW '@REG' | 'Argument'
  2663. .....................................
  2664.  
  2665.    * RC: -
  2666.  
  2667.    * result: -
  2668.  
  2669. OPEN_BREAKPOINTWINDOW
  2670. .....................
  2671.  
  2672.    * RC: -
  2673.  
  2674.    * result: -
  2675.  
  2676. OPEN_FPUWINDOW
  2677. ..............
  2678.  
  2679.    * RC: -
  2680.  
  2681.    * result: -
  2682.  
  2683. OPEN_SNOOPMEMORYWINDOW
  2684. ......................
  2685.  
  2686.    * RC: -
  2687.  
  2688.    * result: -
  2689.  
  2690. DOMENU 'Menu-String'
  2691. ....................
  2692.  
  2693.    * RC: -
  2694.  
  2695.    * result: -
  2696.  
  2697. SET_BREAKPOINT 'Argument'
  2698. .........................
  2699.  
  2700.    * RC: -
  2701.  
  2702.    * result: 'OK','FALSE'
  2703.  
  2704. CLEAR_ICACHE 'Address,Length'
  2705. .............................
  2706.  
  2707.    * RC: -
  2708.  
  2709.    * result: 'OK'
  2710.  
  2711. CLEAR_ICACHE 'Address,Length'
  2712. .............................
  2713.  
  2714.    * RC: -
  2715.  
  2716.    * result: 'OK'
  2717.  
  2718. GOTO_ADDRESS 'Address'
  2719. ......................
  2720.  
  2721.    * RC: -
  2722.  
  2723.    * result: 'OK','FALSE'
  2724.  
  2725. CLEAR_ADDRESS
  2726. .............
  2727.  
  2728.    * RC: -
  2729.  
  2730.    * result: 'OK','FALSE'
  2731.  
  2732. LINK_REGISTER 'Register'
  2733. ........................
  2734.  
  2735.    * RC: -
  2736.  
  2737.    * result: 'OK','FALSE'
  2738.  
  2739. SET_REGISTER 'Register,Value'
  2740. .............................
  2741.  
  2742.    * RC: -
  2743.  
  2744.    * result: 'OK','FALSE'
  2745.  
  2746. Read_Byte 'Address'
  2747. ...................
  2748.  
  2749.    RC    : 0=Ok    Result: Result-String
  2750.  
  2751. Read_Word 'Address'
  2752. ...................
  2753.  
  2754.    RC    : 0=Ok    Result: Result-String
  2755.  
  2756. Read_Long 'Address'
  2757. ...................
  2758.  
  2759.    RC    : 0=Ok    Result: Result-String
  2760.  
  2761. Write_Byte 'Address,Value'
  2762. ..........................
  2763.  
  2764.    RC    : 0=Ok
  2765.  
  2766. Write_Word 'Address,Value'
  2767. ..........................
  2768.  
  2769.    RC    : 0=Ok
  2770.  
  2771. Write_Long 'Address,Value'
  2772. ..........................
  2773.  
  2774.    RC    : 0=Ok
  2775.  
  2776. ASL_FileRequester_Save
  2777. ......................
  2778.  
  2779.    RC    : 0=Ok    Result: Filepath-String
  2780.  
  2781. ASL_FileRequester_Load
  2782. ......................
  2783.  
  2784.    RC    : 0=Ok    Result: Filepath-String
  2785.  
  2786. IS_ADDRESS_LEGAL 'Address'
  2787. ..........................
  2788.  
  2789.    * RC: -
  2790.  
  2791.    * result: 'OK','FALSE'
  2792.  
  2793. LOAD_BINARY 'Name,Destination,Length'
  2794. .....................................
  2795.  
  2796. SAVE_BINARY 'Name,Source,Length'
  2797. ................................
  2798.  
  2799. Usage of BDebug
  2800. ***************
  2801.  
  2802. How to use BDebug ?
  2803. ===================
  2804.  
  2805. Trouble Shooting
  2806. ----------------
  2807.  
  2808.    First you should be sure that all necessary configurations file have
  2809. been installed because without `Barfly.FD' file you don't see any
  2810. function names in the disassembler window; and without `Barfly.Include'
  2811. the `StructWindow' is unusable.  Are these preconditions fullfilled you
  2812. should analyse the problem and anticipate how the Debugger can be used.
  2813. Because the debugging of programs depends heavily on the situation i
  2814. can only list some general points.  The reality probably looks
  2815. different... as always:-)
  2816.  
  2817.    Point of departure:
  2818.  
  2819.    * Program from the CLI
  2820.  
  2821.         * 1 Task
  2822.  
  2823.           The program can be started by `bdebug Program [Argument]' or
  2824.           can be loaded the command window `Debug File'.  By this
  2825.           method all symbol and debug files are loaded.  If the
  2826.           Debugger can't find a source file you can add additional
  2827.           paths if you haven't disabled this function.  The standard
  2828.           breakpoint is the first command in the program.  Sometimes
  2829.           this is inconvenient, and you may want to set a different
  2830.           start breakpoint for example to jump over the CStartup code
  2831.           or to set it tn an important program position.
  2832.  
  2833.         * Creates further Tasks
  2834.  
  2835.           In this case you should be sure how you want to catch the next
  2836.           Task. You could catch the Task by `Next Task' or compile the
  2837.           program with an `illegal' in the task and catch it with
  2838.           `Crashed Task'.  After you caught the task you probably would
  2839.           like to use see symbols and debug source.  These informations
  2840.           can be loaded afterwards by using `Load Symbols'.
  2841.  
  2842.    * Program from the WB
  2843.  
  2844.      In this case you should use `Next Task' and then catch the task
  2845.      `WBL'. Afterwards you have to activate `Next Task' again and run
  2846.      `WBL'. You could also use the `illegal' strategy.  After the right
  2847.      task was caught you can load the symbols again.
  2848.  
  2849.    * Is it a Handler, Filesystem or something similar.
  2850.  
  2851.      In this case you should use the `illegal' strategy and catch the
  2852.      task by `Crashed Task'.  An alternative method would be to catch
  2853.      the waiting task with `Debug Task' and wait as long as the task
  2854.      gets woken up by a signal.
  2855.  
  2856.    After you've taken the first hurdles in taking control over the task,
  2857. you should think about how the problem looks like and where it could be
  2858. located.
  2859.  
  2860.    Problem Type:
  2861.  
  2862.    * Enforcer/CyberGuard
  2863.  
  2864.      If an Enforcer or CyberGuard hit is caused, these programs output
  2865.      the hit's program address and most of the time the hunk offset as
  2866.      well.  You can now directly jump to the address by entering the
  2867.      address in the DissWindow by `Change Address' or you open a
  2868.      HunkWindow, doubleclick on the hunk where the hit is located and
  2869.      then enter the offset returned by Enforcer or CyberGuard.  The
  2870.      Debugger itself can also automaticlly stop a debugged program if a
  2871.      hit happens.
  2872.  
  2873.    * Mungwall
  2874.  
  2875.      These hits aren't as easy to find as Enforcer or CyberGuard hits
  2876.      because Mungwall hits aren't shown when the problem happened but
  2877.      only after a `FreeMem'.  In this case you should remember the
  2878.      memoryblock where it happened and determine where the responsible
  2879.      AllocMem is located in the program, so you get an overview in what
  2880.      area the problem is caused.  Now you should open a MemWindow that
  2881.      points to this certain memory area and step through the program
  2882.      and look if something changes the mungwall borders in the
  2883.      MemWindow.  Mungwall borders are before and after the allocated
  2884.      memory area.  If you're more experienced you could also use the
  2885.      WatchpointWindow and set a watchpoint on the certain memory block.
  2886.  
  2887.    * Crash
  2888.  
  2889.      If it's just an ordinary crash the error should be pretty easy to
  2890.      find by single stepping through the responsible code area.  If
  2891.      it's a random crash you should try `Crashed Task' and hope that
  2892.      the task can be caught.  After the task got caught you should
  2893.      check the instructions that caused the crash. If the PC points to
  2894.      data fields that don't look like real code the PC is probably set
  2895.      wrong by a stack cleanup error.  In this case you should check if
  2896.      the next addresses on the stack point to legal program code.
  2897.  
  2898.    * Side effects and mysterious bugs
  2899.  
  2900.      These bugs are the worst to find and there's no general strategy
  2901.      how to find them. In such cases only intuition and patience can
  2902.      help.
  2903.  
  2904. Problems that can happen
  2905. ------------------------
  2906.  
  2907.    * Why does the Debugger react so slow on keyboard commands that
  2908.      control the tracing ?
  2909.  
  2910.      This happens if you debug a task with a higher priority than the
  2911.      Debugger's priority.  For example. DOS-Handler.  Workaround is to
  2912.      increase the priority of the Debugger.
  2913.  
  2914.    * Why do filerequesters block the Debugger.
  2915.  
  2916.      This happens when you debug a handler, because the filerequester
  2917.      normally tests every handler with a IsFilesystem(). When you debug
  2918.      a handler it can't reply the IsFilesystem packet and therefore the
  2919.      filerequester is busy.
  2920.  
  2921.    * If you debug the following program on a 68040 with 68040.library
  2922.      or 68060.library the instruction `rts' is run if you cause a
  2923.      Single-Step on the instruction `fetox'.  Because this command
  2924.      isn't implemented in the 68040 and 68060 it has to be emulated. It
  2925.      seems to forget the tracebit.
  2926.  
  2927.               mc68040
  2928.               fmove.x    #1.3,fp0
  2929.               fmove.x    #255,fp1
  2930.               fetox.x    fp0,fp1
  2931.               rts
  2932.  
  2933.    * If a program doesn't return from a DOS function, check whether you
  2934.      accidently entered a char in shell window.
  2935.  
  2936.                                BAsm 1.0
  2937.  
  2938.                     A cli/arexx controled Assembler
  2939.  
  2940.                   Copyright (c) 1989-94 Ralph Schmidt
  2941.  
  2942.                              - Shareware -
  2943.  
  2944. The Assembler
  2945. *************
  2946.  
  2947.    The assembler understands the commands and addressmodes from the
  2948. 68000 through the 68060 and both the Floating-Point Units, 68881 and
  2949. 68882.  It supports only the 68851 MMU commands, which are also
  2950. supported by the 68030.  The assembler achieves it's speed by
  2951. translating the source in a single pass, followed by a backpatch phase
  2952. which corrects all unresolved references.
  2953.  
  2954. Syntax
  2955. ======
  2956.  
  2957. Comments
  2958. --------
  2959.  
  2960.    A comment can start in several different ways.  In a pure comment it
  2961. starts either with a ; or *.  A comment can only be started after an
  2962. assembler command or symbol with a ; if an assembler command or symbol
  2963. exists within that line.
  2964.  
  2965.          ;A comment
  2966.      *A comment
  2967.          move.l a0,a0    ;A comment
  2968.  
  2969. Opcode/Instructions arrangement
  2970. -------------------------------
  2971.  
  2972.    `[label[:]] [opcode] [operand[, operand[, operand...]]]]]'
  2973.  
  2974.    * Opcodes
  2975.  
  2976.      An Opcode can be a Motorola Mnemonic, an assembler command, or a
  2977.      Macro call.
  2978.  
  2979.    * Operations
  2980.  
  2981.      In a Motorola mnemonic operands are based on legal addressmoes; in
  2982.      assembler privat instructions the parameters depend on the
  2983.      instruction.
  2984.  
  2985. Symbol structure
  2986. ----------------
  2987.  
  2988.    A symbol can represent the following types:
  2989.  
  2990.    * Value
  2991.  
  2992.    * Program Counter
  2993.  
  2994.    * Register
  2995.  
  2996.    * Register List
  2997.  
  2998.    * Macro
  2999.  
  3000.    Symbols can only be defined once. The exceptions are local labels
  3001. and symbols defined by Set.
  3002.  
  3003.                      Structure rules for Symbols.
  3004.  
  3005.    * The first letter of a symbol can be one of the following: a...z,
  3006.      A...Z,_, @,. and \.
  3007.  
  3008.    * From the second letter on, the symbol can contain the following
  3009.      letters: a...z, A...Z, 0...9, _,@ and ..
  3010.  
  3011.    * If a symbol consists of only numbers and ends with $, then it is a
  3012.      numerical local label.
  3013.  
  3014.    * A symbol is ended by an illegal letter.
  3015.  
  3016.    * If a symbol begins with a . or \, then it is a local label.
  3017.  
  3018.    * A macro symbol should not contain a ..
  3019.  
  3020.    * To avoid a conflict, a symbol should not end with .b, .w or .l.
  3021.  
  3022.  
  3023.      ThisIsALabel              ;That is a normal label
  3024.      ThisIsALabel1.loop:       ;That is a normal label
  3025.      This@_Is_@A_@Label
  3026.      1$:                       ;That is a numerical local label
  3027.      .ThisIsALabel             ;That is a local label
  3028.      .ThisIsALael1:            ;That is a local label
  3029.      \ThisIsALabel.loop:       ;That is a local label
  3030.      ThisIsASymbol=10
  3031.      ThisIsASymbol = 10
  3032.      ThisIsASymbol equ 10
  3033.  
  3034. The relative label
  3035. ------------------
  3036.  
  3037.    This symbol represents an offset to the start of a program.
  3038.  
  3039.  
  3040.      label
  3041.      label:
  3042.      label    nop
  3043.      label: nop
  3044.  
  3045. The local Label
  3046. ---------------
  3047.  
  3048.    A local label is only valid between two normal relative labels, thus
  3049. you cannot reference local labels outside of that scope.  Otherwise it
  3050. works similar as a normal label.  There are 2 different prefixes that
  3051. introduce a local label: . and \ that define 2 different local labels.
  3052. A special case is the Backward Reference Label that is introduced with
  3053. ... It doesn't depend on a certain define area between normal labels
  3054. thus you can only access the symbol if it were defined earlier.
  3055.  
  3056.  
  3057.      ..:
  3058.      label_0:
  3059.      .local:
  3060.       bra.s .local
  3061.      label_1:
  3062.      .local:
  3063.       bra.s \local
  3064.      \local:
  3065.       nop
  3066.      label_end:
  3067.      ..:
  3068.       dbra d0,..
  3069.      ..:
  3070.       dbra d1,..
  3071.      ..Hello:
  3072.       dbra d1,..Hello
  3073.  
  3074. The local numerical label
  3075. -------------------------
  3076.  
  3077.    Addionally to the non-numerical local label there are also the
  3078. numerical labels which are based of 4 digits with the postfix $.  BASM
  3079. handles the number as a hash key with the consequence that there's no
  3080. difference between 001$ and 1$.
  3081.  
  3082.  
  3083.  
  3084.      label_0:
  3085.      123$:    nop
  3086.      label_1:
  3087.      123$:    nop
  3088.  
  3089. The absolute Symbol
  3090. -------------------
  3091.  
  3092.    The absolute symbol is defined by a direct value initializing that
  3093. is initiated by =, equ or set.  If you define a symbol by set you can
  3094. change it as often as needed.
  3095.  
  3096.  
  3097.  
  3098.      value1=2
  3099.      value2 equ value1*2
  3100.      value3 set value2
  3101.  
  3102. The Register Symbol
  3103. -------------------
  3104.  
  3105.    The register symbol is defined by `equr' or `fequr' that is used for
  3106. FPU registers.
  3107.  
  3108.  
  3109.  
  3110.      Ptr    equr    a1
  3111.      PI    fequr    fp2
  3112.       move.l   (Ptr),d0   ;move.l  (a1),d0
  3113.       fmove.x  PI,fp0     ;fmove.x fp2,fp0
  3114.  
  3115. The Register List Symbol
  3116. ------------------------
  3117.  
  3118.    The register list symbol is defined by `reg' and represents the
  3119. register mask for `Movem' and `fmovem'.  You must not mix FPU and
  3120. Integer registers with each other in a register list.
  3121.  
  3122.  
  3123.      mask    reg    d0/d2/d4-d7/a0-a4/a6-a7
  3124.      mask1    reg    d0-a6
  3125.      mask2    reg    d0-6
  3126.      fmask    reg    fp0-fp2/fp4-fp5
  3127.  
  3128. The Macro Symbol
  3129. ----------------
  3130.  
  3131.    By using the command `macro' or `cmacro' after the symbol, the
  3132. symbol is defined as a macro.  The macro block is terminated by the
  3133. command endm.  The Macro cmacro is case-insensitive and therefore
  3134. useful to emulate commands that are missing from the core.
  3135.  
  3136.  
  3137.  
  3138.  
  3139.      Symbol[:] macro
  3140.      .
  3141.      .
  3142.      Symbol[:] endm
  3143.  
  3144. Datatypes
  3145. ---------
  3146.  
  3147.    The assembler understands 3 distinct datatypes.
  3148.  
  3149.    * 32Bit Integer
  3150.  
  3151.    * 96Bit Extended Floating Point
  3152.  
  3153.    * 96Bit Packed Binary Floating Point
  3154.  
  3155.    At the moment only integer datatypes are supported in arithmetic
  3156. arguments so you can only use the FPU datatypes as constants.
  3157.  
  3158.      +-------------+--------------------+
  3159.      | Format      | Representation     |
  3160.      +-------------+--------------------+
  3161.      +-------------+--------------------+
  3162.      | Decimal     | 1024               |
  3163.      +-------------+--------------------+
  3164.      | Hexadecimal | $400               |
  3165.      +-------------+--------------------+
  3166.      | Binary      | %10000000000       |
  3167.      +-------------+--------------------+
  3168.      | Ascii       | "OK", 'OK' or `OK` |
  3169.      +-------------+--------------------+
  3170.  
  3171.    Furthermore you can use symbols or the character `*' that represents
  3172. the program counter in arguments.  There are limitation in the use of
  3173. symbols in arguments.  For example you can only add or subtract
  3174. constants from an external label, Floatingpoint Values can only be used
  3175. as simple constants,...  By the postfix `k' after decimal value the
  3176. value is multply by $1000.
  3177.  
  3178.                         `Floating Point Format'
  3179.  
  3180.      +-------------+-------------------------------------+
  3181.      | Format      | Representation                      |
  3182.      +-------------+-------------------------------------+
  3183.      +-------------+-------------------------------------+
  3184.      | Extended    | '[+,-]3. 145637848298628[e[+,-]123] |
  3185.      +-------------+-------------------------------------+
  3186.      | Packed      | ''[+,-]3. 145637848298628[e[+,-]123]|
  3187.      +-------------+-------------------------------------+
  3188.  
  3189. Datatype Conversion
  3190. -------------------
  3191.  
  3192.    All commands are performed with these 3 datatypes and then converted
  3193. into the required datatype.  For example a 32Bit integer can be
  3194. converted into 16Bit and 8 Bit; an extended floating point into a
  3195. double or single floating point.  Floating point datatypes are rounded
  3196. by a convertation.  If a rouding error occurs the parser returns with
  3197. an error.
  3198.  
  3199. Datatype Format
  3200. ---------------
  3201.  
  3202.                       Internal Datatype Structure
  3203.  
  3204.    * Integer
  3205.  
  3206.      +--------+---------+
  3207.      | Bit 31 | 30..0   |
  3208.      +--------+---------+
  3209.      +--------+---------+
  3210.      |    S   | Integer |
  3211.      +--------+---------+
  3212.  
  3213.    * Single Floating Point
  3214.  
  3215.      +--------+-----------------+------------+
  3216.      | Bit 31 | Bits 30..23     | Bits 22..0 |
  3217.      +--------+-----------------+------------+
  3218.      +--------+-----------------+------------+
  3219.      |  Sign  | Biased Exponent |  Fraction  |
  3220.      +--------+-----------------+------------+
  3221.  
  3222.    * Double Floating Point
  3223.  
  3224.      +--------+-----------------+------------+
  3225.      | Bit 63 | Bits 62..52     | Bits 51..0 |
  3226.      +--------+-----------------+------------+
  3227.      +--------+-----------------+------------+
  3228.      |  Sign  | Biased Exponent |  Fraction  |
  3229.      +--------+-----------------+------------+
  3230.  
  3231.    * Extended Floating Point
  3232.  
  3233.      +--------+-----------------+------------+
  3234.      | Bit 95 | Bits 94..80     | Bits 62..0 |
  3235.      +--------+-----------------+------------+
  3236.      +--------+-----------------+------------+
  3237.      |  Sign  | Biased Exponent |  Mantisse  |
  3238.      +--------+-----------------+------------+
  3239.  
  3240.    * Packed Binary Floating Point
  3241.  
  3242.      +------+------+------+------+------+------+------+------+
  3243.      | MEYY | EXP2 | EXP1 | EXP0 | EXP3 | 0000 | 0000 | M016 |
  3244.      +------+------+------+------+------+------+------+------+
  3245.      | M015 | M014 | M013 | M012 | M011 | M010 | M009 | M008 |
  3246.      +------+------+------+------+------+------+------+------+
  3247.      | M007 | M006 | M005 | M004 | M003 | M002 | M001 | M000 |
  3248.      +------+------+------+------+------+------+------+------+
  3249.  
  3250.    * M is the sign (+ or -) of the fraction
  3251.  
  3252.    * E is the sign (+ or -) of the exponent
  3253.  
  3254.    * Y are the internal flags for infinity and NAN
  3255.  
  3256.    * E002-000 are the numbers of the exponent from 2 to 0, EXP3 is used
  3257.      internally.
  3258.  
  3259.    * M016-000 are the numbers of the fraction from 16 to 0. Each number
  3260.      lies in the range from 0 to 9..
  3261.  
  3262. Operations
  3263. ----------
  3264.  
  3265. Operators
  3266. ---------
  3267.  
  3268.      +----------+-------------------------------+
  3269.      | Operator | Function                      |
  3270.      +----------+-------------------------------+
  3271.      +----------+-------------------------------+
  3272.      |   `+'    | 32Bit signed Addition         |
  3273.      +----------+-------------------------------+
  3274.      |   `-'    | 32Bit signed Subtraction      |
  3275.      +----------+-------------------------------+
  3276.      |   `*'    | 32Bit signed Multiplication   |
  3277.      +----------+-------------------------------+
  3278.      |   `/'    | 32Bit signed Division         |
  3279.      +----------+-------------------------------+
  3280.      |   '|'    | 32Bit Or                      |
  3281.      +----------+-------------------------------+
  3282.      |   `!'    | 32Bit Or                      |
  3283.      +----------+-------------------------------+
  3284.      |   `&'    | 32Bit And                     |
  3285.      +----------+-------------------------------+
  3286.      |   `^'    | 32Bit Eor                     |
  3287.      +----------+-------------------------------+
  3288.      |   `<<'   | logic 32Bit Shift to the left |
  3289.      +----------+-------------------------------+
  3290.      |   `>>'   | logic 32Bit Shift to the right|
  3291.      +----------+-------------------------------+
  3292.      |   `~'    | 32Bit Not                     |
  3293.      +----------+-------------------------------+
  3294.  
  3295.      Basm cares for the operator priorities but be careful while
  3296.      porting Seka Sources because Seka doesn't care for the priorities.
  3297.  
  3298. Functions
  3299. ---------
  3300.  
  3301.    The following functions are supported.
  3302.  
  3303.    * _bitnum(Argument) calculates the bit number of the argument. If
  3304.      this is impossible an error occurs.
  3305.  
  3306.    * _bitfield(Argument) calculates the bit mask of the argument. If
  3307.      this is impossible an error occurs.
  3308.  
  3309.    * _extb(Argument) equal to the 680xx command extb
  3310.  
  3311.    * _extw(Argument) equal to the 680xx command extw
  3312.  
  3313.    * _min(Argument[,Argument,...]) calculate the minimum of the
  3314.      argument.
  3315.  
  3316.    * _max(Argument[,Argument,...]) calculate the maximum of the
  3317.      argument.
  3318.  
  3319. Assembler Commands
  3320. ==================
  3321.  
  3322. Hunk/Link Commands
  3323. ------------------
  3324.  
  3325. [Label] section Name[,Typ[,[RelocModus,Memtyp]
  3326. ..............................................
  3327.  
  3328.    defines a new logical unit so that the DOS-Loader has the
  3329. opportuntity to place smaller hunks into free memory blocks.  Another
  3330. use for this command is to set different memory types for the hunk to
  3331. load gfx data into the chipmem.  If you don't specify the section type
  3332. it assumes "",Code,Public.
  3333.  
  3334.    * Name = Hunkname
  3335.  
  3336.    * Hunk type
  3337.  
  3338.     `CODE'
  3339.           starts a code segment.
  3340.  
  3341.     `DATA'
  3342.           starts a data segment.
  3343.  
  3344.     `BSS'
  3345.           starts an undefined data segment.
  3346.  
  3347.     `DEBUG'
  3348.           starts a custom debug segment.
  3349.  
  3350.     `CUSTOM'
  3351.           starts a Custom-Hunk area.
  3352.  
  3353.    * Reloc-Mode defines the width of the hunk relocation. Default 32Bit
  3354.  
  3355.     `RELOC16'
  3356.           sets the reloc width to 16bit.(V37)
  3357.  
  3358.     `RELOC32'
  3359.           sets the reloc width to 32bit.(Default)
  3360.  
  3361.    * Memtype defines the memory attributes of the hunk.  If you add a
  3362.      `_p', `_c', or `_f' upon the type parameter, you cannot use more
  3363.      memtypes.The memtype `DEBUG' does not allow memory attribute
  3364.      suffixes.
  3365.  
  3366.     `PUBLIC'
  3367.           loads the hunk into the memory with the highest priority.
  3368.           Code Suffix _p.
  3369.  
  3370.     `CHIP'
  3371.           loads the hunk into chip memory. Code Suffix _c.
  3372.  
  3373.     `FAST'
  3374.           loads the hunk into fast memory. Code Suffix _f.
  3375.  
  3376.     `ADVISORY'
  3377.           ignores the hunk if the OS doesn't understand the type. A
  3378.           kind of Debug-Hunk that can be used by the OS.(V39)
  3379.  
  3380.     `ATTR=?'
  3381.           loads the hunk into the memory with specified memory
  3382.           attributs. (V37)
  3383.  
  3384. [Label] code [Name[, Memtyp]]
  3385. .............................
  3386.  
  3387.    defines a new code hunk and is equivalent to the command `section
  3388. ?,code,?'.
  3389.  
  3390.    * Name = Hunkname
  3391.  
  3392.    * Memtype defines the memory attributes for the hunk.
  3393.  
  3394.     `PUBLIC'
  3395.           loads the hunk into the memory with the highest priority.
  3396.           Code Suffix _p.
  3397.  
  3398.     `CHIP'
  3399.           loads the hunk into chip memory. Code Suffix _c.
  3400.  
  3401.     `FAST'
  3402.           loads the hunk into fast memory. Code Suffix _f.
  3403.  
  3404.     `ADVISORY'
  3405.           ignores the hunk if the OS doesn't understand the type. A
  3406.           kind of Debug-Hunk that can be used by the OS.(V39)
  3407.  
  3408.     `ATTR=?'
  3409.           loads the hunk into the memory with specified memory
  3410.           attributs. (V37)
  3411.  
  3412. [Label] data [Name[, Memtyp]]
  3413. .............................
  3414.  
  3415.    defines a new data hunk and is equivalent to the command `section
  3416. ?,data,?'.
  3417.  
  3418.    * Name = Hunkname
  3419.  
  3420.    * Memtype defines the memory attributes for the hunk.
  3421.  
  3422.     `PUBLIC'
  3423.           loads the hunk into the memory with the highest priority.
  3424.           Code Suffix _p.
  3425.  
  3426.     `CHIP'
  3427.           loads the hunk into chip memory. Code Suffix _c.
  3428.  
  3429.     `FAST'
  3430.           loads the hunk into fast memory. Code Suffix _f.
  3431.  
  3432.     `ADVISORY'
  3433.           ignores the hunk if the OS doesn't understand the type. A
  3434.           kind of Debug-Hunk that can be used by the OS.(V39)
  3435.  
  3436.     `ATTR=?'
  3437.           loads the hunk into the memory with specified memory
  3438.           attributs. (V37)
  3439.  
  3440. [Label] bss [Name[, Memtyp]]
  3441. ............................
  3442.  
  3443.    defines a new BSS hunk and is equivalent to the command `section
  3444. ?,bss,?'.
  3445.  
  3446.    * Name = Hunkname
  3447.  
  3448.    * Memtype defines the memory attributes for the hunk.
  3449.  
  3450.     `PUBLIC'
  3451.           loads the hunk into the memory with the highest priority.
  3452.           Code Suffix _p.
  3453.  
  3454.     `CHIP'
  3455.           loads the hunk into chip memory. Code Suffix _c.
  3456.  
  3457.     `FAST'
  3458.           loads the hunk into fast memory. Code Suffix _f.
  3459.  
  3460.     `ADVISORY'
  3461.           ignores the hunk if the OS doesn't understand the type. A
  3462.           kind of Debug-Hunk that can be used by the OS.(V39)
  3463.  
  3464.     `ATTR=?'
  3465.           loads the hunk into the memory with specified memory
  3466.           attributs. (V37)
  3467.  
  3468. [Label] cseg [Name[, Memtyp]]
  3469. .............................
  3470.  
  3471.    has the same function as the command `code'.
  3472.  
  3473. [Label] dseg [Name[, Memtyp]]
  3474. .............................
  3475.  
  3476.    has the same function as the command `data'.
  3477.  
  3478. idnt Name
  3479. .........
  3480.  
  3481.    defines the name of the `HUNK_UNIT' hunk in the object file.
  3482.  
  3483.    * Name = Hunkname
  3484.  
  3485. identify Name
  3486. .............
  3487.  
  3488.    defines the name of the actual hunk.
  3489.  
  3490.    * Name = Hunkname
  3491.  
  3492. BDebugArg Argument
  3493. ..................
  3494.  
  3495.    defines a parameter in env:BDebugProgram. It doesn't active this
  3496. function you have to activate by option "-J" in *Note BOPT: MI_BOPT.
  3497.  
  3498.    * Argument = Argument Text
  3499.  
  3500. smalldata [Register]
  3501. ....................
  3502.  
  3503.    activates smalldata mode for the hunk.  Optionally, you can also
  3504. define the smalldata register.  Default register is `A4'.  The program
  3505. itself must initialize the smalldata register with the address of the
  3506. smalldata data hunk.
  3507.  
  3508.  
  3509.  
  3510.       bopt    w2-            ;68020 addressmode warnings off
  3511.       mc68020            ;68020 mode activated
  3512.      
  3513.       smalldata    a3        ;Default is A4!!!
  3514.       xref    _LinkerDB        ;Special linker symbol
  3515.      
  3516.       lea.l    _LinkerDB,a3        ;Address of the smalldata data segments
  3517.       move.l    #0,(d_test.l,a3)
  3518.       move.l    #"TEST",d_test(a3)
  3519.       moveq    #0,d0
  3520.       tst.b    array(a3,d0.w)
  3521.       rts
  3522.      
  3523.       section    "__MERGED",BSS    ;The smalldata data segments are defined
  3524.                                      ;the following way
  3525.      d_test:
  3526.       ds.l    1
  3527.      array:
  3528.       ds.b    20
  3529.  
  3530. xref Symbol[, Symbol...]
  3531. ........................
  3532.  
  3533.    imports a symbol so that you can access symbols that were exported
  3534. by XDef.  The linker resolves these reference during the link process
  3535. and creates a program file.  If the assembler finds a XRef in the source
  3536. it creates an object file. This decision can be overruled.
  3537.  
  3538.    * Symbol = Name of the importet symbol.
  3539.  
  3540. xdef Symbol[, Symbol...]
  3541. ........................
  3542.  
  3543.    exports a symbol as global so that other object files can import the
  3544. symbol by XRef.  There's no need to define a symbol before you mark them
  3545. with XDef. If the assembler finds a XRef in the source it creates an
  3546. object file. This decision can be overruled.
  3547.  
  3548.    * Symbol = Name of the global symbol
  3549.  
  3550. global Symbol[, Symbol...]
  3551. ..........................
  3552.  
  3553.    has the same function like XDef.
  3554.  
  3555. public Symbol[, Symbol...]
  3556. ..........................
  3557.  
  3558.    has the same function like XDef.
  3559.  
  3560. output Name
  3561. ...........
  3562.  
  3563.    sets an output filename.  If you don't specify a filename the
  3564. assembler uses the source filename and adds the appropriate filetype
  3565. suffix.
  3566.  
  3567.    * Name = Filename
  3568.  
  3569. objfile
  3570. .......
  3571.  
  3572.    has the same function like Output.
  3573.  
  3574. exeobj
  3575. ......
  3576.  
  3577.    writes a program file if you want to overrule the assembler.
  3578.  
  3579. linkobj
  3580. .......
  3581.  
  3582.    writes an object file if you want to overrule the assembler.
  3583.  
  3584. org Address
  3585. ...........
  3586.  
  3587.    activates absolute mode.  All command that refer to hunk related
  3588. functions aren't allowed.  For example:. section, xdef, xref.  The
  3589. parameter address sets the base address of the created code.
  3590.  
  3591.    * Address = Absolute Address
  3592.  
  3593. addsym
  3594. ......
  3595.  
  3596.    writes a symbol hunk.
  3597.  
  3598. debug
  3599. .....
  3600.  
  3601.    writes a SAS D1 debug hunk to see  source level informations while
  3602. debugging the program through bdebug.
  3603.  
  3604. Symbol Commands
  3605. ---------------
  3606.  
  3607. CArgs [#Offset,]Symbol[,Symbol.w[,Symbol.l]
  3608. ...........................................
  3609.  
  3610.    defines the symbol offsets for a stack function. The first Symbol
  3611. starts with the offset 4 but if you like to use a different Offset it's
  3612. possible to specify one.  Then the offset is increased according to the
  3613. size of the symbol. If the symbol has no size specifier the default size
  3614. is word. Sorry..i would use a longword here but to be compatible with
  3615. Devpac i'm forced to use word.
  3616.  
  3617.       cargs Test1.w,Test2.l
  3618.       move.w    Test1(a7),d0    ;Test1=4
  3619.       move.l    Test2(a7),d0    ;Test2=4+2=6
  3620.  
  3621. Symbol rs[.width] Count
  3622. .......................
  3623.  
  3624.    initializes the Symbol with the value of the counter __RS and
  3625. increases the __RS counter afterwards by Count*Width.  You can use this
  3626. command as a replacement for the include exec/types.i macros to
  3627. increase the parsing speed.
  3628.  
  3629.    * Width
  3630.  
  3631.     `B'
  3632.           1 Byte Valuearea: -$80 <= x < $100
  3633.  
  3634.     `W'
  3635.           2 Bytes Valuearea: -$8000 <= x < $10000
  3636.  
  3637.     `L'
  3638.           4 Bytes Valuearea: -$80000000 <= x < $10000000
  3639.  
  3640.     `S'
  3641.           4 Bytes (Single IEEE-Float)
  3642.  
  3643.     `D'
  3644.           8 Bytes (Double IEEE-Float)
  3645.  
  3646.     `X'
  3647.           12 Bytes (Extended IEEE-Float)
  3648.  
  3649.     `P'
  3650.           12 Bytes (Packed BCD-Float)
  3651.  
  3652.     `Q'
  3653.           16 Bytes (Quadword)
  3654.  
  3655. Symbol so[.width] Count
  3656. .......................
  3657.  
  3658.    This command has the same function like rs with the exception that
  3659. the Symbol __SO is used instead of the __RS symbol.  Internally both
  3660. symbols are handled equal.  Devpac has introduced the symbol __RS and
  3661. Macro68k knows the functionality by the name __SO.
  3662.  
  3663. Symbol fo[.width] Count
  3664. .......................
  3665.  
  3666.    decreases the counter __FO by Count*Width and initializes the Symbol
  3667. with the new value.  Useful to create the negative local stackframe
  3668. symbols needed by link.
  3669.  
  3670.    * Width
  3671.  
  3672.     `B'
  3673.           1 Byte Valuearea: -$80 <= x < $100
  3674.  
  3675.     `W'
  3676.           2 Bytes Valuearea: -$8000 <= x < $10000
  3677.  
  3678.     `L'
  3679.           4 Bytes Valuearea: -$80000000 <= x < $10000000
  3680.  
  3681.     `S'
  3682.           4 Bytes (Single IEEE-Float)
  3683.  
  3684.     `D'
  3685.           8 Bytes (Double IEEE-Float)
  3686.  
  3687.     `X'
  3688.           12 Bytes (Extended IEEE-Float)
  3689.  
  3690.     `P'
  3691.           12 Bytes (Packed BCD-Float)
  3692.  
  3693.     `Q'
  3694.           16 Bytes (Quadword)
  3695.  
  3696. rsreset
  3697. .......
  3698.  
  3699.    initializes the counter __RS to 0.
  3700.  
  3701. rsset Value
  3702. ...........
  3703.  
  3704.    initializes the counter __RS with the Value
  3705.  
  3706.    * Value = New Index
  3707.  
  3708. clrso
  3709. .....
  3710.  
  3711.    has the same function like rsreset
  3712.  
  3713. clrfo
  3714. .....
  3715.  
  3716.    has the same function like foreset.
  3717.  
  3718. setso Value
  3719. ...........
  3720.  
  3721.    has the same function like rsset
  3722.  
  3723. setrs Value
  3724. ...........
  3725.  
  3726.    has the same function like rsset
  3727.  
  3728. setfo Value
  3729. ...........
  3730.  
  3731.    initializes the counter __FO with the Value
  3732.  
  3733.    * Value = New Index
  3734.  
  3735. Symbol rsval
  3736. ............
  3737.  
  3738.    initializes the Symbol with the value of the __RS counter.
  3739.  
  3740. Symbol soval
  3741. ............
  3742.  
  3743.    has the same function like rsval.
  3744.  
  3745. Symbol foval
  3746. ............
  3747.  
  3748.    initializes the Symbol with the value of the __FO counter.
  3749.  
  3750. Data Commands
  3751. -------------
  3752.  
  3753. align Value
  3754. ...........
  3755.  
  3756.    aligns the program counter to an address that can be devided by the
  3757. value.  Useful because certain DOS structures have to be aligned on 4
  3758. Byte boundaries. For example FileInfoBlock.  Furthermore it's also
  3759. useful to align subroutines on longword boundaries that they fit better
  3760. into the cache structure.
  3761.  
  3762.    * Value = Align Mask
  3763.  
  3764. cnop Offset,Align
  3765. .................
  3766.  
  3767.    aligns the program counter to an address that can be devided by the
  3768. Align value and adds the value onto the address.  Internally only Align
  3769. values < 16 are supported.
  3770.  
  3771. pad.Width Align[,Value]
  3772. .......................
  3773.  
  3774.    aligns the program counter to an address that can be devided by the
  3775. Align*Width and fills the aligned area by the optional mask value.
  3776.  
  3777. quad
  3778. ....
  3779.  
  3780.    aligns the program counter to a 16 Byte address.
  3781.  
  3782. even
  3783. ....
  3784.  
  3785.    aligns the program counter to an even address.  This function is
  3786. useful if you define an odd sized data area and you need a word aligned
  3787. for OS data structures or assembler instructions.
  3788.  
  3789. odd
  3790. ...
  3791.  
  3792.    aligns the program counter to an odd address.
  3793.  
  3794. dc[.width] Value[,Value...]
  3795. ...........................
  3796.  
  3797.    inserts data of the Width into the code.
  3798.  
  3799.    * Width
  3800.  
  3801.     `B'
  3802.           1 Byte Valuearea: -$80 <= x < $100
  3803.  
  3804.     `W'
  3805.           2 Bytes Valuearea: -$8000 <= x < $10000
  3806.  
  3807.     `L'
  3808.           4 Bytes Valuearea: -$80000000 <= x < $10000000
  3809.  
  3810.     `S'
  3811.           4 Bytes (Single IEEE-Float)
  3812.  
  3813.     `D'
  3814.           8 Bytes (Double IEEE-Float)
  3815.  
  3816.     `X'
  3817.           12 Bytes (Extended IEEE-Float)
  3818.  
  3819.     `P'
  3820.           12 Bytes (Packed BCD-Float)
  3821.  
  3822. db Value[,Value,...]
  3823. ....................
  3824.  
  3825.    inserts a byte with a value in the valuearea -$80 <= x < $100.
  3826.  
  3827. dw Value[,Value,...]
  3828. ....................
  3829.  
  3830.    inserts a word with a value in the valuearea -$8000 <= x < $10000.
  3831.  
  3832. dl Value[,Value,...]
  3833. ....................
  3834.  
  3835.    inserts a longword with a value in the valuearea -$80000000 <= x <
  3836. $100000000.
  3837.  
  3838. ub Value[,Value,...]
  3839. ....................
  3840.  
  3841.    inserts a byte with a value in the valuearea -$80 <= x < $80.
  3842.  
  3843. uw Value[,Value,...]
  3844. ....................
  3845.  
  3846.    inserts a word with a value in the valuearea -$8000 <= x < $8000.
  3847.  
  3848. ul Value[,Value,...]
  3849. ....................
  3850.  
  3851.    inserts a longword with a value in the valuearea -$80000000 <= x <
  3852. $80000000.
  3853.  
  3854. sb Value[,Value,...]
  3855. ....................
  3856.  
  3857.    inserts a byte with a value in the valuearea -$80 <= x < $100.
  3858.  
  3859. sw Value[,Value,...]
  3860. ....................
  3861.  
  3862.    inserts a word with a value in the valuearea -$8000 <= x < $10000.
  3863.  
  3864. sl Value[,Value,...]
  3865. ....................
  3866.  
  3867.    inserts a longword with a value in the valuearea -$80000000 <= x <
  3868. $100000000.
  3869.  
  3870. pb Value[,Value,...]
  3871. ....................
  3872.  
  3873.    inserts a byte with a value in the valuearea 0 <= x < $80.
  3874.  
  3875. pw Value[,Value,...]
  3876. ....................
  3877.  
  3878.    inserts a word with a value in the valuearea 0 <= x < $8000.
  3879.  
  3880. pl Value[,Value,...]
  3881. ....................
  3882.  
  3883.    inserts a longword with a value in the valuearea 0 <= x < $80000000.
  3884.  
  3885. nb Value[,Value,...]
  3886. ....................
  3887.  
  3888.    inserts a byte with a value in the valuearea -$80 <= x < 0.
  3889.  
  3890. nw Value[,Value,...]
  3891. ....................
  3892.  
  3893.    inserts a word with a value in the valuearea -$8000 <= x < 0.
  3894.  
  3895. nl Value[,Value,...]
  3896. ....................
  3897.  
  3898.    inserts a longword with a value in the valuearea -$80000000 <= x < 0.
  3899.  
  3900. ds[.width] Count[,Value]
  3901. ........................
  3902.  
  3903.    defines a memory area with the length Count * Width and fills the
  3904. area with an optional Value.  Default fill value is 0.  Is the Count 0
  3905. a cnop 0,Width is run.
  3906.  
  3907.    * Width
  3908.  
  3909.     `B'
  3910.           1 Byte Valuearea: -$80 <= x < $100
  3911.  
  3912.     `W'
  3913.           2 Bytes Valuearea: -$8000 <= x < $10000
  3914.  
  3915.     `L'
  3916.           4 Bytes Valuearea: -$80000000 <= x < $10000000
  3917.  
  3918.     `S'
  3919.           4 Bytes (Single IEEE-Float)
  3920.  
  3921.     `D'
  3922.           8 Bytes (Double IEEE-Float)
  3923.  
  3924.     `X'
  3925.           12 Bytes (Extended IEEE-Float)
  3926.  
  3927.     `P'
  3928.           12 Bytes (Packed BCD-Float)
  3929.  
  3930.    * Count = Length of the memory area.
  3931.  
  3932.    * Value = optional Fill Value.
  3933.  
  3934. dsb[.width] Count[,Value]
  3935. .........................
  3936.  
  3937.    has the same function like ds
  3938.  
  3939. dsb[.width] Count[,Value]
  3940. .........................
  3941.  
  3942.    has the same function like ds
  3943.  
  3944. blk[.width] Count[,Value...]
  3945. ............................
  3946.  
  3947.    has the same function like ds
  3948.  
  3949. ascii String1[,String2,...]
  3950. ...........................
  3951.  
  3952.    inserts Strings.
  3953.  
  3954. cstring String1[,String2,...]
  3955. .............................
  3956.  
  3957.    inserts C-Strings.
  3958.  
  3959. dstring dtype1,dtype2,dtype3
  3960. ............................
  3961.  
  3962.    inserts the current date string.
  3963.  
  3964.                               Datentypen
  3965.  
  3966.    * "w" WeekDay
  3967.  
  3968.    * "d" Date
  3969.  
  3970.    * "t" Time
  3971.  
  3972.  
  3973.       dc.b    " ("
  3974.       dstring    w,d,t
  3975.       dc.b    ")"
  3976.       dc.b    $a,$d,0
  3977.      ;=> (Thursday 14-Okt-93 15:32:06)
  3978.  
  3979. pstring String[,String,...]
  3980. ...........................
  3981.  
  3982.    inserts a BCPL string.
  3983.  
  3984. istring String[,String,...]
  3985. ...........................
  3986.  
  3987.    inserts strings that terminate with a char that has Bit 7 set.
  3988.  
  3989. bitstream Mask
  3990. ..............
  3991.  
  3992.    inserts a bitmask for an image object for example.  The bits are
  3993. aligned to bytes.
  3994.  
  3995.    * Mask =  Mask is a string that is based only of 0 and 1.
  3996.  
  3997.  
  3998.       bitstream "01001000001"
  3999.  
  4000. sprintx "Formatstring"[,Value[,...]]
  4001. ....................................
  4002.  
  4003.    inserts the resulting string into the code.  The string isn't
  4004. terminated by a 0 so that you can add other strings rather easy.
  4005.  
  4006.    * FormatString - is a string in C-Notation so you can
  4007.            use the known C char types n,t,...
  4008.      The following options are allowed.
  4009.  
  4010.    * FormatSyntax - %[flags][width][.limit][length]type
  4011.  
  4012.         * flags - '-' deactivates left side layout.
  4013.  
  4014.         * width - Field Length. If the first char is '0' the field is
  4015.           filled by '0' on the left side.
  4016.  
  4017.         * limit - defines the maximal count of char that can be inserted
  4018.           from a string. Only legal for %s and %b.
  4019.  
  4020.         * length - The size of the datatype. Default is 16-bit for the
  4021.           typs %d,%u and %x. %l is long (32Bit). Attention! The
  4022.           Assembler always pushes a longword on the stack so always use
  4023.           %l if you don't know what you're doing.
  4024.  
  4025.         * type - The following types are supported.
  4026.  
  4027.           b - BSTR, a 32-bit BPTR Pointer on a bytelength     string.
  4028.             A NULL BPTR is handled like an empty string.  d - signed
  4029.           decimal u - unsigned decimal x - hexadezimal in lower case.
  4030.           X - hexadecimal in upper case.  s - String, a 32-bit Pointer
  4031.           on a     NULL-terminated Byte-String.      A NULL BPTR is
  4032.           handled like an empty string.  c - Char
  4033.  
  4034.    * Value - is an argument that has to be resolvable.
  4035.  
  4036. Listing I/O Commands
  4037. --------------------
  4038.  
  4039. list
  4040. ....
  4041.  
  4042.    activates the listing output. Has no function if the global listing
  4043. output wasn't activated.
  4044.  
  4045.                             Listing Format:
  4046.  
  4047.             LINE ADDRESS[Flag1] COMMAND-BYTES[Flag2] SOURCE
  4048.  
  4049.    * Flag1
  4050.  
  4051.         * + shows that the line was created by a macro.
  4052.  
  4053.         * > shows that the Assembler searches the closing ENDC.
  4054.  
  4055.         * < shows that the Assembler searches the closing ENDM.
  4056.  
  4057.    * Flag2
  4058.  
  4059.         * + shows a line overflow and that Bytes are ignored.  Can
  4060.           often happen during data definitions.
  4061.  
  4062. nolist
  4063. ......
  4064.  
  4065.    deactivates the listing output. Has no function if the global
  4066. listing output wasn't activated.
  4067.  
  4068. printx "Formatstring"[,Value[,...]]
  4069. ...................................
  4070.  
  4071.    outputs the string to the current Stdout and works similar as the
  4072. known C-Printf function. Look at SPRINTF
  4073.  
  4074. errfile Name
  4075. ............
  4076.  
  4077.    defines the filename for the error output.
  4078.  
  4079.    * Name = Filename
  4080.  
  4081. lisfile Name
  4082. ............
  4083.  
  4084.    defines the filename for the listing output.  If no error file was
  4085. defined the error output is also written into the listing file.
  4086.  
  4087.    * Name = Filename
  4088.  
  4089. Structuring
  4090. -----------
  4091.  
  4092. symbol[:] macro
  4093. ...............
  4094.  
  4095.    starts a Macro block.
  4096.  
  4097. endm
  4098. ....
  4099.  
  4100.    ends a macroblock.
  4101.  
  4102. mexit
  4103. .....
  4104.  
  4105.    ends a macro call.
  4106.  
  4107. fail
  4108. ....
  4109.  
  4110.    creates an error.
  4111.  
  4112. end
  4113. ...
  4114.  
  4115.    ends the assembling.
  4116.  
  4117. if Symbol
  4118. .........
  4119.  
  4120.    checks if the symbol value is not NULL and assembles the block
  4121. depending on the success.
  4122.  
  4123. ifd Symbol
  4124. ..........
  4125.  
  4126.    checks if the Symbol exists and assembles the block depending on the
  4127. success.
  4128.  
  4129. ifnd Symbol
  4130. ...........
  4131.  
  4132.    checks if the Symbol doesn't exist and assembles the block depending
  4133. on the success.
  4134.  
  4135. ifv String
  4136. ..........
  4137.  
  4138.    This is a privat command that is used for internal functionality and
  4139. subject to change. Touch an burn!
  4140.  
  4141. ifnv String
  4142. ...........
  4143.  
  4144.    This is a privat command that is used for internal functionality and
  4145. subject to change. Touch an burn!
  4146.  
  4147. ifmacrod Macro
  4148. ..............
  4149.  
  4150.    checks if the Macro exists and assembles the block depending on the
  4151. success.
  4152.  
  4153. ifmacrond Macro
  4154. ...............
  4155.  
  4156.    checks if the Macro doesn't exist and assembles the block depending
  4157. on the success.
  4158.  
  4159. ifcmacrod CMacro
  4160. ................
  4161.  
  4162.    checks if the CMacro exists and assembles the block depending on the
  4163. success.
  4164.  
  4165. ifcmacrond CMacro
  4166. .................
  4167.  
  4168.    checks if the CMacro doesn't exist and assembles the block depending
  4169. on the success.
  4170.  
  4171. ifc Symbol,Symbol
  4172. .................
  4173.  
  4174.    compares the first string with the second string and if they are
  4175. equal the block is assembled.
  4176.  
  4177. ifnc 'String','String'
  4178. ......................
  4179.  
  4180.    compares the first string with the second string and if they differ
  4181. the block is assembled.
  4182.  
  4183. if[condition] Symbol=Symbol
  4184. ...........................
  4185.  
  4186.    compares the first symbol with the second symbol and decides
  4187. according to the condition if the block is assembled.
  4188.  
  4189.    * Condition = Normal Bcc-Condition Syntax
  4190.  
  4191.    * Symbol = Normal Symbol
  4192.  
  4193. else
  4194. ....
  4195.  
  4196.    activates the condition block if the block above wasn't assembled.
  4197.  
  4198. elseif
  4199. ......
  4200.  
  4201.    activates the condition block if the block above wasn't assembled.
  4202.  
  4203. endc
  4204. ....
  4205.  
  4206.    defines the end of a condition block.
  4207.  
  4208. endif
  4209. .....
  4210.  
  4211.    defines the end of a condition block.
  4212.  
  4213. repeat Count
  4214. ............
  4215.  
  4216.    repeats the blocks that is located between repeat and endr by the
  4217. number Count.
  4218.  
  4219. rept Count
  4220. ..........
  4221.  
  4222.    has the same function like Repeat
  4223.  
  4224. procstart
  4225. .........
  4226.  
  4227.    defines a function in a Dice-C assembler output and is used to
  4228. optimize Link and Unlk.  This optimize method isn't working yet.
  4229.  
  4230. procend
  4231. .......
  4232.  
  4233.    defines a function in a Dice-C assembler output and is used to
  4234. optimize Link and Unlk.  This optimize method isn't working yet.
  4235.  
  4236. File I/O Commands
  4237. -----------------
  4238.  
  4239. incdir Dir[,Dir[,...]]
  4240. ......................
  4241.  
  4242.    adds directories to the include path list.  BASM uses 2 internal
  4243. path lists and the current directory to find the include and incbin
  4244. files.  First BASM checks for a : character in the filename and if it
  4245. finds a volume the file is loaded direct instead of searching it
  4246. through the pathlists.  The first path list contains the paths that
  4247. were defined in the commandline or *Note BOPT: MI_BOPT by the option -i
  4248. or through incdir.  The second path list contains the paths that were
  4249. defined in global configuration file ENV:BASMOption.  The entries of
  4250. the second list will be removed when the assembler is closed so that
  4251. the paths are still correct in ARexx-Mode.  The first list is removed
  4252. every pass.
  4253.  
  4254.    * Dir = Name of the Include-Path.
  4255.  
  4256. Incpath
  4257. .......
  4258.  
  4259.    has the same function like incdir.
  4260.  
  4261. include Name
  4262. ............
  4263.  
  4264.    loads the external include file, for example the OS-Includes.  If
  4265. the file is a precompiled include file it's detected automaticlly.
  4266. Includes are loaded from the editor or cachefile.library.
  4267.  
  4268.    * Name = Filename
  4269.  
  4270. include2 Name
  4271. .............
  4272.  
  4273.    has the same function like include with the exception that the
  4274. cachefile.library isn't ignored.
  4275.  
  4276.    * Name = Filename
  4277.  
  4278. incbin Name[,size]
  4279. ..................
  4280.  
  4281.    inserts the file with the optional length at the current address
  4282. into the code. Normally used for sounds and graphics.
  4283.  
  4284. incbin2 Name[,size]
  4285. ...................
  4286.  
  4287.    has the same function like incbin with the exception that the
  4288. cachefile.library isn't used.
  4289.  
  4290.    * Name = Name of the data file.
  4291.  
  4292. ibytes Name[,Length]
  4293. ....................
  4294.  
  4295.    has the same function like incbin
  4296.  
  4297. dsbin Name[,Length]
  4298. ...................
  4299.  
  4300.    defines a memory area with the length of the file specified by the
  4301. file. Optinally you can defined the maximal file length.
  4302.  
  4303.    * Name = Filename
  4304.  
  4305.    * Length = maximal file length
  4306.  
  4307. doscmd Name
  4308. ...........
  4309.  
  4310.    runs the program Name.
  4311.  
  4312.       dc.b    0,"$VER: Fubar 1.0 by Joe User"
  4313.       doscmd    "c:date >ram:Temp"
  4314.       incbin    ram:Temp
  4315.       doscmd    "c:delete ram:Temp"
  4316.  
  4317. pure
  4318. ....
  4319.  
  4320.    sets the Pure Bit while writing a program file.
  4321.  
  4322. Miscellaneous
  4323. -------------
  4324.  
  4325. trashreg Reglist
  4326. ................
  4327.  
  4328.    defines the registers that are available to the optimizer.
  4329.  
  4330.    * RegList = A normal Registerlist known by Movem.
  4331.  
  4332. super
  4333. .....
  4334.  
  4335.    deactivates Supervisor warnings.
  4336.  
  4337. mc[Type]
  4338. ........
  4339.  
  4340.    defines the processor type to allow certain commands and
  4341. addressmodes.
  4342.  
  4343.                             Processor-Type
  4344.  
  4345.    * 68000 default mode
  4346.  
  4347.    * 68010
  4348.  
  4349.    * 68020
  4350.  
  4351.    * 68030
  4352.  
  4353.    * 68040
  4354.  
  4355.    * 68060
  4356.  
  4357.    * 68881
  4358.  
  4359.    * 68882
  4360.  
  4361. bopt [opt[,...],...]
  4362. ....................
  4363.  
  4364.    sets the assembler options.
  4365.  
  4366.                                 Options
  4367.  
  4368. `m1[+,-]'
  4369.      activates/deactivates 68010 mode.
  4370.  
  4371. `m2[+,-]'
  4372.      activates/deactivates 68020 mode.
  4373.  
  4374. `m3[+,-]'
  4375.      activates/deactivates 68030 mode.
  4376.  
  4377. `m4[+,-]'
  4378.      activates/deactivates 68040 mode.
  4379.  
  4380. `m6[+,-]'
  4381.      activates/deactivates 68060 mode.
  4382.  
  4383. `mf[+,-]'
  4384.      activates/deactivates 68881/2 mode.
  4385.  
  4386. `ue[+,-]'
  4387.      activates/deactivates writing an executable file.
  4388.  
  4389. `uo[+,-]'
  4390.      activates/deactivates writing an object file.
  4391.  
  4392. `ua[+,-]'
  4393.      activates/deactivates writing an absolut file.
  4394.  
  4395. `un[+,-]'
  4396.      activates/deactivates writing file.
  4397.  
  4398. `p[+,-]'
  4399.      activates/deactivates writing a preassembled Include file.
  4400.  
  4401. `g[+,-]'
  4402.      activates/deactivates adding the prefix _ to each exported symbol.
  4403.      Default is off.
  4404.  
  4405. `sx[+,-]'
  4406.      activates/deactivates writing all XRef/XDef symbols to a symbol
  4407.      hunk.  Default is off.
  4408.  
  4409. `sl[+,-]'
  4410.      activates/deactivates writing all normal symbols to a symbol hunk.
  4411.      Default is off.
  4412.  
  4413. `sa[+,-]'
  4414.      activates/deactivates writing all symbols to a symbol hunk.
  4415.      Default is off.
  4416.  
  4417. `sd[+,-]'
  4418.      activates/deactivates writing a BASM custom format Debug Hunk.
  4419.      Makes only sense as a program file and it needs a lot hd space
  4420.      because it includes all sources. Default is off.
  4421.  
  4422. `s1[+,-]'
  4423.      activates/deactivates writing a SAS D1 compatible Debug Hunk.
  4424.      Default is off.
  4425.  
  4426. `sf[+,-]'
  4427.      activates/deactivates writing the full sourcefile path into the
  4428.      debug hunk.  You should only use this for your own development
  4429.      system because other users may have different HD layouts. This
  4430.      option has only a meaning with in a SAS D1 Debug Hunk. Default is
  4431.      off.
  4432.  
  4433. `j[+,-]'
  4434.      activates/deactivates setting the PURE Bit for a program file.
  4435.      The PURE Bit tells the Shell that this program can be loaded
  4436.      resident.  Default is off.
  4437.  
  4438. `J[+,-]'
  4439.      activates/deactivates creating the file ENV:BDebugProgram that
  4440.      contains the assembled filename for BDebug.  Default is off.
  4441.  
  4442. `a[+,-]'
  4443.      activates/deactivates creating of an .info file for each program.
  4444.      Useful if you use the assembler through the WB.  Default is off.
  4445.  
  4446. `A[+,-]'
  4447.      activates/deactivates Arexxmode. Only allowed in the commandline.
  4448.      Default is off.
  4449.  
  4450. `i<DirName>'
  4451.      defines the include path.
  4452.  
  4453. `o<FileName>'
  4454.      defines the object filename. If not specified the assembler uses
  4455.      the source file name without the source suffix as the output name.
  4456.      For object files it adds the suffix `.o'.
  4457.  
  4458. `P<Priority>'
  4459.      sets the task priority.
  4460.  
  4461. `c[+,-]'
  4462.      activates/deactivates that the assembler interpretes Upper and
  4463.      Lower case as 2 different chars.  Default is on.
  4464.  
  4465. `f[+,-]'
  4466.      activates/deactivates a faster mode that resolves all references
  4467.      in the 2nd pass.  Fortunately this mode needs more memory and has
  4468.      some disadvantages like uncorrect values during the listing.  This
  4469.      option has no effect during optimizing.  Default is off.
  4470.  
  4471. `M<Bytes>'
  4472.      defines the max macro expansion size.  If you get a macromemerror
  4473.      you should increase the size. Default 1000 Bytes.
  4474.  
  4475. `Z<Address>'
  4476.      tells the assembler that the source is starts in the memory at the
  4477.      defined address.  Useful for ARexx scripts.  Option is only
  4478.      available in the commandline.
  4479.  
  4480. `x[+,-]'
  4481.      uses the `cachefile.library' to load resident Includes/Incbins or
  4482.      add unknown files to the cachefile.library database.  Default is
  4483.      off.
  4484.  
  4485. `X[+,-]'
  4486.      erases all files that are controled by the cachefile.library.
  4487.      Default is off.
  4488.  
  4489. `y[+,-]'
  4490.      shows all files that are controled by the cachefile.library.
  4491.      Default is off.
  4492.  
  4493. `l[+,-]'
  4494.      activates/deactivates the listing output.  Default is off.
  4495.  
  4496. `l0[+,-]'
  4497.      activates/deactivates the listing macro expansion.  Default is on.
  4498.  
  4499. `L<Listingfile>'
  4500.      defines the Listing filename.
  4501.  
  4502. `h[+,-]'
  4503.      activates/deactivates the symbol listing output.  Default is off.
  4504.  
  4505. `H[+,-]'
  4506.      activates/deactivates the unused symbol output.  Default is off.
  4507.  
  4508. `v[+,-]'
  4509.      outputs a statistic after assembling.  Default is off.
  4510.  
  4511. `V[+,-]'
  4512.      as little status output as possible Default is off.
  4513.  
  4514. `e[+,-]'
  4515.      creates an error list.  Default is on.
  4516.  
  4517. `es[+,-]'
  4518.      outputs the error list in the Barfly shell.  This option has no
  4519.      meaning in BASM.
  4520.  
  4521. `wo[+,-]'
  4522.      activates/deactivates Optimizing warnings.  Default is on.
  4523.  
  4524. `ws[+,-]'
  4525.      activates/deactivates Supervisor warnings.  Default is on.
  4526.  
  4527. `wm[+,-]'
  4528.      activates/deactivates Move16 warnings because the use of the
  4529.      move16 command is dangerous if you don't know the problems.
  4530.      Default is on.
  4531.  
  4532. `wp[+,-]'
  4533.      activates/deactivates pc-relative access to different section
  4534.      warnings. The linker is needed to resolve such files.  Default is
  4535.      on.
  4536.  
  4537. `w2[+,-]'
  4538.      activates/deactivates 68020 addressmode warnings.  Default is on.
  4539.  
  4540. `w4[+,-]'
  4541.      activates/deactivates 64k-Access warnings.  It's useful if you
  4542.      accidently avoid to forget the address register.  Example: move.l
  4543.      8,d0 instead of move.l 8(an),d0 Default is on.
  4544.  
  4545. `b0'
  4546.      sets the Default Branch Length to 8-Bit. .b Default is off.
  4547.  
  4548. `b1'
  4549.      sets the Default Branch Length to 16-Bit. .w Default is on.
  4550.  
  4551. `b2'
  4552.      sets the Default Branch Length to 32-Bit. .l Default is off.
  4553.  
  4554. `B0'
  4555.      sets the Default BaseDisplacement-Width to 8 Bit. .b Default is on.
  4556.  
  4557. `B1'
  4558.      sets the Default BaseDisplacement-Width to 16 Bit. .w Default is
  4559.      off.
  4560.  
  4561. `B2'
  4562.      sets the Default BaseDisplacement-Width to 32 Bit. .l Default is
  4563.      off.
  4564.  
  4565. `n0'
  4566.      sets the Default OuterDisplacement-Width to 16 Bit. .w Default is
  4567.      off.
  4568.  
  4569. `n1'
  4570.      sets the Default OuterDisplacement-Width to 32 Bit. .l Default is
  4571.      on.
  4572.  
  4573. `q[+,-]'
  4574.      activates/deactivates align long after each rts, bra or jmp to
  4575.      align blocks to the cache structure.  Default is off.
  4576.  
  4577. `O[+,-]'
  4578.      activates/deactivates the Optimizer.  Without this option no
  4579.      optimizing will happen besides addressmode converting.  Default is
  4580.      off.
  4581.  
  4582. `OG[+,-]'
  4583.      activates/deactivates Forward Reference Optimizing to use every
  4584.      possibility. In this mode the source is assembled until no further
  4585.      optimizing method is found.  First the source is assembled
  4586.      normally.  This is shown by the Output Pass 1.  Afterwards the
  4587.      optimize passes are started and continued until no further symbol
  4588.      changes and length errors occur.  This can take a while and
  4589.      depends on the source size. Default is off.
  4590.  
  4591. `OT[+,-]'
  4592.      activates/deactivates Time Optimizing.  Default is off.
  4593.  
  4594.      Addressmode Converting
  4595.  
  4596. `OC0[+,-]'
  4597.      *Note bdwan: OP_DIRECT
  4598.  
  4599. `OC1[+,-]'
  4600.      *Note bdwpc: OP_DIRECT
  4601.  
  4602. `OC2[+,-]'
  4603.      *Note anxn: OP_DIRECT
  4604.  
  4605. `OC3[+,-]'
  4606.      *Note pcxn: OP_DIRECT
  4607.  
  4608. `OC4[+,-]'
  4609.      *Note bdw: OP_DIRECT
  4610.  
  4611. `OC5[+,-]'
  4612.      *Note bdl: OP_DIRECT
  4613.  
  4614. `OC6[+,-]'
  4615.      *Note an: OP_DIRECT
  4616.  
  4617. `OC7[+,-]'
  4618.      *Note pc: OP_DIRECT
  4619.  
  4620. `ODD[+,-]'
  4621.      activates Direct Addressmode Optimizing
  4622.  
  4623.      Direct Optimizing
  4624.  
  4625. `OD0[+,-]'
  4626.      *Note move: OP_OPTIMIZE
  4627.  
  4628. `OD1[+,-]'
  4629.      *Note clr: OP_OPTIMIZE
  4630.  
  4631. `OD2[+,-]'
  4632.      *Note add: OP_OPTIMIZE
  4633.  
  4634. `OD3[+,-]'
  4635.      *Note sub: OP_OPTIMIZE
  4636.  
  4637. `OD4[+,-]'
  4638.      *Note lea: OP_OPTIMIZE
  4639.  
  4640. `OD5[+,-]'
  4641.      *Note cmp: OP_OPTIMIZE
  4642.  
  4643. `OD6[+,-]'
  4644.      *Note bcc: OP_OPTIMIZE
  4645.  
  4646. `OD7[+,-]'
  4647.      *Note jsr: OP_OPTIMIZE
  4648.  
  4649. `OD8[+,-]'
  4650.      *Note jmp: OP_OPTIMIZE
  4651.  
  4652. `OD9[+,-]'
  4653.      *Note asl: OP_OPTIMIZE
  4654.  
  4655. `ODa[+,-]'
  4656.      *Note or: OP_OPTIMIZE  ( This Optimizing is deactivated internal )
  4657.  
  4658. `ODb[+,-]'
  4659.      *Note eor: OP_OPTIMIZE ( This Optimizing is deactivated internal )
  4660.  
  4661. `ODc[+,-]'
  4662.      *Note and: OP_OPTIMIZE
  4663.  
  4664. `ODd[+,-]'
  4665.      *Note mulu: OP_OPTIMIZE
  4666.  
  4667. `ODe[+,-]'
  4668.      *Note muls: OP_OPTIMIZE
  4669.  
  4670. `ODf[+,-]'
  4671.      *Note jsr+rts: OP_OPTIMIZE
  4672.  
  4673. `ODg[+,-]'
  4674.      *Note jmp+rts: OP_OPTIMIZE
  4675.  
  4676. `ODh[+,-]'
  4677.      *Note MovemNoRegister: OP_OPTIMIZE
  4678.  
  4679. `ODi[+,-]'
  4680.      *Note MovemOneRegister: OP_OPTIMIZE
  4681.  
  4682. `ODj[+,-]'
  4683.      *Note Link: OP_OPTIMIZE
  4684.  
  4685. `OAP[+,-]'
  4686.      activates *Note PC-Relative: OP_ADDRESS Optimizing
  4687.  
  4688. `OAS[+,-]'
  4689.      activates *Note Smalldata: OP_ADDRESS Optimizing
  4690.  
  4691. `OAL[+,-]'
  4692.      activates *Note long to word: OP_ADDRESS Optimizing
  4693.  
  4694. `OAX[+,-]'
  4695.      activates *Note x(An) to (An): OP_ADDRESS Optimizing
  4696.  
  4697. `OAY[+,-]'
  4698.      activates *Note 68020 An-EA: OP_ADDRESS Optimizing
  4699.  
  4700. `OAZ[+,-]'
  4701.      activates *Note 68020 PC-EA: OP_ADDRESS Optimizing
  4702.  
  4703. `OAR[+,-]'
  4704.      activates *Note Register: OP_REGISTER Optimizing
  4705.  
  4706.    You should be careful with the command *Note BOPT: MI_BOPT when you
  4707. activate Global-Optimize.  In every parse the default config is set and
  4708. therefore you should define all global options in the commandline or in
  4709. the configuration file.
  4710.  
  4711. 680xx Meta Commands
  4712. -------------------
  4713.  
  4714. mb Operand1,Operand2
  4715. ....................
  4716.  
  4717.    has the same function as move.b.
  4718.  
  4719. mw Operand1,Operand2
  4720. ....................
  4721.  
  4722.    has the same function as move.w.
  4723.  
  4724. ml Operand1,Operand2
  4725. ....................
  4726.  
  4727.    has the same function as move.l.
  4728.  
  4729. mq Operand1,Operand2
  4730. ....................
  4731.  
  4732.    has the same function as moveq.
  4733.  
  4734. xor.? Operand1,Operand2
  4735. .......................
  4736.  
  4737.    has the same function as eor.?.
  4738.  
  4739. xori.? Operand1,Operand2
  4740. ........................
  4741.  
  4742.    has the same function as eori.?.
  4743.  
  4744. bhs.? Label
  4745. ...........
  4746.  
  4747.    has the same function as bcc.?.
  4748.  
  4749. blo.? Label
  4750. ...........
  4751.  
  4752.    has the same function as bcs.?.
  4753.  
  4754. Assembler Macros
  4755. ================
  4756.  
  4757.    Macros are meta commands that can be based of many assembler
  4758. instructions to achieve an abstracter source layout.  In a macro you
  4759. can use several different pattern that are replaced by appropriate
  4760. parameters when the macro is called.  The parameter that are passed
  4761. during a macro call are represented by the following patterns:
  4762. \0,...,\9, \a,...,\z, \A,...,\Z.  The pattern ids are using the
  4763. hexadecimal format.  If a pattern is used with no related parameter an
  4764. empty string is inserted.  Furthermore if a parameter contains
  4765. tabulators or spaces it has to be placed between <...>.  When a macro
  4766. needs relative labels and is should be called more than one time you
  4767. should use the special pattern @.  This pattern is replaced by a number
  4768. that is based of 4 digits and that is increased after each call.  The
  4769. pattern \# is replaced by the value of the symbol narg that represents
  4770. the count of macro parameters.  Besides the standard patterns there are
  4771. some more advanced pattern functions supported that look like
  4772. \*Function-Name.  These functions don't belong to the motorola standard
  4773. thus they aren't supported by every assembler.  Another important point
  4774. is that you can also call macros from from macros but you can't define
  4775. macros in macros.
  4776.  
  4777.    The standard macro pattern
  4778.  
  4779.    Label & [. string] & [, string] & [, string] & [,...]        & [\\0]
  4780. & [\\1|] & [\\2|] & [\\3|]...[\\n|]
  4781.  
  4782.    The advanced macro pattern functions
  4783.  
  4784.    * ` \(Argument)' inserts the string of the macroparameter with the
  4785.      number the argument defines.
  4786.  
  4787.  
  4788.           \(1) =  \1
  4789.           \(1+3+4) = \8
  4790.  
  4791.    * `\*upper(String)' inserts the string in upper case.
  4792.  
  4793.    * `\*lower(String)' inserts the string in lower case.
  4794.  
  4795.    * `\*valof(Argument)' inserts the decimal value of the argument as a
  4796.      string.
  4797.  
  4798.    * `\*strlen(Symbol)' inserts the length of a symbol as a string.
  4799.  
  4800.    * `\*right(String,n)' inserts n chars of the right side of the
  4801.      string.  If the string contains less than n chars the whole string
  4802.      is inserted.
  4803.  
  4804.    * `\*left(String,n)' inserts n chars of the left side of the string.
  4805.      If the string contains less than n chars the whole string is
  4806.      inserted.
  4807.  
  4808.    * `\*mid(String,n,m)' inserts chars from position n to m from the
  4809.      string.  If the position is outside of the string length the chars
  4810.      till the end of the string is inserted.
  4811.  
  4812.  
  4813.      openwind MACRO
  4814.               move.l     intbase,a6
  4815.               lea.l      \1,a0
  4816.               jsr        OpenWindow(a6)
  4817.               ENDM
  4818.      
  4819.      start:
  4820.               openwind   newwindow
  4821.  
  4822.  
  4823.  
  4824.      movewind MACRO
  4825.               move.l     intbase,a6
  4826.               move.l     \1,a0
  4827.               moveq      #0,d0
  4828.               move.\0    \2,d1
  4829.               IFC        `\0',`b'
  4830.               ext.w      d1
  4831.               ENDC
  4832.               jsr        MoveWindow(a6)
  4833.               ENDM
  4834.      
  4835.      start:
  4836.               move.b     #10,d2
  4837.      1$:
  4838.               movewind.b newwindow,d2
  4839.               addq.b     #1,d2
  4840.               cmp.b      #100,d2
  4841.               bne.s      1$
  4842.  
  4843.  
  4844.      wait MACRO
  4845.               moveq      #-1,d0
  4846.      wait\
  4847.               dbra       d0,wait\
  4848.               ENDM
  4849.      
  4850.      start:
  4851.               wait
  4852.               wait
  4853.               wait
  4854.  
  4855.  
  4856.      test MACRO
  4857.               move.l     #\*upper(Hello),d0
  4858.               move.l     #\*lower(Hello),d0
  4859.               move.l     #\*strlen(1234567890123456),d0
  4860.               move.l     #\*valof(value),d0
  4861.               rts
  4862.      
  4863.               cstring    "\*left(abcdefgh,4)"
  4864.               even
  4865.               cstring    "\*left(abcdefgh,10)"
  4866.               even
  4867.               cstring    "\*right(abcdefgh,4)"
  4868.               even
  4869.               cstring    "\*right(abcdefgh,10)"
  4870.               even
  4871.               cstring    "\*mid(abcdefgh,2,4)"
  4872.               even
  4873.               cstring    "\*mid(abcdefgh,2,8)"
  4874.               even
  4875.      
  4876.               ENDM
  4877.      
  4878.      value = 123456789
  4879.      hello:
  4880.               test
  4881.  
  4882.  
  4883.       value = 123456789
  4884.      
  4885.      
  4886.      hello:
  4887.               move.l     #HELLO,d0
  4888.               move.l     #hello,d0
  4889.               move.l     #16,d0
  4890.               move.l     #123456789,d0
  4891.               rts
  4892.               cstring    "abcd"
  4893.               even
  4894.               cstring    "abcdefgh"
  4895.               even
  4896.               cstring    "efgh"
  4897.               even
  4898.               cstring    "abcdefgh"
  4899.               even
  4900.               cstring    "cdef"
  4901.               even
  4902.               cstring    "cdefgh"
  4903.               even
  4904.  
  4905.  
  4906.      PUTTAG MACRO
  4907.               IFC        "\2",""
  4908.      PUTTAG_COUNT set 0
  4909.               ENDC
  4910.      
  4911.               IFNC       "\2",""
  4912.               move.l     \2,-(a7)
  4913.      PUTTAG_COUNT SET PUTTAG_COUNT+4
  4914.               ENDC
  4915.      
  4916.               move.l     \1,-(a7)
  4917.      PUTTAG_COUNT SET PUTTAG_COUNT+4
  4918.      
  4919.               IFC        "\1","#TAG_END"
  4920.      PUTTAG_COUNT SET 4
  4921.               ENDC
  4922.      
  4923.               ENDM
  4924.      
  4925.      CLEARTAG MACRO
  4926.               lea.l      PUTTAG_COUNT(a7),a7
  4927.               ENDM
  4928.      
  4929.      
  4930.      
  4931.               PUTTAG     #TAG_END
  4932.               PUTTAG     #WA_Width,#100
  4933.               PUTTAG     #WA_ScreenTitle,#Title
  4934.               .
  4935.               .
  4936.               move.l     a7,a1
  4937.               sub.l      a0,a0
  4938.               jsr        OpenWindowTagList(a6)
  4939.               CLEARTAG
  4940.  
  4941. Highlevel Macros
  4942. ================
  4943.  
  4944.    In highlevel macros the operands are based of legal addressmodes.
  4945. Arguments are based of operands and the operators +,-,<<,>>. Conditions
  4946. are based of !,=, <,>,<=,>=,<>.  By using highlevel macros you can make
  4947. the programming of non critical source areas easier and more abstract.
  4948. Blame Mike Schwartz for this idea...he forced me to do it:-B
  4949.  
  4950. .REG
  4951. ....
  4952.  
  4953.    sets the accumulator register that is used to calculate arguments.
  4954. Default register is D0.
  4955.  
  4956. .BRANCH b|w|l
  4957. .............
  4958.  
  4959.    sets the length of branch commands that are used in the highlevel
  4960. macros.  Standard length is .b.
  4961.  
  4962. .FOR Operand[.b|w|l] = Operand TO Operand STEP Operand
  4963. ......................................................
  4964.  
  4965.    creates code for a for loop.  The optional width you define after
  4966. the first operand sets the width for all operations in the for loop.
  4967.  
  4968.  
  4969.        .FOR   d0.w = #1 to  STEP #2
  4970.        addq.w #1,d1
  4971.        .NEXT
  4972.      
  4973.        ;Compiled Code
  4974.      
  4975.        move.w #1,d0
  4976.      __for1:
  4977.        addq.w #1,d1
  4978.        add.w  #2,d0
  4979.        cmp.w  ,d0
  4980.        blt.b  __for1
  4981.  
  4982. .NEXT
  4983. .....
  4984.  
  4985.    closes the outer .FOR loop.
  4986.  
  4987. .IF [Argument] =,!, < , > , <> Operand
  4988. ......................................
  4989.  
  4990.    creates code for an IF-Operation.  You can remove the first argument
  4991. if you want to test the operand.  For example .IF <>
  4992.  
  4993.  
  4994.        .IF    (a0) + #0 <> d1
  4995.        moveq  #0,d0
  4996.        .ELSE
  4997.        moveq  #1,d0
  4998.        .ENDIF
  4999.      
  5000.        ;Compiled Code
  5001.      
  5002.        move.l (a0),d7
  5003.        add.l  #0,d7
  5004.        cmp.l  d1,d7
  5005.        beq.b  __else1
  5006.        moveq  #0,d0
  5007.        bra.b  __endif1
  5008.      __else1:
  5009.        moveq  #1,d0
  5010.      __endif1:
  5011.  
  5012. .ELSE
  5013. .....
  5014.  
  5015.    starts an alternative IF-Block.
  5016.  
  5017. .ENDIF
  5018. ......
  5019.  
  5020.    closes the outer .IF block.
  5021.  
  5022. .WHILE [Argument] =,!, < , > , <> Operand
  5023. .........................................
  5024.  
  5025.    creates code for a while loop The optional width you define after
  5026. the first operand sets the width for all operations in the while loop.
  5027.  
  5028.  
  5029.        .WHILE d0 <> #0
  5030.        addq.w #1,d1
  5031.        .ENDWHILE
  5032.      
  5033.        ;Compiled Code
  5034.      
  5035.      __while1:
  5036.        cmp.l  #0,d0
  5037.        beq.s  __endwhile1
  5038.        addq.w #1,d1
  5039.        bra.s  __while1
  5040.      __endwhile1:
  5041.  
  5042. .ENDWHILE
  5043. .........
  5044.  
  5045.    closes the outer while loop.
  5046.  
  5047. .CALL Function [, Argument [, Argument [,...]]]
  5048. ...............................................
  5049.  
  5050.    calls a C-Function by parsing the arguments through the stack.
  5051. Arguments are calculated in the accumulator register.
  5052.  
  5053.  
  5054.  
  5055.        .CALL func , test + 0 - #20 , #test
  5056.      
  5057.        ;Compiled Code
  5058.      
  5059.        move.l test,d7
  5060.        add.l  0,d7
  5061.        sub.l  #20,d7
  5062.        move.l d7,-(a7)
  5063.        move.l #test,-(a7)
  5064.        jsr    func
  5065.        ifnc   "8","0"             ;Were there any parameters ?
  5066.        lea.l  __CALLSize(a7),a7
  5067.        endc
  5068.  
  5069. .RETURN Argument
  5070. ................
  5071.  
  5072.    returns a result value in the accumulator register.
  5073.  
  5074.  
  5075.        .return d1 + d2 + #$100
  5076.      
  5077.        ;Compiled Code
  5078.      
  5079.      
  5080.        move.l d1,d7
  5081.        add.l  d2,d7
  5082.        add.l  #$100,d7
  5083.  
  5084. .DEF func [, Operand [, Operand [,...]]]
  5085. ........................................
  5086.  
  5087.    defines a C-Stack function and loads the defined parameters into the
  5088. operands.
  5089.  
  5090.  
  5091.        .DEF func , d0.w , d1 , (a0)
  5092.        .ENDDEF
  5093.      
  5094.        ;Compiled Code
  5095.      
  5096.        XDEF   func
  5097.        link   a5,#0
  5098.        move.w $0a(a5),d0
  5099.        move.l $0c(a5),d1
  5100.        move.l $10(a5),(a0)
  5101.        unlk   a5            ;.ENDDEF
  5102.        rts
  5103.  
  5104. .ENDDEF
  5105. .......
  5106.  
  5107.    closes a function that was started by .DEF
  5108.  
  5109. .LET [ Operand =] Argument
  5110. ..........................
  5111.  
  5112.    calculates an argument in an accumulator or moves the value to a
  5113. defined operand.
  5114.  
  5115.  
  5116.        .LET + 4 - #LN_SIZE << #7
  5117.        .LET d1 = (a1) - (a0)
  5118.      
  5119.        ;Compiled Code
  5120.      
  5121.        add.l  4,d7
  5122.        sub.l  #LN_SIZE,d7
  5123.        lsl.l  #7,d7
  5124.      
  5125.        move.l (a1),d7
  5126.        sub.l  (a0),d7
  5127.        move.l d7,d1
  5128.  
  5129. Predefined Symbols
  5130. ==================
  5131.  
  5132. NARG
  5133. ....
  5134.  
  5135.    represents the macro parameter count in a macro.
  5136.  
  5137. BARFLY
  5138. ......
  5139.  
  5140.    represents the assembler version.
  5141.  
  5142. 680xx
  5143. .....
  5144.  
  5145.    represents the CPU processor type.
  5146.  
  5147. 6888x
  5148. .....
  5149.  
  5150.    represents the FPU processor type.
  5151.  
  5152. _MOVEMBYTES
  5153. ...........
  5154.  
  5155.    represents the byte count the last movem transfer used.
  5156.  
  5157.  
  5158.       lea    _MOVEMBYTES(a7),a7    ;frees the stack
  5159.  
  5160. _MOVEMREGS
  5161. ..........
  5162.  
  5163.    represents the last movem register mask.
  5164.  
  5165.  
  5166.       movem    (a7)+,_MOVEMREGS
  5167.  
  5168. __RS
  5169. ....
  5170.  
  5171.    represents the RS-Counter.
  5172.  
  5173. __SO
  5174. ....
  5175.  
  5176.    represents the RS-Counter.
  5177.  
  5178. __FO
  5179. ....
  5180.  
  5181.    represents the FO-Counter.
  5182.  
  5183. Optimizing
  5184. ==========
  5185.  
  5186.    Optimize Methods...
  5187.  
  5188. Direct Addressmode Optimizing
  5189. -----------------------------
  5190.  
  5191.    The assembler can direct optimize certain 68020...60 Addressmodes if
  5192. a faster 68000 addressmode exists.  This optimizing method should
  5193. always be activated because of compatibility reasons.
  5194.  
  5195.    * `(bd.w,an)' can be optimized to `x(an)' that removes 1 word and
  5196.      some cycles.
  5197.  
  5198.      +------------------------+--------------------+--------+
  5199.      |       Addressmode      |     Optimizing     | Option |
  5200.      +------------------------+--------------------+--------+
  5201.      +------------------------+--------------------+--------+
  5202.      | move. l (1000.w,an),dn | move.l 1000(an),dn |  -OC0  |
  5203.      +------------------------+--------------------+--------+
  5204.  
  5205.    * `(bd.w,pc)' can be optimized to `x(pc)' that removes 1 word and
  5206.      some cycles.
  5207.  
  5208.      +------------------------+--------------------+--------+
  5209.      |       Addressmode      |     Optimizing     | Option |
  5210.      +------------------------+--------------------+--------+
  5211.      +------------------------+--------------------+--------+
  5212.      | move. l (1000.w,pc),dn | move.l 1000(pc),dn |  -OC1  |
  5213.      +------------------------+--------------------+--------+
  5214.  
  5215.    * `(bd.w)' can be optimized to `bd.w' that removes 1 word and some
  5216.      cycles.
  5217.  
  5218.      +------------------------+--------------------+--------+
  5219.      |       Addressmode      |     Optimizing     | Option |
  5220.      +------------------------+--------------------+--------+
  5221.      +------------------------+--------------------+--------+
  5222.      |  move. l (bd.w),dn     |   move.l bd.w,dn   |  -OC4  |
  5223.      +------------------------+--------------------+--------+
  5224.  
  5225.    * `(bd.l)' can be optimized to `bd.l' that removes 1 word and some
  5226.      cycles.
  5227.  
  5228.      +------------------------+--------------------+--------+
  5229.      |       Addressmode      |     Optimizing     | Option |
  5230.      +------------------------+--------------------+--------+
  5231.      +------------------------+--------------------+--------+
  5232.      |  move. l (bd.l),dn     |   move.l bd.l,dn   |  -OC5  |
  5233.      +------------------------+--------------------+--------+
  5234.  
  5235.    * `(an)' can be optimized to `(an)' that removes 1 word and some
  5236.      cycles.  The addressmode `(an)' can be interpreted as a subgroup
  5237.      of `(bd,an,xn)'. Because `(an)' is a normal 68000 addressmode you
  5238.      should never switch off this optimizing method.
  5239.  
  5240.      +------------------------+--------------------+--------+
  5241.      |       Addressmode      |     Optimizing     | Option |
  5242.      +------------------------+--------------------+--------+
  5243.      +------------------------+--------------------+--------+
  5244.      |     move. l (an),dn    |   move.l (an),dn   |  -OC6  |
  5245.      +------------------------+--------------------+--------+
  5246.  
  5247.    * `(pc)' can be optimized to `(pc)' that removes 1 word and some
  5248.      cycles.  The addressmode `(pc)' can be interpreted as a subgroup
  5249.      of `(bd,pc,xn)'. Because `(pc)' is a normal 68000 addressmode you
  5250.      should never switch off this optimizing method.
  5251.  
  5252.      +------------------------+--------------------+--------+
  5253.      |       Addressmode      |     Optimizing     | Option |
  5254.      +------------------------+--------------------+--------+
  5255.      +------------------------+--------------------+--------+
  5256.      |     move. l (pc),dn    |   move.l (pc),dn   |  -OC7  |
  5257.      +------------------------+--------------------+--------+
  5258.  
  5259. Address Optimizing
  5260. ------------------
  5261.  
  5262.    * `Long'
  5263.  
  5264.      +---------------+----------------+---------------------+--------+
  5265.      | Addressmode   |   Optimizing   |         Note        | Option |
  5266.      +---------------+----------------+---------------------+--------+
  5267.      +---------------+----------------+---------------------+--------+
  5268.      |     x.l,EA    |    x.w,EA      | $ffff8000<=x<=$7fff |        |
  5269.      +---------------+----------------+---------------------+  -OAL  |
  5270.      |     EA,x.l    |    EA,x.l      | $ffff8000<=x<=$7fff |        |
  5271.      +---------------+----------------+---------------------+--------+
  5272.  
  5273.    * `x(an)'
  5274.  
  5275.      +---------------+----------------+---------------------+--------+
  5276.      | Addressmode   |   Optimizing   |         Note        | Option |
  5277.      +---------------+----------------+---------------------+--------+
  5278.      +---------------+----------------+---------------------+--------+
  5279.      |   x(an),EA    |    (an),EA     |         x=0         |        |
  5280.      +---------------+----------------+---------------------+  -OAX  |
  5281.      |   EA,x(an)    |    EA,(an)     |         x=0         |        |
  5282.      +---------------+----------------+---------------------+--------+
  5283.  
  5284.    * `PC-Relative'
  5285.  
  5286.      +---------------+----------------+---------------------+--------+
  5287.      | Addressmode   |   Optimizing   |         Note        | Option |
  5288.      +---------------+----------------+---------------------+--------+
  5289.      +---------------+----------------+---------------------+--------+
  5290.      |   label,EA    |  label(pc),EA  | $ffff8000<=x<=$7fff |  -OAP  |
  5291.      +---------------+----------------+---------------------+--------+
  5292.  
  5293.    * `A4-Smalldata'
  5294.  
  5295.      +---------------+----------------+---------------------+--------+
  5296.      | Addressmode   |   Optimizing   |         Note        | Option |
  5297.      +---------------+----------------+---------------------+--------+
  5298.      +---------------+----------------+---------------------+--------+
  5299.      |     x.l,EA    |    x(a4),EA    | $ffff8000<=x<=$7fff |        |
  5300.      +---------------+----------------+---------------------+  -OAS  |
  5301.      |     EA,x.l    |    EA,x(a4)    | $ffff8000<=x<=$7fff |        |
  5302.      +---------------+----------------+---------------------+--------+
  5303.  
  5304.    * `68020-An'
  5305.  
  5306.      +---------------+----------------+---------------------+--------+
  5307.      | Addressmode   |   Optimizing   |         Note        | Option |
  5308.      +---------------+----------------+---------------------+--------+
  5309.      +---------------+----------------+---------------------+--------+
  5310.      |   (x.l,an)    |    (an)        | x=0                 |  -OAY  |
  5311.      +---------------+----------------+---------------------+        |
  5312.      |   (x.l,an)    |    x(an)       | $ffffff80<=x<=$7f   |        |
  5313.      +---------------+----------------+---------------------+        |
  5314.      |   (x,an,xn)   |    0(an,xn)    | x=0                 |        |
  5315.      +---------------+----------------+---------------------+        |
  5316.      |   (x,an,xn)   |    (x.b,an,xn) | $ffffff80<=x<=$7f   |        |
  5317.      +---------------+----------------+---------------------+        |
  5318.      |   (x,an,xn)   |    (x.w,an,xn) | $ffff8000<=x<=$7fff |        |
  5319.      +---------------+----------------+---------------------+        |
  5320.      |   ([?],x)     |    ([?])       | x=0                 |        |
  5321.      |               |                | ? is also optimized |        |
  5322.      +---------------+----------------+---------------------+        |
  5323.      |   ([?],x)     |    ([?],x.w)   | $ffff8000<=x<=$7fff |        |
  5324.      |               |                | ? is also optimized |        |
  5325.      +---------------+----------------+---------------------+        |
  5326.      |   ([?],xn,x)  |    ([?],xn)    | x=0                 |        |
  5327.      |               |                | ? is also optimized |        |
  5328.      +---------------+----------------+---------------------+        |
  5329.      |   ([?],xn,x)  |    ([?],xn,x.w)| $ffff8000<=x<=$7fff |        |
  5330.      |               |                | ? is also optimized |        |
  5331.      +---------------+----------------+---------------------+--------+
  5332.  
  5333.    * `68020-PC'
  5334.  
  5335.      +---------------+----------------+---------------------+--------+
  5336.      | Addressmode   |   Optimizing   |         Note        | Option |
  5337.      +---------------+----------------+---------------------+--------+
  5338.      +---------------+----------------+---------------------+--------+
  5339.      |   (x.l,pc)    |    (pc)        | x=0                 |  -OAZ  |
  5340.      +---------------+----------------+---------------------+        |
  5341.      |   (x.l,pc)    |    x(pc)       | $ffffff80<=x<=$7f   |        |
  5342.      +---------------+----------------+---------------------+        |
  5343.      |   (x,pc,xn)   |    0(pc,xn)    | x=0                 |        |
  5344.      +---------------+----------------+---------------------+        |
  5345.      |   (x,pc,xn)   |    (x.b,pc,xn) | $ffffff80<=x<=$7f   |        |
  5346.      +---------------+----------------+---------------------+        |
  5347.      |   (x,pc,xn)   |    (x.w,pc,xn) | $ffff8000<=x<=$7fff |        |
  5348.      +---------------+----------------+---------------------+        |
  5349.      |   ([?],x)     |    ([?])       | x=0                 |        |
  5350.      |               |                | ? is also optimized |        |
  5351.      +---------------+----------------+---------------------+        |
  5352.      |   ([?],x)     |    ([?],x.w)   | $ffff8000<=x<=$7fff |        |
  5353.      |               |                | ? is also optimized |        |
  5354.      +---------------+----------------+---------------------+        |
  5355.      |   ([?],xn,x)  |    ([?],xn)    | x=0                 |        |
  5356.      |               |                | ? is also optimized |        |
  5357.      +---------------+----------------+---------------------+        |
  5358.      |   ([?],xn,x)  |    ([?],xn,x.w)| $ffff8000<=x<=$7fff |        |
  5359.      |               |                | ? is also optimized |        |
  5360.      +---------------+----------------+---------------------+--------+
  5361.  
  5362. #x Optimizing
  5363. -------------
  5364.  
  5365.    * `Move'
  5366.  
  5367.      +-------------------+------------------+-------------------------+--------+
  5368.      | Addressmode       |   Optimizing     |         Note            | Option |
  5369.      +-------------------+------------------+-------------------------+--------+
  5370.      +-------------------+------------------+-------------------------+--------+
  5371.      |  move.l #x,dn     |   moveq #x,dn    |    $ffffff80<=$7f       |  -OD0  |
  5372.      +-------------------+------------------+-------------------------+        |
  5373.      |  move.? #0,an     |  suba.l an,an    |      ? = w or l         |        |
  5374.      +-------------------+------------------+-------------------------+        |
  5375.      |  move.l #x,dn     | moveq #y,dn      | $10000<=x<=$7f0000      |        |
  5376.      |                   | swap dn          |                         |        |
  5377.      +-------------------+------------------+-------------------------+        |
  5378.      |  move.l #x,dn     | moveq #y,dn      | $ff80ffff<=x<=$fffEffff |        |
  5379.      |                   | swap dn          |                         |        |
  5380.      +-------------------+------------------+-------------------------+        |
  5381.      |  move.l #x,dn     | moveq #y,dn      |      $80<=x<=$ff        |        |
  5382.      |                   | neg.b dn         |                         |        |
  5383.      +-------------------+------------------+-------------------------+        |
  5384.      |  move.l #x,dn     | moveq #y,dn      |     $ffff<=x<=$ff81     |        |
  5385.      |                   | neg.w dn         |                         |        |
  5386.      +-------------------+------------------+-------------------------+        |
  5387.      |  move.l #x,dn     | moveq #y,dn      | $ffff0080<=x<=$ffff0001 |        |
  5388.      |                   | neg.w dn         |                         |        |
  5389.      +-------------------+------------------+-------------------------+        |
  5390.      |  move.? #0,EA     | clr.? EA         | ? = w or l.See Trashreg |        |
  5391.      |                   |                  | optimizing. I also check|        |
  5392.      |                   |                  | if it accesses the HW   |        |
  5393.      +-------------------+------------------+-------------------------+        |
  5394.      | move.b #$ff,EA    | st EA            |                         |        |
  5395.      +-------------------+------------------+-------------------------+        |
  5396.      | movea.l -4(an),an | movea.l -(an),an |                         |        |
  5397.      +-------------------+------------------+-------------------------+--------+
  5398.  
  5399.    * `Clr'
  5400.  
  5401.      +---------------+----------------+-------------------------+--------+
  5402.      | Addressmode   |   Optimizing   |         Note            | Option |
  5403.      +---------------+----------------+-------------------------+--------+
  5404.      +---------------+----------------+-------------------------+--------+
  5405.      |    clr.l dn   |   moveq #0,dn  |                         |  -OD1  |
  5406.      +---------------+----------------+-------------------------+--------+
  5407.  
  5408.    * `Add'
  5409.  
  5410.      +---------------+----------------+-------------------------+--------+
  5411.      | Addressmode   |   Optimizing   |         Note            | Option |
  5412.      +---------------+----------------+-------------------------+--------+
  5413.      +---------------+----------------+-------------------------+--------+
  5414.      |  add.? #x,EA  |  addq.? #x,EA  |       1<=x<=8           |  -OD2  |
  5415.      +---------------+----------------+-------------------------+        |
  5416.      |  add.? #x,EA  |  subq.? #x,EA  |      -8<=x<=-1          |        |
  5417.      +---------------+----------------+-------------------------+        |
  5418.      |  add.? #x,an  | lea.l x(an),an |   $ffff8000<=x<=$7fff   |        |
  5419.      +---------------+----------------+-------------------------+        |
  5420.      |  add.? #0,EA  | tst.? EA       |       legal EA          |        |
  5421.      +---------------+----------------+-------------------------+        |
  5422.      |  add.? #0,an  | removed        |                         |        |
  5423.      +---------------+----------------+-------------------------+--------+
  5424.  
  5425.    * `Sub'
  5426.  
  5427.      +---------------+----------------+-------------------------+--------+
  5428.      | Addressmode   |   Optimizing   |         Note            | Option |
  5429.      +---------------+----------------+-------------------------+--------+
  5430.      +---------------+----------------+-------------------------+--------+
  5431.      |  sub.? #x,EA  |  subq.? #x,EA  |       1<=x<=8           |  -OD3  |
  5432.      +---------------+----------------+-------------------------+        |
  5433.      |  sub.? #x,EA  |  addq.? #x,EA  |      -8<=x<=-1          |        |
  5434.      +---------------+----------------+-------------------------+        |
  5435.      |  sub.? #x,an  |lea.l -x(an),an |   $ffff8000<=x<=$7fff   |        |
  5436.      +---------------+----------------+-------------------------+        |
  5437.      |  sub.? #0,EA  | tst.? EA       |       legal EA          |        |
  5438.      +---------------+----------------+-------------------------+        |
  5439.      |  sub.? #0,an  | removed        |                         |        |
  5440.      +---------------+----------------+-------------------------+--------+
  5441.  
  5442.    * `Lea'
  5443.  
  5444.      +---------------+----------------+-------------------------+--------+
  5445.      | Addressmode   |   Optimizing   |         Note            | Option |
  5446.      +---------------+----------------+-------------------------+--------+
  5447.      +---------------+----------------+-------------------------+--------+
  5448.      | lea x(an),an  |  addq.w #x,an  |       1<=x<=8           |        |
  5449.      +---------------+----------------+-------------------------+  -OD4  |
  5450.      | lea x(an),an  |  subq.w #x,an  |      -8<=x<=-1          |        |
  5451.      +---------------+----------------+-------------------------+--------+
  5452.  
  5453.    * `Cmp'
  5454.  
  5455.      +---------------+----------------+-------------------------+--------+
  5456.      | Addressmode   |   Optimizing   |         Note            | Option |
  5457.      +---------------+----------------+-------------------------+--------+
  5458.      +---------------+----------------+-------------------------+--------+
  5459.      |  cmp.? #0,EA  |   tst.? EA     |                         |  -OD5  |
  5460.      +---------------+----------------+-------------------------+--------+
  5461.  
  5462.    * `Bcc'
  5463.  
  5464.      The assembler tries to optimize the branch on the smallest
  5465.      possible length so that can win max 2 words and some cycles.
  5466.  
  5467.      +---------------+----------------+-------------------------+--------+
  5468.      | Addressmode   |   Optimizing   |         Note            | Option |
  5469.      +---------------+----------------+-------------------------+--------+
  5470.      +---------------+----------------+-------------------------+--------+
  5471.      |  Bcc.l label  |  Bcc.w label   |   $8000<=label<=$7fff   |  -OD6  |
  5472.      +---------------+----------------+-------------------------+        |
  5473.      |  Bcc.l label  |  Bcc.s label   |     $80<=label<=$7f     |        |
  5474.      +---------------+----------------+-------------------------+        |
  5475.      |  Bcc.w label  |  Bcc.s label   |     $80<=label<=$7f     |        |
  5476.      +---------------+----------------+-------------------------+--------+
  5477.  
  5478.      Attention! This optimizing methid is unsafe when you use
  5479.      BRANCH-Tables.  You should switch off the optimize method over
  5480.      this area.
  5481.  
  5482.  
  5483.    * `Jsr'
  5484.  
  5485.      +---------------+----------------+-------------------------+--------+
  5486.      | Addressmode   |   Optimizing   |         Note            | Option |
  5487.      +---------------+----------------+-------------------------+--------+
  5488.      +---------------+----------------+-------------------------+--------+
  5489.      |   jsr label   |  bsr.w label   |   $8000<=Offset<=$7fff  |        |
  5490.      +---------------+----------------+-------------------------+  -OD7  |
  5491.      |   jsr label   |  bsr.s label   |     $80<=Offset<=$7f    |        |
  5492.      +---------------+----------------+-------------------------+--------+
  5493.  
  5494.      Attention! This optimizing methid is unsafe when you use
  5495.      JSR-Tables.  You should switch off the optimize method over this
  5496.      area.
  5497.  
  5498.  
  5499.    * `Jmp'
  5500.  
  5501.      +---------------+----------------+-------------------------+--------+
  5502.      | Addressmode   |   Optimizing   |         Note            | Option |
  5503.      +---------------+----------------+-------------------------+--------+
  5504.      +---------------+----------------+-------------------------+--------+
  5505.      |   jmp label   |  bra.w label   |$ffff8000<=Offset<=$7fff |        |
  5506.      +---------------+----------------+-------------------------+  -OD8  |
  5507.      |   jmp label   |  bra.s label   |$ffffff80<=Offset<=$7f   |        |
  5508.      +---------------+----------------+-------------------------+--------+
  5509.  
  5510.    * `Asl'
  5511.  
  5512.      +---------------+----------------+-------------------------+--------+
  5513.      | Addressmode   |   Optimizing   |         Note            | Option |
  5514.      +---------------+----------------+-------------------------+--------+
  5515.      +---------------+----------------+-------------------------+--------+
  5516.      |  asl.? #1,dn  |  add.? dn,dn   |                         |  -OD9  |
  5517.      +---------------+----------------+-------------------------+--------+
  5518.  
  5519.    * `Or' This optimizing method isn't safe because of the changed
  5520.      condition flags.
  5521.  
  5522.      +---------------+----------------+-------------------------+--------+
  5523.      | Addressmode   |   Optimizing   |         Note            | Option |
  5524.      +---------------+----------------+-------------------------+--------+
  5525.      +---------------+----------------+-------------------------+--------+
  5526.      |  or.? #x,dn   |  bset #y,dn    | x=y^2                   |  -ODa  |
  5527.      +---------------+----------------+-------------------------+--------+
  5528.  
  5529.    * `Eor' This optimizing method isn't safe because of the changed
  5530.      condition flags.
  5531.  
  5532.      +---------------+----------------+-------------------------+--------+
  5533.      | Addressmode   |   Optimizing   |         Note            | Option |
  5534.      +---------------+----------------+-------------------------+--------+
  5535.      +---------------+----------------+-------------------------+--------+
  5536.      |  eor.? #x,dn  |  bchg #y,dn    | x=y^2                   |  -ODb  |
  5537.      +---------------+----------------+-------------------------+--------+
  5538.  
  5539.    * `Mulu'
  5540.  
  5541.      Be very careful with this optimizing.
  5542.  
  5543.      +---------------+----------------+-------------------------+--------+
  5544.      | Addressmode   |   Optimizing   |         Note            | Option |
  5545.      +---------------+----------------+-------------------------+--------+
  5546.      +---------------+----------------+-------------------------+--------+
  5547.      | mulu.w #x,dn  | swap dn        | x=2^y                   |  -ODc  |
  5548.      |               | clr.w dn       | y=y1+y2                 |        |
  5549.      |               | swap dn        | y=1,add.l dn,dn         |        |
  5550.      |               | lsl.l #y1,dn   |                         |        |
  5551.      |               | lsl.l #y2,dn   |                         |        |
  5552.      +---------------+----------------+-------------------------+        |
  5553.      | mulu.l #x,dn  | lsl.l #y1,dn   | x=2^y                   |        |
  5554.      |               | lsl.l #y2,dn   | y=y1+y2                 |        |
  5555.      |               |                | y >= 16                 |        |
  5556.      |               |                | swap dn , y-16          |        |
  5557.      +---------------+----------------+-------------------------+--------+
  5558.  
  5559.    * `Muls'
  5560.  
  5561.      Be very careful with this optimizing.
  5562.  
  5563.      +---------------+----------------+-------------------------+--------+
  5564.      | Addressmode   |   Optimizing   |         Note            | Option |
  5565.      +---------------+----------------+-------------------------+--------+
  5566.      +---------------+----------------+-------------------------+--------+
  5567.      | muls.w #x,dn  | ext.l dn       | x=2^y                   |  -ODd  |
  5568.      |               | asl.l #y1,dn   | y=y1+y2                 |        |
  5569.      |               | asl.l #y2,dn   | y=1 , add.l dn,dn       |        |
  5570.      +---------------+----------------+-------------------------+        |
  5571.      | muls.l #x,dn  | asl.l #y1,dn   | x=2^y                   |        |
  5572.      |               | asl.l #y2,dn   | y=y1+y2                 |        |
  5573.      |               |                | y >= 16                 |        |
  5574.      |               |                | swap dn ,y-16           |        |
  5575.      +---------------+----------------+-------------------------+--------+
  5576.  
  5577.    * `Jsr+Rts'
  5578.  
  5579.      +--------------+---------------+------------------------+-------+
  5580.      | Addressmode   |   Optimizing   |         Note            |
  5581.      Option |
  5582.      +--------------+---------------+------------------------+-------+
  5583.      +--------------+---------------+------------------------+-------+
  5584.      | jsr EA        | jmp EA         | No optimizing if there's|  -ODe
  5585.      | | rts           |                | a label before RTS      |
  5586.         |
  5587.      +--------------+---------------+------------------------+-------+
  5588.  
  5589.    * `Bsr+Rts'
  5590.  
  5591.      +--------------+---------------+------------------------+-------+
  5592.      | Addressmode   |   Optimizing   |         Note            |
  5593.      Option |
  5594.      +--------------+---------------+------------------------+-------+
  5595.      +--------------+---------------+------------------------+-------+
  5596.      | jmp EA        | jmp EA         | No optimizing if there's|  -ODf
  5597.      | | rts           |                | a label before RTS      |
  5598.         |
  5599.      +--------------+---------------+------------------------+-------+
  5600.  
  5601.    * `MovemNoRegister'
  5602.  
  5603.      +---------------+----------------+-------------------------+--------+
  5604.      | Addressmode   |   Optimizing   |         Note            | Option |
  5605.      +---------------+----------------+-------------------------+--------+
  5606.      +---------------+----------------+-------------------------+--------+
  5607.      |  movem.l ,EA  |     Removed    |                         |        |
  5608.      +---------------+----------------+-------------------------+  -ODh  |
  5609.      |  movem.l EA,  |     Removed    |                         |        |
  5610.      +---------------+----------------+-------------------------+--------+
  5611.  
  5612.    * `MovemOneRegister'
  5613.  
  5614.      +---------------+----------------+-------------------------+--------+
  5615.      | Addressmode   |   Optimizing   |         Note            | Option |
  5616.      +---------------+----------------+-------------------------+--------+
  5617.      +---------------+----------------+-------------------------+--------+
  5618.      | movem.l Xn,EA |  Move.l Xn,EA  | Alter the status flags! |        |
  5619.      +---------------+----------------+-------------------------+  -ODi  |
  5620.      | movem.l EA,Xn |  Move.l EA,Xn  | Alter the status flags! |        |
  5621.      +---------------+----------------+-------------------------+--------+
  5622.  
  5623. Register Optimizing
  5624. -------------------
  5625.  
  5626.    * `#xxx' is switched off.
  5627.  
  5628.         * An address register is set free by `trashreg'.
  5629.  
  5630.           +---------------+--------------------+-------------------------+--------+
  5631.           | Addressmode   |   Optimizing       |         Note            | Option |
  5632.           +---------------+--------------------+-------------------------+--------+
  5633.           +---------------+--------------------+-------------------------+--------+
  5634.           |move.? EA,label| lea.l label(pc),an | $ffff8000<=label<=$7fff |        |
  5635.           |               | move.? EA,(an)     |                         |  -OAR  |
  5636.           +---------------+--------------------+-------------------------+        |
  5637.           |  tst.?  label | lea.l label(pc),an | $ffff8000<=label<=$7fff |        |
  5638.           |               | tst.? (an)         |                         |        |
  5639.           +---------------+--------------------+-------------------------+        |
  5640.           |  not.?  label | lea.l label(pc),an | $ffff8000<=label<=$7fff |        |
  5641.           |               | not.? (an)         |                         |        |
  5642.           +---------------+--------------------+-------------------------+        |
  5643.           |  neg.?  label | lea.l label(pc),an | $ffff8000<=label<=$7fff |        |
  5644.           |               | neg.? (an)         |                         |        |
  5645.           +---------------+--------------------+-------------------------+        |
  5646.           |  negx.? label | lea.l label(pc),an | $ffff8000<=label<=$7fff |        |
  5647.           |               | negx.? (an)        |                         |        |
  5648.           +---------------+--------------------+-------------------------+        |
  5649.           |  nbcd label   | lea.l label(pc),an | $ffff8000<=label<=$7fff |        |
  5650.           |               | nbcd (an)          |                         |        |
  5651.           +---------------+--------------------+-------------------------+        |
  5652.           |   scc label   | lea.l label(pc),an | $ffff8000<=label<=$7fff |        |
  5653.           |               | scc (an)           |                         |        |
  5654.           +---------------+--------------------+-------------------------+--------+
  5655.  
  5656.    * `#x' Optimizing on.
  5657.  
  5658.         * An address register is set free by `trashreg'.
  5659.  
  5660.           +---------------+--------------------+-------------------------+--------+
  5661.           | Addressmode   |   Optimizing       |         Note            | Option |
  5662.           +---------------+--------------------+-------------------------+--------+
  5663.           +---------------+--------------------+-------------------------+--------+
  5664.           | move.l #x,EA  | moveq  #x,dn       |    $ffffff80<=x<=$7f    |        |
  5665.           |               | move.l dn,EA       |                         |  -OAR  |
  5666.           +---------------+--------------------+-------------------------+        |
  5667.           | ori.l  #x,EA  | moveq  #x,dn       |    $ffffff80<=x<=$7f    |        |
  5668.           |               | or.l   dn,EA       |                         |        |
  5669.           +---------------+--------------------+-------------------------+        |
  5670.           | eori.l #x,EA  | moveq  #x,dn       |    $ffffff80<=x<=$7f    |        |
  5671.           |               | eor.l  dn,EA       |                         |        |
  5672.           +---------------+--------------------+-------------------------+        |
  5673.           | andi.l #x,EA  | moveq  #x,dn       |    $ffffff80<=x<=$7f    |        |
  5674.           |               | and.l  dn,EA       |                         |        |
  5675.           +---------------+--------------------+-------------------------+        |
  5676.           | addi.l #x,EA  | moveq  #x,dn       |    $ffffff80<=x<=$7f    |        |
  5677.           |               | add.l  dn,EA       |                         |        |
  5678.           +---------------+--------------------+-------------------------+        |
  5679.           | subi.l #x,EA  | moveq  #x,dn       |    $ffffff80<=x<=$7f    |        |
  5680.           |               | sub.l  dn,EA       |                         |        |
  5681.           +---------------+--------------------+-------------------------+        |
  5682.           | cmpi.l #x,EA  | moveq  #x,dn       |    $ffffff80<=x<=$7f    |        |
  5683.           |               | cmp.l  EA,dn       |                         |        |
  5684.           +---------------+--------------------+-------------------------+        |
  5685.           | move.? #0,EA  | moveq  #0,dn       | Time optimizing         |        |
  5686.           |               | move.l dn,EA       | must be on              |        |
  5687.           +---------------+--------------------+-------------------------+--------+
  5688.  
  5689. How does Optimizing work ?
  5690. --------------------------
  5691.  
  5692.    In single-pass Optimizing the assembler can only optimize commands
  5693. where it can resolve the reference in the first pass.  This means the
  5694. label or symbol has to be known before.  In multi-pass Optimizing it
  5695. can optimize every command without bothering where the label is defined.
  5696. The Assembler keeps all labels each pass but increases a change counter
  5697. if the old contents differs with the new contents.  The exception is
  5698. that the assembler can't optimize commands that depend on symbols that
  5699. are defined after the command.  The reason is that the Assembler has to
  5700. remove each pass every symbol to avoid problems with `IFD' and `IFND'
  5701. that can cause that certain areas aren't assembled in multi-pass mode.
  5702. You probably noticed that i assume that nobody used `IFD' or `IFND'
  5703. with labels because that would also break multi-pass.
  5704.  
  5705.    An example for a construct that can't be optimized.
  5706.  
  5707.           move.l #1,NULL(a0)
  5708.      NULL=0
  5709.  
  5710. Problems...
  5711. -----------
  5712.  
  5713.    You should always be careful with optimizing because it can cause
  5714. bugs in certain source areas.  Branch optimizing for example has to be
  5715. switched off if you use JMP-Towers.
  5716.  
  5717.  
  5718.           lsl.w #1,d0
  5719.           jmp   Tower(pc,d0.w)
  5720.      
  5721.       Tower:
  5722.           bra.w func1
  5723.           bra.w func2
  5724.           bra.w func3
  5725.      
  5726.       could be be optimized to
  5727.      
  5728.       Tower:
  5729.           bra.w func1
  5730.           bra.s func2
  5731.           bra.s func3
  5732.      
  5733.       that leads to program bugs.
  5734.      
  5735.       Solution:
  5736.      
  5737.       bopt OD6-
  5738.      
  5739.       Tower:
  5740.           bra.w func1
  5741.           bra.w func2
  5742.           bra.w func3
  5743.      
  5744.       bopt OD6+
  5745.  
  5746. Preassembled Includes
  5747. =====================
  5748.  
  5749.    If you want to assemble a program that needs to load a lot includes
  5750. it's useful to preassemble the includes and load one file because  the
  5751. real slowdown factor is the need loading time.   You can only use
  5752. absolut symbols and macros in a preassembled file.   All relative and
  5753. symbols defined by `set' aren't written into  a preassembled file.
  5754. The created file isn't compress to avoid any slowdown but if  the file
  5755. size is critical you can compress the file by xpk and  load it through
  5756. the xfh filesystem.
  5757.  
  5758.      basm -p Source.S creates the preassembled file Source.p
  5759.  
  5760.  
  5761.      An error location could be absolut symbols that are calculated  by
  5762.      relative symbols. You should avoid these symbols.
  5763.  
  5764.      Symbol=Label1-Label2
  5765.  
  5766.  
  5767. Resident includes
  5768. =================
  5769.  
  5770.    `BASM' can control an Include and Incbin database by the library
  5771. `cachefile.library' to get rid of the loading delays.  The files in the
  5772. database can be shown and deleted.
  5773.  
  5774. Basm Assembler System
  5775. =====================
  5776.  
  5777. Cli Calling Convention
  5778. ----------------------
  5779.  
  5780.    `Format:'
  5781.  
  5782.      BASM [-Option] Name
  5783.  
  5784.  
  5785.    This is the commandline version of the assembler and can be easy
  5786. integrated in own development system, for example `Make' and `CED'.  An
  5787. assembler error is indicated by the result 20 and the result 10 is used
  5788. if no source file were specified.
  5789.  
  5790.    * `Option'
  5791.  
  5792.      The same options are accepted that are described in the assembler
  5793.      command *Note BOPT: MI_BOPT.  The following options are accepted
  5794.      additionally.
  5795.  
  5796.         * A[+,-] Turns ARexx mode on/off
  5797.  
  5798.         * C <Configuration> loads a configuration file
  5799.  
  5800.         * d <Symbol=Value> defines a symbol
  5801.  
  5802.    * `Standard-Optionen'
  5803.  
  5804.  
  5805.           ;All other options are deactivated.
  5806.           
  5807.           c+,e+,m1000,wo+,ws+,wm+,w2+,w4+,wp+
  5808.           b1+,B0+,n1+
  5809.           OC0+,OC1+,OC2+,OC3+,OC4+,OC5+,OC6+,OC7+,
  5810.           ODD+,OD0+,OD1+,OD2+,OD3+,OD4+,OD5+,OD6+,OD7+,OD8+,
  5811.           OD9+,ODc+,ODe+,ODf+,ODg+
  5812.           OAP+,OAL+,OAX+,OAY+,OAZ+,OAR+
  5813.  
  5814. Configuration
  5815. -------------
  5816.  
  5817. Global
  5818. ......
  5819.  
  5820.    You can define the global configuration through the file
  5821. `ENV:BASMOption'. The internal standard configuration  is not replaced
  5822. but can only be changed.
  5823.  
  5824.    File `ENV:BASMOption'
  5825.  
  5826.  
  5827.       -v
  5828.       -f
  5829.       -c-
  5830.       -iASM:
  5831.  
  5832.      If a line doesn't start with - it's ignored.
  5833.  
  5834.  
  5835. WB Tooltypes
  5836. ............
  5837.  
  5838.    Additionally you can also define the above described configuration
  5839. options in the tooltypes of the source file icon.   Furthermore `BASM'
  5840. allows a special tooltype to define  an output window.
  5841.  
  5842.    o Window= <Window Defintion>
  5843.  
  5844. ARexx
  5845. =====
  5846.  
  5847.    The `BASM' ARexx Port Name is `rexx_BASM' and the  ARexx Script
  5848. suffix `.basm'.   To activate the `BASM' ARexx mode you have to start
  5849. `BASM' with the option -A.
  5850.  
  5851. BASM
  5852. ....
  5853.  
  5854.    `BASM [-Option] Name'
  5855.  
  5856.    This ARexx command starts the assembler and coincides with the
  5857. CLI-syntax structure.
  5858.  
  5859. BEND
  5860. ....
  5861.  
  5862.    `BEND'
  5863.  
  5864.    This ARexx command closes the ARexx port and shuts down the
  5865. assembler.
  5866.  
  5867. BGETERROR
  5868. .........
  5869.  
  5870.    `BGETERROR'
  5871.  
  5872.    With this ARexx command you will receive an explanation of the actual
  5873. errors. If no errors exist it will return a status code 20.
  5874.  
  5875.    Error Format String
  5876.  
  5877.    OFFSET|FILE|<Error Description>
  5878.  
  5879. BNEXTERROR
  5880. ..........
  5881.  
  5882.    `BNEXTERROR'
  5883.  
  5884.    This ARexx command will cause a jump to the next error in the list.
  5885. If there are no further errors in the list it will return a status
  5886. code 20.
  5887.  
  5888. BINITERROR
  5889. ..........
  5890.  
  5891.    `BINITERROR'
  5892.  
  5893.    This ARexx command will cause a jump to the first entry in the error
  5894. list. If no error exists it will return a status code 20.
  5895.  
  5896. Compatibility
  5897. =============
  5898.  
  5899. to other assemblers...
  5900. ----------------------
  5901.  
  5902.  
  5903.      Fortunately `BASM' can't be 100% compatible to every assembler on
  5904.      the amiga market.  Thus you can expect problems with different
  5905.      sources.  In general you can expect problems with commands that
  5906.      don't belong to a standard like option commands.  Furthermore you
  5907.      should also be careful with sources that directly depend on the
  5908.      assembler implementation.  Because `BASM' is a 1-Pass Assembler in
  5909.      the normal mode with an additional backpatch phase you shouldn't
  5910.      define symbols that can't be resolved at once.  An ideal example
  5911.      for this practice is the `Xoper2.2' Source that was developed with
  5912.      the PD Assembler A68k.  While assembling with `BASM' the assembler
  5913.      detects that a not defined symbols is accessed through the `SET'
  5914.      command.  Generally this should cause an error at once but
  5915.      unfortunately `A68k' doesn't show anything and uses the last value
  5916.      of `cmdnum'.
  5917.  
  5918.  
  5919.  
  5920.           ADDCMD        MACRO
  5921.           cmdnum        set     cmdnum+1
  5922.                   dc.b    \1,0
  5923.                   ENDM
  5924.                       .
  5925.                       .
  5926.                       .
  5927.           ;Here it's using `cmdnum' although
  5928.           ;the symbol wasn't defined yet
  5929.                   addq    #1,d2
  5930.                   cmp.w   #cmdnum,d2
  5931.                   bne.s   1$
  5932.                       .
  5933.                       .
  5934.                       .
  5935.           
  5936.           ;Here the cmdnum is first defined
  5937.           cmdnum        set      0
  5938.           commds        ADDCMD  'time'
  5939.                   ADDCMD  'taskpri'
  5940.                   ADDCMD  'info'
  5941.                   ADDCMD  'pri'
  5942.                   ADDCMD  'flush'
  5943.  
  5944.      Because the A68k is a 2-Pass Assembler he can assemble this Source
  5945.      without problems.
  5946.  
  5947.  
  5948.      Another Problem is that the assembler argument parser doesn't
  5949.      detect Overflow because of speed reasons. I don't think it's worth
  5950.      it...if you differ tell me your opinion.
  5951.  
  5952.  
  5953.      The assembler doesn't support the following motorola syntax bugs
  5954.      because of the internal structure of the parser it would cause
  5955.      major problems in the multi-pass mode.
  5956.  
  5957.  
  5958.           symbol: equ 0
  5959.           symbol: equr d0
  5960.  
  5961. C-Compiler Assembler
  5962. --------------------
  5963.  
  5964. Dice
  5965. ....
  5966.  
  5967.    If you use Basm as a `DASM' replacement you have to run `Basm' with
  5968. the option -OAS to activate the Smalldata mode.  If you want to emulate
  5969. the advanced `Link', `UnLink', `Movem' optimizing `DASM' supports you
  5970. have to use the options -O, -OG, -ODh, -ODi and -ODj.  The option -OG
  5971. is needed because the link stackframe register list symbols are defined
  5972. after the commands so the assembler doesn't know them in 1 pass mode.
  5973. Sorry...i had to disable this mode because i later detected that i have
  5974. to keep track of the used registers.  I'll try to fix this in a later
  5975. version
  5976.  
  5977. Literature
  5978. **********
  5979.  
  5980.    * [Addison Wesley] RKM Libraries 2.04,CATS
  5981.  
  5982.    * [Addison Wesley] RKM Devices 2.04,CATS
  5983.  
  5984.    * [Addison Wesley] RKM Autodocs\&Includes 2.04,CATS
  5985.  
  5986.    * [Addison Wesley] RKM Hardware 2.04,CATS
  5987.  
  5988.    * [Addison Wesley] RKM Styleguide,CATS
  5989.  
  5990.    * [Addison Wesley] RKM Libraries 1.1,CATS
  5991.  
  5992.    * [Addison Wesley] RKM Intuition 1.1,CATS
  5993.  
  5994.    * [Addison Wesley] RKM Exec 1.1,CATS
  5995.  
  5996.    * [Addison Wesley] RKM Hardware 1.1,CATS
  5997.  
  5998.    * [Edotronik] Kommentiertes Rom-Listing 1,Dr. Ruprecht
  5999.  
  6000.    * [Edotronik] Kommentiertes Rom-Listing 2,Dr. Ruprecht
  6001.  
  6002.    * [Edotronik] Kommentiertes Rom-Listing 3,Dr. Ruprecht
  6003.  
  6004.    * [Ralph Babel] Guru Book,Selbstvertrieb
  6005.  
  6006. Software
  6007. ********
  6008.  
  6009.    For the development of Barfly the following programs were used:
  6010.  
  6011.    * [CATS] Developer CD V2.0
  6012.  
  6013.    * [B.Hawes] WShell V2.0
  6014.  
  6015.    * [M.Sinz] Enforcer
  6016.  
  6017.    * [R.Schmidt] CyberGuard
  6018.  
  6019.    * [C.Scheppner] Mungwall
  6020.  
  6021.    * [SAS Institute] SAS/C
  6022.  
  6023.    * [GNU] GCC
  6024.  
  6025.    * [ASDG] CED
  6026.  
  6027.    * [Georg Hessmann] PasTex
  6028.  
  6029.    * [Stefan Stuntz] MFR 2.0d
  6030.  
  6031.    * [Mathias Scheler] Filer
  6032.  
  6033.    * [Matthew Dillon] DNet
  6034.  
  6035.    * [Brian Cerveny] Grapevine
  6036.  
  6037.    * [Ezy] MLink
  6038.  
  6039. Assembler Addressmodes
  6040. **********************
  6041.  
  6042.      +--------------+------------------------+
  6043.      |   Notation   | Description            |
  6044.      +--------------+------------------------+
  6045.      +--------------+------------------------+
  6046.      |      EA      | Effective Address      |
  6047.      |      Dn      | D0...D7                |
  6048.      |      An      | A0...A7                |
  6049.      |      Xn      | D0...D7, A0...A7       |
  6050.      |      .b      | Operand Width  8Bit    |
  6051.      |      .w      | Operand Width 16Bit    |
  6052.      |      .l      | Operand Width 32Bit    |
  6053.      |     size     | w,l                    |
  6054.      |     Size     | b,w,l                  |
  6055.      |     Scale    | 1,2,4 or 8             |
  6056.      | Xn.size*Scale| 68000-10 only Scale 1. |
  6057.      +---------------------------------------+
  6058.  
  6059. `Data register direct'
  6060.      Syntax: Dn
  6061.  
  6062. `Address register direct'
  6063.      Syntax: An
  6064.  
  6065. `Address register indirect'
  6066.      Syntax: (An)
  6067.  
  6068. `Address register indirect with postincrement'
  6069.      Syntax: (An)+
  6070.  
  6071. `Address register indirect with predecrement'
  6072.      Syntax: -(An)
  6073.  
  6074. `Address register indirect with offset'
  6075.      Syntax: bd.w(An)
  6076.  
  6077. `Address register indirect with index and offset'
  6078.      Syntax: bd.b(An,Xn{.Size*Scale})
  6079.  
  6080. `Address register indirect with index and offset'
  6081.      Syntax: (bd,An,Xn{.Size*Scale})
  6082.  
  6083. `Address register indirect with index and offset'
  6084.      Syntax: (bd.b,An,Xn{.Size*Scale})
  6085.  
  6086. `Address register indirect with index and base displacement'
  6087.      Syntax: ({bd.size{,An{,Xn{.Size{*Scale}}}}})
  6088.  
  6089. `Indirect Memory Addressierung mit postindex'
  6090.      Syntax: ({[{bd.size{,An}}]}{Xn{.Size{*Scale}{,od.size}}})
  6091.  
  6092. `Indirect Memory Addressierung mit preindex'
  6093.      Syntax: ({[{bd.size{,An}}{,Xn{.Size{*Scale}]}{,od.size}}})
  6094.  
  6095. `PC Indirect'
  6096.      Syntax: (PC)
  6097.  
  6098. `PC Indirect with offset'
  6099.      Syntax: bd.w(PC)
  6100.  
  6101. `PC Indirect with index and offset'
  6102.      Syntax: bd.b(PC,Xn{.Size*Scale})
  6103.  
  6104. `PC Indirect with index and offset'
  6105.      Syntax: bd.b(ZPC,Xn{.Size*Scale})
  6106.  
  6107. `PC Indirect with index and base displacement'
  6108.      Syntax: ({bd.size{,PC{,Xn{.Size{*Scale}}}}})
  6109.  
  6110. `PC Indirect with index and base displacement'
  6111.      Syntax: ({bd.size{,ZPC{,Xn{.Size{*Scale}}}}})
  6112.  
  6113. `PC Indirect memory Addressing with post-index'
  6114.      Syntax: ({[{bd.size{,PC}}]}{,Xn{.Size{*Scale}{,od.size}}})
  6115.  
  6116. `PC Indirect memory Addressing with post-index'
  6117.      Syntax: ({[{bd.size{,ZPC}}]}{,Xn{.Size{*Scale}{,od.size}}})
  6118.  
  6119. `PC Indirect memory Addressing with pre-index'
  6120.      Syntax: ({[{bd.size{,PC}}{,Xn{.Size{*Scale}]}{,od.size}}})
  6121.  
  6122. `PC Indirect memory addressing with pre-index'
  6123.      Syntax: ({[{bd.size{,ZPC}}{,Xn{.Size{*Scale}]}{,od.size}}})
  6124.  
  6125. `Absolut short'
  6126.      Syntax: bd.w
  6127.  
  6128. `Absolut long'
  6129.      Syntax: bd[.l]
  6130.  
  6131. `Immediate Data'
  6132.      Syntax: #xxx
  6133.  
  6134. Addressmode Examples
  6135. ====================
  6136.  
  6137.    To avoid some problems here are some small examples how addressmode
  6138. have to build up.
  6139.  
  6140.  
  6141.      x=$40
  6142.      y=$400
  6143.        move.b (x,A0,D2.W),D0
  6144.        move.b x(A0,D2.W),D0
  6145.      
  6146.      ;Both lines are correct
  6147.      ;(x,a0,d2.w) is optimized internal to (x,a0,d2.w).
  6148.      ;For more information please check the chapter about
  6149.      ;Optimizing Direct Addressmodes.
  6150.      
  6151.        move.b (y,A0,D2.W),D0
  6152.        move.b y(A0,D2.W),D0
  6153.      
  6154.      ;Now you get 2 errors, because y is not an 8bit word.
  6155.      ;These 2 lines shows the correct version.
  6156.      
  6157.        move.b (y.w,A0,D2.W),D0
  6158.        move.b (y.w,A0,D2.W),D0
  6159.      
  6160.      ;or
  6161.      
  6162.        move.b (y.l,A0,D2.W),D0
  6163.        move.b (y.l,A0,D2.W),D0
  6164.  
  6165. 680xx Opcode Overview
  6166. *********************
  6167.  
  6168.      +----------+---------+-------------------------------------------+
  6169.      |  Opcode  |  Size   | 68000 68010 68020 68030 68040 68060 6888x |
  6170.      +----------+---------+-------------------------------------------+
  6171.      +----------+---------+-------------------------------------------+
  6172.      | abcd     | b       |   x     x     x     x     x     x         |
  6173.      | add      | b,w,l   |   x     x     x     x     x     x         |
  6174.      | addq     | b,w,l   |   x     x     x     x     x     x         |
  6175.      | adda     | w,l     |   x     x     x     x     x     x         |
  6176.      | addi     | b,w,l   |   x     x     x     x     x     x         |
  6177.      | addx     | b,w,l   |   x     x     x     x     x     x         |
  6178.      | and      | b,w,l   |   x     x     x     x     x     x         |
  6179.      | andi     | b,w,l   |   x     x     x     x     x     x         |
  6180.      | asr      | b,w,l   |   x     x     x     x     x     x         |
  6181.      | asl      | b,w,l   |   x     x     x     x     x     x         |
  6182.      | bcc      | b,w,l   |   x     x     x     x     x     x         |
  6183.      | bchg     | b,l     |   x     x     x     x     x     x         |
  6184.      | bclr     | b,l     |   x     x     x     x     x     x         |
  6185.      | bfchg    | unsized |               x     x     x     x         |
  6186.      | bfclr    | unsized |               x     x     x     x         |
  6187.      | bfext    | unsized |               x     x     x     x         |
  6188.      | bfffo    | unsized |               x     x     x     x         |
  6189.      | bfins    | unsized |               x     x     x     x         |
  6190.      | bfset    | unsized |               x     x     x     x         |
  6191.      | bftst    | unsized |               x     x     x     x         |
  6192.      | bkpt     | unsized |         x     x     x     x     x         |
  6193.      | bset     | b,l     |   x     x     x     x     x     x         |
  6194.      | btst     | b,l     |   x     x     x     x     x     x         |
  6195.      | callm    | unsized |               x                           |
  6196.      | cas      | b,w,l   |   x     x     x     x     x     x,2       |
  6197.      | cas2     | b,w,l   |   x     x     x     x     x     x,2       |
  6198.      | chk      | b,w,l   |   x     x     x     x     x     x         |
  6199.      | chk2     | b,w,l   |               x     x     x     2         |
  6200.      | cinv¹    | unsized |                           x     x         |
  6201.      | clr      | b,w,l   |   x     x     x     x     x     x         |
  6202.      | cmp      | b,w,l   |   x     x     x     x     x     x         |
  6203.      | cmpa     | w,l     |   x     x     x     x     x     x         |
  6204.      | cmpi     | b,w,l   |   x     x     x     x     x     x         |
  6205.      | cmpm     | b,w,l   |   x     x     x     x     x     x         |
  6206.      | cmp2     | b,w,l   |               x     x     x     2         |
  6207.      | cpush¹   | unsized |                           x     x         |
  6208.      | dbcc     | w       |   x     x     x     x     x     x         |
  6209.      | divs     | w,l     |   x     x     x     x     x     x,2       |
  6210.      | divsl    | l       |               x     x     x     x         |
  6211.      | divu     | w,l     |   x     x     x     x     x     x,2       |
  6212.      | divul    | l       |               x     x     x     x         |
  6213.      | eor      | b,w,l   |   x     x     x     x     x     x         |
  6214.      | eori     | b,w,l   |   x     x     x     x     x     x         |
  6215.      | eori/ccr | b       |   x     x     x     x     x     x         |
  6216.      | eori/sr¹ | w       |   x     x     x     x     x     x         |
  6217.      | exg      | l       |   x     x     x     x     x     x         |
  6218.      | ext      | w,l     |   x     x     x     x     x     x         |
  6219.      | extb     | l       |               x     x     x     x         |
  6220.      | fabs     |         |                           x     x     x   |
  6221.      | fsabs    |         |                           x     x         |
  6222.      | fdabs    |         |                           x     x         |
  6223.      | facos    |         |                           2     2     x   |
  6224.      | fadd     |         |                           x     x     x   |
  6225.      | fsadd    |         |                           x     x         |
  6226.      | fdadd    |         |                           x     x         |
  6227.      | fasin    |         |                           2     2     x   |
  6228.      | fatan    |         |                           2     2     x   |
  6229.      | fatanh   |         |                           2     2     x   |
  6230.      | fbcc     |         |                           x     x     x   |
  6231.      | fcmp     |         |                           x     x     x   |
  6232.      | fcos     |         |                           2     2     x   |
  6233.      | fcosh    |         |                           2     2     x   |
  6234.      | fdbcc    |         |                           x     2     x   |
  6235.      | fdiv     |         |                           x     x     x   |
  6236.      | fsdiv    |         |                           x     x         |
  6237.      | fddiv    |         |                           x     x         |
  6238.      | fetox    |         |                           2     2     x   |
  6239.      | fetoxm1  |         |                           2     2     x   |
  6240.      | fgetexp  |         |                           2     2     x   |
  6241.      | fgetman  |         |                           2     2     x   |
  6242.      | fint     |         |                           2     x     x   |
  6243.      | fintrz   |         |                           2     x     x   |
  6244.      | flogn    |         |                           2     2     x   |
  6245.      | flognp1  |         |                           2     2     x   |
  6246.      | flog2    |         |                           2     2     x   |
  6247.      | flog10   |         |                           2     2     x   |
  6248.      | fmod     |         |                           2     2     x   |
  6249.      | fmove    |         |                           x     x     x   |
  6250.      | fsmove   |         |                           x     x         |
  6251.      | fdmove   |         |                           x     x         |
  6252.      | fmovecr  |         |                           2     2     x   |
  6253.      | fmovem   |         |                           x     x,2   x   |
  6254.      | fmul     |         |                           x     x     x   |
  6255.      | fsmul    |         |                           x     x         |
  6256.      | fdmul    |         |                           x     x         |
  6257.      | fneg     |         |                           x     x     x   |
  6258.      | fsneg    |         |                           x     x         |
  6259.      | fdneg    |         |                           x     x         |
  6260.      | fnop     |         |                           x     x     x   |
  6261.      | frem     |         |                           2     2     x   |
  6262.      | frestore¹|         |                           x     x     x   |
  6263.      | fscc     |         |                           2     2     x   |
  6264.      | fsub     |         |                           x     x     x   |
  6265.      | fssub    |         |                           x     x         |
  6266.      | fdsub    |         |                           x     x         |
  6267.      | fsave¹   |         |                           x     x     x   |
  6268.      | fscale   |         |                           2     2     x   |
  6269.      | fsglmul  |         |                           2     2     x   |
  6270.      | fsgldiv  |         |                           2     2     x   |
  6271.      | fsin     |         |                           2     2     x   |
  6272.      | fsinh    |         |                           2     2     x   |
  6273.      | fsincos  |         |                           2     2     x   |
  6274.      | fsqrt    |         |                           x     x     x   |
  6275.      | fssqrt   |         |                           x     x         |
  6276.      | fdsqrt   |         |                           x     x         |
  6277.      | ftan     |         |                           2     2     x   |
  6278.      | ftanh    |         |                           2     2     x   |
  6279.      | ftentox  |         |                           2     2     x   |
  6280.      | ftrap    |         |                           x     2     x   |
  6281.      | ftst     |         |                           x     x     x   |
  6282.      | ftwotox  |         |                           2     2     x   |
  6283.      | illegal  | unsized |   x     x     x     x     x     x         |
  6284.      | jmp      | unsized |   x     x     x     x     x     x         |
  6285.      | jsr      | unsized |   x     x     x     x     x     x         |
  6286.      | lea      | l       |   x     x     x     x     x     x         |
  6287.      | link     | w,l     |   x     x     x     x     x     x         |
  6288.      | lpstop   |         |                                 x         |
  6289.      | lsl      | b,w,l   |   x     x     x     x     x     x         |
  6290.      | lsr      | b,w,l   |   x     x     x     x     x     x         |
  6291.      | move     | b,w,l   |   x     x     x     x     x     x         |
  6292.      | movea    | w,l     |   x     x     x     x     x     x         |
  6293.      | moveq    | l       |   x     x     x     x     x     x         |
  6294.      | movec¹   | l       |         x     x     x     x     x         |
  6295.      | movem    | w,l     |   x     x     x     x     x     x         |
  6296.      | movep    | w,l     |   x     x     x     x     x               |
  6297.      | moves¹   | b,w,l   |         x     x     x     x     x         |
  6298.      | move16   |         |                           x     x         |
  6299.      | muls     | w,l     |   x     x     x     x     x     x         |
  6300.      | mulu     | w,l     |   x     x     x     x     x     x         |
  6301.      | nbcd     | b       |   x     x     x     x     x     x         |
  6302.      | neg      | b,w,l   |   x     x     x     x     x     x         |
  6303.      | negx     | b,w,l   |   x     x     x     x     x     x         |
  6304.      | nop      | unsized |   x     x     x     x     x     x         |
  6305.      | not      | b,w,l   |   x     x     x     x     x     x         |
  6306.      | or       | b,w,l   |   x     x     x     x     x     x         |
  6307.      | ori      | b,w,l   |   x     x     x     x     x     x         |
  6308.      | pack     | unsized |               x     x     x     x         |
  6309.      | pea      | l       |   x     x     x     x     x     x         |
  6310.      | pflush¹  | unsized |                     x     x     x         |
  6311.      | pflusha¹ | unsized |                     x                     |
  6312.      | plpa¹    | unsized |                                 x         |
  6313.      | pload¹   | unsized |                     x                     |
  6314.      | pmove¹   | w,l,q   |                     x                     |
  6315.      | ptest¹   | unsized |                     x     x               |
  6316.      | reset¹   | unsized |   x     x     x     x     x     x         |
  6317.      | rol      | b,w,l   |   x     x     x     x     x     x         |
  6318.      | ror      | b,w,l   |   x     x     x     x     x     x         |
  6319.      | roxl     | b,w,l   |   x     x     x     x     x     x         |
  6320.      | roxr     | b,w,l   |   x     x     x     x     x     x         |
  6321.      | rtd      | unsized |         x     x     x     x     x         |
  6322.      | rte¹     | unsized |   x     x     x     x     x     x         |
  6323.      | rtr      | unsized |   x     x     x     x     x     x         |
  6324.      | rts      | unsized |   x     x     x     x     x     x         |
  6325.      | rtm      | unsized |               x                           |
  6326.      | sbcd     | b       |   x     x     x     x     x     x         |
  6327.      | scc      | b       |   x     x     x     x     x     x         |
  6328.      | stop¹    | unsized |   x     x     x     x     x     x         |
  6329.      | sub      | b,w,l   |   x     x     x     x     x     x         |
  6330.      | subq     | b,w,l   |   x     x     x     x     x     x         |
  6331.      | suba     | w,l     |   x     x     x     x     x     x         |
  6332.      | subi     | b,w,l   |   x     x     x     x     x     x         |
  6333.      | subx     | b,w,l   |   x     x     x     x     x     x         |
  6334.      | swap     | w       |   x     x     x     x     x     x         |
  6335.      | tas      | b       |   x     x     x     x     x     x         |
  6336.      | trap     | unsized |   x     x     x     x     x     x         |
  6337.      | trapcc   | ? ,w,l  |               x     x     x     x         |
  6338.      | trapv    | unsized |   x     x     x     x     x     x         |
  6339.      | tst      | b,w,l   |   x     x     x     x     x     x         |
  6340.      | unlk     | unsized |   x     x     x     x     x     x         |
  6341.      | unpk     | unsized |               x     x     x     x         |
  6342.      +----------+---------+-------------------------------------------+
  6343.      
  6344.      ¹ Supervisor instruction
  6345.      2 These are software-supported instructions on the 68040 and 68060
  6346.  
  6347.