On 12 Apr 2012 09:48:17 -0700, in bit.listserv.ibm-main you wrote: >Now that you mention it, I remember that the C/C++ compiler has a architecture >option to control the instructions generated. I should have known that the >PL/X compiler would too. I didn't know that they both share the same back-end. >I wish that the COBOL compiler did. I am constantly amazed at the amount of >code generate by a simpe: > > ADD +1 TO WS-INTEGER. > >when WS-INTEGER is defined as PIC S9(9) BINARY or NATIVE. COBOL seems to have >an inordinate love for PACKED-DECIMAL. Someone once said it was due to ANSI >standards compliance. Might be worth it, in CPU saved, to license the C >compiler and port the OpenCOBOL > >Unless I somehow have the wrong compile parameters. Make sure you have TRUNC(OPT) implied or expressed in the compile parameters. If you have TRUNC(STD) then WS-INTEGER must be in the range -999,999,999 through +999,999,999. TRUN(BIN) always has been fiasco.
Clark Morris ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN

