home *** CD-ROM | disk | FTP | other *** search
/ Piper's Pit BBS/FTP: ibm 0010 - 0019 / ibm0010-0019 / ibm0010.tar / ibm0010 / QC25-01.ZIP / README.DOC < prev    next >
Encoding:
Text File  |  1990-04-04  |  20.3 KB  |  508 lines

  1.                               README.DOC File
  2.                     
  3.                            Release Notes for the
  4.    Microsoft(R) QuickC(R) Compiler with QuickAssembler, Version 2.51
  5.  
  6.           (C) Copyright Microsoft Corporation, 1989-1990
  7.  
  8. This document contains release notes for Version 2.51 of the Microsoft
  9. QuickC Compiler with QuickAssembler. It includes information on both C and 
  10. assembly language. The Contents section below lists the documentation for 
  11. C and assembly language affected by the release notes. In all cases, the 
  12. information in this document supersedes the information in the manuals.
  13. However, Microsoft revises its documentation at the time of reprinting;
  14. the manuals may already include some of this information.
  15.  
  16. Note: If you're reading this from within on-line help, but would prefer to
  17. print it out by loading README.DOC into a word processor, you can find the
  18. file in the executable files directory (the default is \QC25\BIN).
  19.  
  20. The other documentation files are \SAMPLES\QASAMPLES.DOC, which explains
  21. the assembly-language example programs in the SAMPLES directory; and
  22. SAMPLES.DOC, which explains the C-language example programs in the same
  23. directory.
  24.  
  25. (COMPAQ is a registered trademark of Compaq Computer Corporation.)
  26. (Intel is a registered trademark of Intel Corporation.)
  27. (Novell is a registered trademark of Novell, Inc.)
  28.  
  29.  
  30. ===============================< Contents >================================
  31.  
  32.  
  33. This document has five parts:
  34.  
  35.           Part           Notes
  36.           ----           ----------------------------------------------
  37.             1            Notes on "Up and Running"
  38.             2            Notes on "C for Yourself"
  39.             3            Notes on "QuickC Tool Kit"
  40.             4            Notes on "QuickAssembler Programmer's Guide"
  41.             5            Additional Notes on QuickC with QuickAssembler
  42.  
  43.  
  44.  
  45. ===================< Part 1: Notes on "Up and Running" >===================
  46.  
  47.  
  48. Page  Note
  49. ----  ----
  50.  
  51. Inside Front Cover
  52.       Brief Guide to Keystrokes
  53. ---   -------------------------
  54.       The chart on the inside front cover says the ESC key "stops the
  55.       compiler and linker from continuing."  ESC stops the compiler but NOT
  56.       the linker.  Press CTRL+BREAK to stop both the compiler and linker.
  57.  
  58.       If you are using the debugger and running a program that expects
  59.       keyboard input, pressing either CTRL+C or CTRL+BREAK and then ENTER
  60.       will allow you to exit.
  61.  
  62.   6   Running SETUP
  63. ---   -------------
  64.       If you already have QuickC installed, SETUP will overwrite the
  65.       existing QC.INI file that contains the current compiler options,
  66.       etc. set in the environment. If you wish to save those settings,
  67.       rename this file before running SETUP.
  68.  
  69.  19   Using QuickC
  70. ---   ------------
  71.       If you own a COMPAQ(R) SLT/286, and the LCD display goes
  72.       blank when exiting from QuickC back to DOS, you should
  73.       run the program DAC_ON.COM before loading QuickC. To obtain a
  74.       copy of DAC_ON.COM, contact your authorized COMPAQ Computer
  75.       Dealer.
  76.  
  77.  42   The Debugger
  78. ---   ------------
  79.       The Quickwatch command does not display complete information
  80.       for assembler structures. Only the first member of a structure
  81.       is shown.
  82.  
  83.       You may see the message "currently running program terminated"
  84.       while debugging.
  85.       
  86.       This may happen if your program is linked with a user-created
  87.       library module that contains debugging information, and for
  88.       which the source files are present. In such a case, single-
  89.       stepping into a function contained in the library will cause
  90.       the debugger to terminate the current program and attempt to
  91.       compile the source files for the library module into an
  92.       executable program.
  93.  
  94.       You can avoid this problem by setting your program list to
  95.       contain only the name of the source file of your program.
  96.  
  97. (miscellaneous)
  98.  
  99.       Accessing Memory at 0xFFFF
  100.       --------------------------
  101.       Due to a problem with the Intel(R) processor, any attempt to
  102.       access a word value at memory location 0xFFFF may cause the
  103.       system to hang. The most likely way for this to happen is from
  104.       within the QuickC debugger, if you use the WO (display word) or
  105.       DW (display double word) operators to examine a register 
  106.       containing 0xFFFF. Any C or assembly-language program trying
  107.       to access that location may also cause the system to hang.
  108.  
  109.       Incompatibility with Novell(R) Netware
  110.       --------------------------------------
  111.       If you have a peripheral (such as a mouse) that uses IRQ 3, and
  112.       your system is part of a network using Novell Netware version
  113.       2.15 or lower, your system may hang when you load the QuickC
  114.       environment. As a temporary solution, reset your peripheral to
  115.       use another interrupt. For more information, contact your Novell
  116.       Netware dealer.
  117.  
  118.  
  119.  
  120. ===================< Part 2: Notes on "C for Yourself" >===================
  121.  
  122.  
  123. Page  Note
  124. ----  ----
  125.  
  126.  53   Type Qualifiers
  127. ---   ---------------
  128.       The fourth paragraph in this section is incorrect. A long double
  129.       value is the same size as a double. It contains 8 bytes, not 10. It
  130.       expresses a floating-point number with at least 15 digits of
  131.       precision, not 19. Table 4.1 on page 49 should also be corrected.
  132.  
  133. 164   Declaring a Pointer with the Wrong Type
  134. ---   ---------------------------------------
  135.       In the first program listing on the page, the line
  136.  
  137.            ptr = val;      /* Error! */
  138.  
  139.       should read
  140.  
  141.            ptr = &val;     /* Error! */
  142.  
  143. 215   Table 11.4   Standard vs. Low-Level
  144. ---   -----------------------------------
  145.       The headings across the top of the table should read 
  146.  
  147.          Function     Parameters        Returns        Error Condition
  148.  
  149. 298   Vector-Mapped Fonts
  150. ---   -------------------
  151.       Add this note to the description of vector mapping:
  152.  
  153.       If a vector-mapped font is selected in graphics mode, any function
  154.       affecting "_moveto" or "_lineto" will also affect the font
  155.       ("_setlinestyle" and so on) when "_outgtext" is called.
  156.  
  157. 304   Example Program Using Fonts
  158. ---   ---------------------------
  159.       The line reading
  160.  
  161.            if( !_setfont( list ) )
  162.  
  163.       should read
  164.  
  165.            if( _setfont( list ) >= 0 )
  166.  
  167. 309   Limits on _asm Identifiers
  168. ---   --------------------------
  169.       Never use reserved assembly words as labels, variable names, or other
  170.       identifiers within an _asm block. This includes words in the
  171.       following categories:
  172.  
  173.          - ASM Opcodes such as CMP or MOV
  174.          - Opcodes new to the 80186, 80286, and 80386 such as ARPLS or CLTS
  175.          - Reserved operand words such as WORD or PARA
  176.          - C library functions such as "exit" or "time"
  177.  
  178.       For example, the following code is not permitted:
  179.  
  180.            main()
  181.            {
  182.               int word;
  183.               _asm { mov WORD PTR [word],ax }
  184.            }
  185.  
  186.       The variable 'word' can be used in the C part of the program, but not
  187.       within the assembly block.
  188.  
  189.  366  Font Display Routines
  190.  ---  ---------------------
  191.       The return values for the _registerfonts and _setfont functions
  192.       should be
  193.  
  194.       _registerfonts
  195.  
  196.       Returns: the number of fonts registered, or a negative value if
  197.                failure
  198.  
  199.       _setfont
  200.  
  201.       Returns: a negative value if failure, zero or positive if
  202.                successful
  203.  
  204.  
  205.  
  206. ==================< Part 3: Notes on "QuickC Tool Kit" >===================
  207.  
  208.  
  209. Page  Note
  210. ----  ----
  211.  
  212.   94  /Gw, GW (Generate Code for Windows Function Calls)
  213.  ---  --------------------------------------------------
  214.       QuickC 2.5 supports development of programs for the next release
  215.       of Windows. If you wish to develop programs for Windows 2.03, you
  216.       must explicitly link your program with C51STUBS.LIB.
  217.  
  218.  130  /INC (Prepare for ILINK)
  219.  ---  ------------------------
  220.       By default, ILINK will call LINK if the incremental link fails.
  221.       To make ILINK call QLINK instead, use the /E option and an 
  222.       argument. For example:
  223.  
  224.            ILINK /E "QLINK @RESPONSE" PROGRAM.EXE
  225.  
  226.  259  Warning Message C4018
  227.  ---  ---------------------
  228.       The warning message below is new and should be added to page 259:
  229.  
  230.            C4018   'operator': signed/unsigned mismatch
  231.  
  232.       An expression involving the specified operator had inconsistent
  233.       integer types. The two integer expressions used in the comparison
  234.       operation are not of the same signed or unsigned type.
  235.  
  236. (miscellaneous)
  237.  
  238.       Makefile Compatibility with QuickC 2.0
  239.       --------------------------------------
  240.       The name of the linker supplied with QuickC has been changed
  241.       from LINK to QLINK. Any makefile used with QuickC 2.0 that
  242.       specify the LINK command should be changed accordingly.
  243.  
  244.       Makefile Compatibility with Programmer's WorkBench
  245.       --------------------------------------------------
  246.       The makefiles generated by QuickC are not fully readable by 
  247.       Microsoft Programmer's WorkBench (PWB) included with Microsoft's
  248.       Professional Development Systems. PWB is unable to read the
  249.       linker options specified in QuickC makefiles, so you will have to 
  250.       re-specify those options using PWB's menus. QuickC cannot read
  251.       makefiles generated by PWB.
  252.  
  253.  
  254.  
  255. ========< Part 4: Notes on "QuickAssembler Programmer's Guide" >===========
  256.  
  257.  
  258. Page  Note
  259. ----  ----
  260.  
  261.  xi   Running SETUP Before Using Help
  262. ---   -------------------------------
  263.       Before using the Quick Advisor, make sure you run the SETUP
  264.       program. This program combines files on different disks to build
  265.       QA.HLP, which contains help on assembly language as well as DOS
  266.       and BIOS interrupt functions. 
  267.  
  268.  xi   Expanding Environment Space
  269. ---   ---------------------------
  270.  
  271.       QuickAssembler for QuickC makes use of certain environment
  272.       variables, such as HELPFILES. However, these variables are stored
  273.       in an area of memory called the "environment space." You may need
  274.       to expand this memory to use the new environment variables
  275.       successfully.
  276.  
  277.       If you run DOS 3.2 or later, you can set the environment space
  278.       with the DOS SHELL command. For example, the following command
  279.       sets the environment size at 3000 bytes when placed in CONFIG.SYS:
  280.  
  281.            SHELL=COMMAND.COM /E:3000 /p
  282.  
  283.       Consult your DOS manual for more information.
  284.  
  285.  xi   Temporary Files and the TMP Environment Variable
  286. ---   ------------------------------------------------
  287.       If you do not have a TMP environment variable set, the linker
  288.       prints the following message when it creates a temporary file:
  289.  
  290.            temporary file <filename> created
  291.  
  292.       To avoid getting this message, set the TMP environment variable to
  293.       the name of a drive and directory. This drive should have some free
  294.       space. For example, the following command line sets C:\TEMP as the
  295.       directory where the linker places temporary files:
  296.  
  297.            SET TMP=C:\TEMP
  298.  
  299.       For convenience, place this command (or a similar one) in your
  300.       AUTOEXEC.BAT file to execute it automatically.
  301.  
  302.   6   Terminating the Program with .EXIT
  303. ---   ----------------------------------
  304.       When you use the .STARTUP directive, the recommended method for
  305.       terminating the program is to use the .EXIT directive. With
  306.       stand-alone assembly programs, you must explicitly terminate
  307.       or the processor will execute meaningless instructions beyond the
  308.       end of the program.
  309.  
  310.       The .EXIT directive has the following syntax:
  311.  
  312.            .EXIT [exitcode]
  313.  
  314.       in which exitcode is an optional register, memory location, or
  315.       constant that contains a value to return to DOS. This value must
  316.       not be larger than one byte.
  317.  
  318.       When you use this directive, the assembler generates instructions
  319.       that call DOS function 4CH (Exit with Return Code). You can use
  320.       another method to terminate the program if you wish. The assembler
  321.       generates an advisory warning if you use .STARTUP without .EXIT.
  322.  
  323.       The .EXIT directive requires that .MODEL was previously used.
  324.  
  325.       Within the environment, the assembler generates an advisory
  326.       warning message if you use .STARTUP without using .EXIT. Outside
  327.       the environment, the assembler does not generate this message.
  328.  
  329.   7   Effect of ILINK on Building a Program
  330. ---   -------------------------------------
  331.       By default, the QuickC environment invokes ILINK to link programs.
  332.       ILINK, in turn, requires that a program have a default data
  333.       segment (it may be empty). To meet this requirement, you can do
  334.       any of three alternatives:
  335.  
  336.       1. Declare a data segment with .DATA if using simplified segment
  337.          directives.
  338.  
  339.       2. Declare a group named DGROUP.
  340.  
  341.       3. Turn Incremental Link off in the Linker Flags dialog box.
  342.  
  343.       The use of ILINK imposes some other requirements on assembly-
  344.       language programs:
  345.  
  346.       1. You cannot have a segment with the AT attribute.
  347.  
  348.       2. Avoid depending on distances between segments being fixed. Some
  349.          programs calculate the distance between two segments and then
  350.          use this value elsewhere. When ILINK is in use, segment-address
  351.          arithmetic is unpredictable.
  352.  
  353.       3. The DUP operator cannot have a program address as an operand.
  354.          For example, the following statement is compatible with ILINK:
  355.  
  356.       myarr     DW     10 DUP (5)
  357.  
  358.       However, the next statement is not compatible with ILINK, even
  359.       though it is supported by the assembler:
  360.  
  361.       myarr     DW     10 DUP (myproc)
  362.  
  363.   7   Searching for Include Files
  364. ---   ---------------------------
  365.       When building and running a program, note that the assembler looks
  366.       for include files in the following order:
  367.  
  368.       1. The directory in which the current source file is located
  369.       2. Directories specified with the /I command-line option
  370.       3. The current directory (as recognized by the environment)
  371.       4. Directories specified in the INCLUDE environment variable
  372.  
  373.   9   Assembling from the Command Line
  374. ---   --------------------------------
  375.       QCL does not report some warning messages reported inside the QuickC
  376.       environment. QCL does not warn you if you use .STARTUP without .EXIT.
  377.  
  378.  14   Specifying Debug Expressions
  379. ---   ----------------------------
  380.       The QuickC environment now supports an optional display-format
  381.       character for examining arrays. You can add a suffix to any
  382.       expression for the Watch window as follows:
  383.  
  384.            expression,nf
  385.  
  386.       in which n is a number and f is a format specifier (such as i, x,
  387.       d, or a). Both are optional. The use of n displays the expression
  388.       as if it were an array. If the expression is already an array,
  389.       then the use of n displays the array as if it were an array of a
  390.       higher dimension. The assembler does not type any symbol as an
  391.       array. Thus, the use of n with a variable declared in assembly
  392.       always displays the variable as an array of one dimension.
  393.  
  394.       The optional f display-format specifier only affects the format
  395.       in which each member of the array is displayed.
  396.  
  397.       The Watch window determines the type of array from the expression
  398.       or from BY, WO, or DW if used. If WVAR is declared as type WORD
  399.       (or "int" in C), then WVAR,5x displays the first five words at the
  400.       address of WVAR. The "x" specifies hex format. BY WVAR,5x displays
  401.       the first five bytes at the address of WVAR. Each byte is
  402.       displayed as if it were a hexadecimal word-sized value.
  403.  
  404.  56   The PROC Directive
  405. ---   ------------------
  406.       The PROC directive sets the BP register to point to a procedure's
  407.       frame, but only if you use a parameter list or the LOCAL directive.
  408.  
  409.  82   Using Full Segment Definitions
  410. ---   ------------------------------
  411.       The program example on this page should declare class name 'CODE'
  412.       for the segment definition:
  413.  
  414.       _TEXT     SEGMENT  'CODE'
  415.  
  416.       The class name 'CODE' is necessary if you want to debug the
  417.       module. The assembler issues a warning message if you assemble a
  418.       code segment without this class name. If you use simplified
  419.       segment directives, the code segments automatically have this
  420.       class name.
  421.  
  422. 109   Defining Segment Combine Types
  423. ---   ------------------------------
  424.       The combine type describes how the linker combines segments, but
  425.       does not affect the assembler itself. Within any given module, the
  426.       assembler concatenates segments with the same name. Thus, segments
  427.       with the COMMON attribute are overlapped only if they are in
  428.       different modules.
  429.  
  430. 383   Assembling with Two Passes
  431. ---   --------------------------
  432.       In addition to the options listed in Appendix B, QCL supports the
  433.       /P2 option, which specifies two-pass assembly. The /P1 option
  434.       specifies one-pass assembly and is now the default. Two-pass
  435.       assembly is slower than one-pass assembly, but enables some
  436.       language-specific features (such as IF1 and IF2) that rely on two
  437.       passes.
  438.  
  439. 383   Removing Copyright Message
  440. ---   --------------------------
  441.       In addition to the options listed in Appendix B, QCL supports the
  442.       /nologo option, which prevents QCL from printing the product name
  443.       and copyright information. QCL also prints a warning message when a
  444.       nonstandard version of DOS is detected. The /nologo option prevents
  445.       this message from being printed.
  446.  
  447. 386   Using /AT to Generate a .COM File
  448. ---   ---------------------------------
  449.       If you use QCL to generate a .COM file but do not use /AT, the
  450.       linker may produce a file with an .EXE extension. This file is
  451.       really in .COM format. It should be renamed immediately. You can
  452.       prevent this situation by using the /AT option, or by using the
  453.       /Fe option to explicitly give the name of the output file. For
  454.       example, the following command line produces a file with a .EXE
  455.       extension:
  456.  
  457.            QCL sample.asm /link /TINY
  458.  
  459.       However, the following command lines each produce a file with a
  460.       .COM extension:
  461.  
  462.            QCL /AT /Ln sample.asm /link /TINY
  463.            QCL /Fe sample.com sample.asm /link /TINY
  464.  
  465. 392   Line-Number Index in Listing File
  466. ---   ---------------------------------
  467.       The line-number index generated by /Sq (and generated by default
  468.       within the environment) lists correspondences between source-file
  469.       lines and listing-file lines. This index, placed at the end of the
  470.       listing file, is read and interpreted by the QuickC environment.
  471.       You should avoid writing utilities that read this index. The
  472.       format of the line-number index is subject to change without
  473.       notice.
  474.  
  475.  
  476.  
  477. ========< Part 5: Additional Notes for QuickC with QuickAssembler>=========
  478.  
  479.  
  480. Source of DOS and BIOS Function Information in Help
  481. ---------------------------------------------------
  482. On-line help includes information on IBM ROM BIOS services as well as
  483. MS-DOS service calls. The information on these topics is adapted from the
  484. books "IBM ROM BIOS" and "MS-DOS Functions" by Ray Duncan. Both books are
  485. published by Microsoft Press and are part of the Programmer's Quick
  486. Reference Series.
  487.  
  488. Math Coprocessor Instructions in .ASM Programs
  489. ----------------------------------------------
  490. If you do not have a math coprocessor chip, you must use the /FPi option
  491. when assembling code for emulated floating-point instructions. If the
  492. switch is omitted, your assembly-language programs may hang your machine.
  493.  
  494. Setting Breakpoints on Assembly Procedures and Labels
  495. -----------------------------------------------------
  496. Version 2.51 of QuickAssembler now supports setting breakpoints on labels.
  497. Because assembly procedures are treated as labels, a dialog box verifies if
  498. you want to set a breakpoint at a procedure label.  Additional information
  499. can be found in the on-line help. 
  500.  
  501. ILINK and Tiny Model
  502. --------------------
  503. When switching to tiny model from another model, or from another model to
  504. tiny model, turn off the incremental link option the first time you build
  505. after switching models.  Alternatively, you can delete to .SYM and .ILK
  506. files to force a full link.  ILINK should always be disabled
  507. when creating tiny model (.COM) programs.
  508.