We're moving away from distributing generated files.
From-SVN: r15446
This commit is contained in:
parent
a3ee32467c
commit
f2d19dd24a
751
gcc/f/g77.info
751
gcc/f/g77.info
@ -1,751 +0,0 @@
|
||||
This is Info file g77.info, produced by Makeinfo version 1.68 from the
|
||||
input file g77.texi.
|
||||
|
||||
This file explains how to use the GNU Fortran system.
|
||||
|
||||
Published by the Free Software Foundation 59 Temple Place - Suite 330
|
||||
Boston, MA 02111-1307 USA
|
||||
|
||||
Copyright (C) 1995-1997 Free Software Foundation, Inc.
|
||||
|
||||
Permission is granted to make and distribute verbatim copies of this
|
||||
manual provided the copyright notice and this permission notice are
|
||||
preserved on all copies.
|
||||
|
||||
Permission is granted to copy and distribute modified versions of
|
||||
this manual under the conditions for verbatim copying, provided also
|
||||
that the sections entitled "GNU General Public License," "Funding for
|
||||
Free Software," and "Protect Your Freedom--Fight `Look And Feel'" are
|
||||
included exactly as in the original, and provided that the entire
|
||||
resulting derived work is distributed under the terms of a permission
|
||||
notice identical to this one.
|
||||
|
||||
Permission is granted to copy and distribute translations of this
|
||||
manual into another language, under the above conditions for modified
|
||||
versions, except that the sections entitled "GNU General Public
|
||||
License," "Funding for Free Software," and "Protect Your Freedom--Fight
|
||||
`Look And Feel'", and this permission notice, may be included in
|
||||
translations approved by the Free Software Foundation instead of in the
|
||||
original English.
|
||||
|
||||
Contributed by James Craig Burley (<burley@gnu.ai.mit.edu>).
|
||||
Inspired by a first pass at translating `g77-0.5.16/f/DOC' that was
|
||||
contributed to Craig by David Ronis (<ronis@onsager.chem.mcgill.ca>).
|
||||
|
||||
INFO-DIR-SECTION Fortran Programming
|
||||
START-INFO-DIR-ENTRY
|
||||
* g77: (g77). The GNU Fortran compilation system.
|
||||
END-INFO-DIR-ENTRY
|
||||
|
||||
|
||||
Indirect:
|
||||
g77.info-1: 1697
|
||||
g77.info-2: 51504
|
||||
g77.info-3: 86652
|
||||
g77.info-4: 102421
|
||||
g77.info-5: 148200
|
||||
g77.info-6: 198176
|
||||
g77.info-7: 240263
|
||||
g77.info-8: 290181
|
||||
g77.info-9: 339800
|
||||
g77.info-10: 389391
|
||||
g77.info-11: 437993
|
||||
g77.info-12: 487886
|
||||
g77.info-13: 537704
|
||||
g77.info-14: 586061
|
||||
g77.info-15: 635100
|
||||
g77.info-16: 684261
|
||||
g77.info-17: 734128
|
||||
g77.info-18: 773211
|
||||
g77.info-19: 822559
|
||||
g77.info-20: 833284
|
||||
|
||||
Tag Table:
|
||||
(Indirect)
|
||||
Node: Top1697
|
||||
Node: Copying3654
|
||||
Node: Contributors22836
|
||||
Node: Funding25868
|
||||
Node: Funding GNU Fortran28371
|
||||
Node: Look and Feel31054
|
||||
Node: Getting Started31556
|
||||
Node: What is GNU Fortran?33874
|
||||
Node: G77 and GCC43439
|
||||
Node: Invoking G7744790
|
||||
Node: Option Summary46941
|
||||
Node: Overall Options51504
|
||||
Node: Shorthand Options57592
|
||||
Node: Fortran Dialect Options60070
|
||||
Node: Warning Options70755
|
||||
Node: Debugging Options79641
|
||||
Node: Optimize Options80714
|
||||
Node: Preprocessor Options84159
|
||||
Node: Directory Options85340
|
||||
Node: Code Gen Options86652
|
||||
Node: Environment Variables101963
|
||||
Node: News102421
|
||||
Node: Changes148200
|
||||
Node: Language162250
|
||||
Node: Direction of Language Development164190
|
||||
Node: Standard Support170429
|
||||
Node: No Passing External Assumed-length171150
|
||||
Node: No Passing Dummy Assumed-length171627
|
||||
Node: No Pathological Implied-DO172142
|
||||
Node: No Useless Implied-DO172829
|
||||
Node: Conformance173560
|
||||
Node: Notation Used175583
|
||||
Node: Terms and Concepts179788
|
||||
Node: Syntactic Items180300
|
||||
Node: Statements Comments Lines180982
|
||||
Node: Scope of Names and Labels182847
|
||||
Node: Characters Lines Sequence183277
|
||||
Node: Character Set183858
|
||||
Node: Lines184859
|
||||
Node: Continuation Line187335
|
||||
Node: Statements188290
|
||||
Node: Statement Labels189246
|
||||
Node: Order189938
|
||||
Node: INCLUDE190823
|
||||
Node: Data Types and Constants193566
|
||||
Node: Types197087
|
||||
Node: Double Notation198176
|
||||
Node: Star Notation199248
|
||||
Node: Kind Notation202193
|
||||
Node: Constants210613
|
||||
Node: Integer Type211925
|
||||
Node: Character Type212523
|
||||
Node: Expressions213287
|
||||
Node: %LOC()213703
|
||||
Node: Specification Statements216404
|
||||
Node: NAMELIST216861
|
||||
Node: DOUBLE COMPLEX217143
|
||||
Node: Control Statements217397
|
||||
Node: DO WHILE217889
|
||||
Node: END DO218115
|
||||
Node: Construct Names219122
|
||||
Node: CYCLE and EXIT219862
|
||||
Node: Functions and Subroutines222626
|
||||
Node: %VAL()223272
|
||||
Node: %REF()224636
|
||||
Node: %DESCR()226464
|
||||
Node: Generics and Specifics228597
|
||||
Node: REAL() and AIMAG() of Complex235792
|
||||
Node: CMPLX() of DOUBLE PRECISION237625
|
||||
Node: MIL-STD 1753239351
|
||||
Node: f77/f2c Intrinsics239693
|
||||
Node: Table of Intrinsic Functions240263
|
||||
Node: Abort Intrinsic256970
|
||||
Node: Abs Intrinsic257234
|
||||
Node: Access Intrinsic258102
|
||||
Node: AChar Intrinsic258938
|
||||
Node: ACos Intrinsic259460
|
||||
Node: AdjustL Intrinsic259921
|
||||
Node: AdjustR Intrinsic260246
|
||||
Node: AImag Intrinsic260572
|
||||
Node: AInt Intrinsic261377
|
||||
Node: Alarm Intrinsic262005
|
||||
Node: All Intrinsic262841
|
||||
Node: Allocated Intrinsic263153
|
||||
Node: ALog Intrinsic263482
|
||||
Node: ALog10 Intrinsic263872
|
||||
Node: AMax0 Intrinsic264270
|
||||
Node: AMax1 Intrinsic264755
|
||||
Node: AMin0 Intrinsic265208
|
||||
Node: AMin1 Intrinsic265692
|
||||
Node: AMod Intrinsic266144
|
||||
Node: And Intrinsic266570
|
||||
Node: ANInt Intrinsic267076
|
||||
Node: Any Intrinsic267840
|
||||
Node: ASin Intrinsic268147
|
||||
Node: Associated Intrinsic268605
|
||||
Node: ATan Intrinsic268939
|
||||
Node: ATan2 Intrinsic269405
|
||||
Node: BesJ0 Intrinsic269956
|
||||
Node: BesJ1 Intrinsic270417
|
||||
Node: BesJN Intrinsic270878
|
||||
Node: BesY0 Intrinsic271377
|
||||
Node: BesY1 Intrinsic271839
|
||||
Node: BesYN Intrinsic272301
|
||||
Node: Bit_Size Intrinsic272804
|
||||
Node: BTest Intrinsic273463
|
||||
Node: CAbs Intrinsic274183
|
||||
Node: CCos Intrinsic274570
|
||||
Node: Ceiling Intrinsic274962
|
||||
Node: CExp Intrinsic275284
|
||||
Node: Char Intrinsic275676
|
||||
Node: ChDir Intrinsic (subroutine)276930
|
||||
Node: ChMod Intrinsic (subroutine)277739
|
||||
Node: CLog Intrinsic279008
|
||||
Node: Cmplx Intrinsic279412
|
||||
Node: Complex Intrinsic280213
|
||||
Node: Conjg Intrinsic281659
|
||||
Node: Cos Intrinsic282083
|
||||
Node: CosH Intrinsic282546
|
||||
Node: Count Intrinsic282921
|
||||
Node: Cpu_Time Intrinsic283239
|
||||
Node: CShift Intrinsic283702
|
||||
Node: CSin Intrinsic284024
|
||||
Node: CSqRt Intrinsic284416
|
||||
Node: CTime Intrinsic (subroutine)284826
|
||||
Node: CTime Intrinsic (function)285581
|
||||
Node: DAbs Intrinsic286215
|
||||
Node: DACos Intrinsic286611
|
||||
Node: DASin Intrinsic287002
|
||||
Node: DATan Intrinsic287394
|
||||
Node: DATan2 Intrinsic287787
|
||||
Node: Date_and_Time Intrinsic288242
|
||||
Node: DbesJ0 Intrinsic288592
|
||||
Node: DbesJ1 Intrinsic288985
|
||||
Node: DbesJN Intrinsic289371
|
||||
Node: DbesY0 Intrinsic289795
|
||||
Node: DbesY1 Intrinsic290181
|
||||
Node: DbesYN Intrinsic290567
|
||||
Node: Dble Intrinsic290989
|
||||
Node: DCos Intrinsic291695
|
||||
Node: DCosH Intrinsic292079
|
||||
Node: DDiM Intrinsic292469
|
||||
Node: DErF Intrinsic292901
|
||||
Node: DErFC Intrinsic293270
|
||||
Node: DExp Intrinsic293645
|
||||
Node: Digits Intrinsic294031
|
||||
Node: DiM Intrinsic294348
|
||||
Node: DInt Intrinsic294847
|
||||
Node: DLog Intrinsic295231
|
||||
Node: DLog10 Intrinsic295616
|
||||
Node: DMax1 Intrinsic296014
|
||||
Node: DMin1 Intrinsic296468
|
||||
Node: DMod Intrinsic296920
|
||||
Node: DNInt Intrinsic297348
|
||||
Node: Dot_Product Intrinsic297747
|
||||
Node: DProd Intrinsic298087
|
||||
Node: DSign Intrinsic298469
|
||||
Node: DSin Intrinsic298908
|
||||
Node: DSinH Intrinsic299293
|
||||
Node: DSqRt Intrinsic299684
|
||||
Node: DTan Intrinsic300075
|
||||
Node: DTanH Intrinsic300460
|
||||
Node: Dtime Intrinsic (subroutine)300864
|
||||
Node: EOShift Intrinsic301799
|
||||
Node: Epsilon Intrinsic302138
|
||||
Node: ErF Intrinsic302462
|
||||
Node: ErFC Intrinsic302868
|
||||
Node: ETime Intrinsic (subroutine)303426
|
||||
Node: ETime Intrinsic (function)304253
|
||||
Node: Exit Intrinsic304957
|
||||
Node: Exp Intrinsic305434
|
||||
Node: Exponent Intrinsic305896
|
||||
Node: Fdate Intrinsic (subroutine)306235
|
||||
Node: Fdate Intrinsic (function)306923
|
||||
Node: FGet Intrinsic (subroutine)307473
|
||||
Node: FGetC Intrinsic (subroutine)308310
|
||||
Node: Float Intrinsic309187
|
||||
Node: Floor Intrinsic309587
|
||||
Node: Flush Intrinsic309903
|
||||
Node: FNum Intrinsic310482
|
||||
Node: FPut Intrinsic (subroutine)310930
|
||||
Node: FPutC Intrinsic (subroutine)311727
|
||||
Node: Fraction Intrinsic312574
|
||||
Node: FSeek Intrinsic312915
|
||||
Node: FStat Intrinsic (subroutine)313640
|
||||
Node: FStat Intrinsic (function)315109
|
||||
Node: FTell Intrinsic (subroutine)316343
|
||||
Node: FTell Intrinsic (function)317016
|
||||
Node: GError Intrinsic317533
|
||||
Node: GetArg Intrinsic317907
|
||||
Node: GetCWD Intrinsic (subroutine)318543
|
||||
Node: GetCWD Intrinsic (function)319399
|
||||
Node: GetEnv Intrinsic320019
|
||||
Node: GetGId Intrinsic320606
|
||||
Node: GetLog Intrinsic320912
|
||||
Node: GetPId Intrinsic321236
|
||||
Node: GetUId Intrinsic321544
|
||||
Node: GMTime Intrinsic321849
|
||||
Node: HostNm Intrinsic (subroutine)322857
|
||||
Node: HostNm Intrinsic (function)323729
|
||||
Node: Huge Intrinsic324354
|
||||
Node: IAbs Intrinsic324677
|
||||
Node: IAChar Intrinsic325068
|
||||
Node: IAnd Intrinsic325608
|
||||
Node: IArgC Intrinsic326096
|
||||
Node: IBClr Intrinsic326472
|
||||
Node: IBits Intrinsic326982
|
||||
Node: IBSet Intrinsic327696
|
||||
Node: IChar Intrinsic328197
|
||||
Node: IDate Intrinsic (UNIX)329416
|
||||
Node: IDiM Intrinsic329997
|
||||
Node: IDInt Intrinsic330446
|
||||
Node: IDNInt Intrinsic330839
|
||||
Node: IEOr Intrinsic331238
|
||||
Node: IErrNo Intrinsic331736
|
||||
Node: IFix Intrinsic332063
|
||||
Node: Imag Intrinsic332451
|
||||
Node: ImagPart Intrinsic333456
|
||||
Node: Index Intrinsic334482
|
||||
Node: Int Intrinsic335035
|
||||
Node: Int2 Intrinsic335750
|
||||
Node: Int8 Intrinsic336438
|
||||
Node: IOr Intrinsic337126
|
||||
Node: IRand Intrinsic337606
|
||||
Node: IsaTty Intrinsic338526
|
||||
Node: IShft Intrinsic338950
|
||||
Node: IShftC Intrinsic339800
|
||||
Node: ISign Intrinsic340728
|
||||
Node: ITime Intrinsic341178
|
||||
Node: Kill Intrinsic (subroutine)341580
|
||||
Node: Kind Intrinsic342417
|
||||
Node: LBound Intrinsic342742
|
||||
Node: Len Intrinsic343059
|
||||
Node: Len_Trim Intrinsic343695
|
||||
Node: LGe Intrinsic344107
|
||||
Node: LGt Intrinsic345520
|
||||
Node: Link Intrinsic (subroutine)346426
|
||||
Node: LLe Intrinsic347391
|
||||
Node: LLt Intrinsic348297
|
||||
Node: LnBlnk Intrinsic349192
|
||||
Node: Loc Intrinsic349595
|
||||
Node: Log Intrinsic350026
|
||||
Node: Log10 Intrinsic350606
|
||||
Node: Logical Intrinsic351179
|
||||
Node: Long Intrinsic351502
|
||||
Node: LShift Intrinsic352026
|
||||
Node: LStat Intrinsic (subroutine)353062
|
||||
Node: LStat Intrinsic (function)354818
|
||||
Node: LTime Intrinsic356325
|
||||
Node: MatMul Intrinsic357329
|
||||
Node: Max Intrinsic357647
|
||||
Node: Max0 Intrinsic358198
|
||||
Node: Max1 Intrinsic358649
|
||||
Node: MaxExponent Intrinsic359133
|
||||
Node: MaxLoc Intrinsic359473
|
||||
Node: MaxVal Intrinsic359800
|
||||
Node: MClock Intrinsic360122
|
||||
Node: MClock8 Intrinsic360849
|
||||
Node: Merge Intrinsic361567
|
||||
Node: Min Intrinsic361883
|
||||
Node: Min0 Intrinsic362434
|
||||
Node: Min1 Intrinsic362885
|
||||
Node: MinExponent Intrinsic363369
|
||||
Node: MinLoc Intrinsic363709
|
||||
Node: MinVal Intrinsic364036
|
||||
Node: Mod Intrinsic364355
|
||||
Node: Modulo Intrinsic364878
|
||||
Node: MvBits Intrinsic365197
|
||||
Node: Nearest Intrinsic366063
|
||||
Node: NInt Intrinsic366387
|
||||
Node: Not Intrinsic367225
|
||||
Node: Or Intrinsic367620
|
||||
Node: Pack Intrinsic368118
|
||||
Node: PError Intrinsic368428
|
||||
Node: Precision Intrinsic368882
|
||||
Node: Present Intrinsic369217
|
||||
Node: Product Intrinsic369547
|
||||
Node: Radix Intrinsic369873
|
||||
Node: Rand Intrinsic370190
|
||||
Node: Random_Number Intrinsic371077
|
||||
Node: Random_Seed Intrinsic371430
|
||||
Node: Range Intrinsic371778
|
||||
Node: Real Intrinsic372099
|
||||
Node: RealPart Intrinsic373105
|
||||
Node: Rename Intrinsic (subroutine)374138
|
||||
Node: Repeat Intrinsic375110
|
||||
Node: Reshape Intrinsic375446
|
||||
Node: RRSpacing Intrinsic375775
|
||||
Node: RShift Intrinsic376110
|
||||
Node: Scale Intrinsic377108
|
||||
Node: Scan Intrinsic377424
|
||||
Node: Second Intrinsic (function)377748
|
||||
Node: Second Intrinsic (subroutine)378288
|
||||
Node: Selected_Int_Kind Intrinsic378934
|
||||
Node: Selected_Real_Kind Intrinsic379325
|
||||
Node: Set_Exponent Intrinsic379712
|
||||
Node: Shape Intrinsic380069
|
||||
Node: Short Intrinsic380392
|
||||
Node: Sign Intrinsic381088
|
||||
Node: Signal Intrinsic (subroutine)381688
|
||||
Node: Sin Intrinsic382987
|
||||
Node: SinH Intrinsic383462
|
||||
Node: Sleep Intrinsic383835
|
||||
Node: Sngl Intrinsic384177
|
||||
Node: Spacing Intrinsic384566
|
||||
Node: Spread Intrinsic384890
|
||||
Node: SqRt Intrinsic385211
|
||||
Node: SRand Intrinsic385815
|
||||
Node: Stat Intrinsic (subroutine)386192
|
||||
Node: Stat Intrinsic (function)387751
|
||||
Node: Sum Intrinsic389059
|
||||
Node: SymLnk Intrinsic (subroutine)389391
|
||||
Node: System Intrinsic (subroutine)390423
|
||||
Node: System_Clock Intrinsic391362
|
||||
Node: Tan Intrinsic392130
|
||||
Node: TanH Intrinsic392590
|
||||
Node: Time Intrinsic (UNIX)392972
|
||||
Node: Time8 Intrinsic393786
|
||||
Node: Tiny Intrinsic394499
|
||||
Node: Transfer Intrinsic394814
|
||||
Node: Transpose Intrinsic395145
|
||||
Node: Trim Intrinsic395479
|
||||
Node: TtyNam Intrinsic (subroutine)395809
|
||||
Node: TtyNam Intrinsic (function)396508
|
||||
Node: UBound Intrinsic397077
|
||||
Node: UMask Intrinsic (subroutine)397422
|
||||
Node: Unlink Intrinsic (subroutine)398119
|
||||
Node: Unpack Intrinsic399017
|
||||
Node: Verify Intrinsic399352
|
||||
Node: XOr Intrinsic399671
|
||||
Node: ZAbs Intrinsic400187
|
||||
Node: ZCos Intrinsic400556
|
||||
Node: ZExp Intrinsic400929
|
||||
Node: ZLog Intrinsic401302
|
||||
Node: ZSin Intrinsic401675
|
||||
Node: ZSqRt Intrinsic402049
|
||||
Node: Scope and Classes of Names402406
|
||||
Node: Underscores in Symbol Names402876
|
||||
Node: Other Dialects403123
|
||||
Node: Source Form404282
|
||||
Node: Carriage Returns405633
|
||||
Node: Tabs405962
|
||||
Node: Short Lines407671
|
||||
Node: Long Lines408645
|
||||
Node: Ampersands409256
|
||||
Node: Trailing Comment409510
|
||||
Node: Debug Line410286
|
||||
Node: Dollar Signs410955
|
||||
Node: Case Sensitivity411241
|
||||
Node: VXT Fortran419857
|
||||
Node: Double Quote Meaning421040
|
||||
Node: Exclamation Point421968
|
||||
Node: Fortran 90423011
|
||||
Node: Pedantic Compilation424063
|
||||
Node: Distensions428027
|
||||
Node: Ugly Implicit Argument Conversion429558
|
||||
Node: Ugly Assumed-Size Arrays430172
|
||||
Node: Ugly Complex Part Extraction431893
|
||||
Node: Ugly Null Arguments433515
|
||||
Node: Ugly Conversion of Initializers435120
|
||||
Node: Ugly Integer Conversions436885
|
||||
Node: Ugly Assigned Labels437993
|
||||
Node: Compiler439924
|
||||
Node: Compiler Limits440530
|
||||
Node: Compiler Types441413
|
||||
Node: Compiler Constants446112
|
||||
Node: Compiler Intrinsics446971
|
||||
Node: Intrinsic Groups447898
|
||||
Node: Other Intrinsics451339
|
||||
Node: ACosD Intrinsic458937
|
||||
Node: AIMax0 Intrinsic459218
|
||||
Node: AIMin0 Intrinsic459527
|
||||
Node: AJMax0 Intrinsic459837
|
||||
Node: AJMin0 Intrinsic460147
|
||||
Node: ASinD Intrinsic460456
|
||||
Node: ATan2D Intrinsic460762
|
||||
Node: ATanD Intrinsic461070
|
||||
Node: BITest Intrinsic461376
|
||||
Node: BJTest Intrinsic461685
|
||||
Node: CDAbs Intrinsic461994
|
||||
Node: CDCos Intrinsic462367
|
||||
Node: CDExp Intrinsic462742
|
||||
Node: CDLog Intrinsic463117
|
||||
Node: CDSin Intrinsic463492
|
||||
Node: CDSqRt Intrinsic463868
|
||||
Node: ChDir Intrinsic (function)464261
|
||||
Node: ChMod Intrinsic (function)464895
|
||||
Node: CosD Intrinsic466007
|
||||
Node: DACosD Intrinsic466319
|
||||
Node: DASinD Intrinsic466627
|
||||
Node: DATan2D Intrinsic466938
|
||||
Node: DATanD Intrinsic467252
|
||||
Node: Date Intrinsic467561
|
||||
Node: DbleQ Intrinsic468190
|
||||
Node: DCmplx Intrinsic468494
|
||||
Node: DConjg Intrinsic470125
|
||||
Node: DCosD Intrinsic470510
|
||||
Node: DFloat Intrinsic470816
|
||||
Node: DFlotI Intrinsic471188
|
||||
Node: DFlotJ Intrinsic471498
|
||||
Node: DImag Intrinsic471807
|
||||
Node: DReal Intrinsic472184
|
||||
Node: DSinD Intrinsic473331
|
||||
Node: DTanD Intrinsic473635
|
||||
Node: Dtime Intrinsic (function)473950
|
||||
Node: FGet Intrinsic (function)474844
|
||||
Node: FGetC Intrinsic (function)475617
|
||||
Node: FloatI Intrinsic476433
|
||||
Node: FloatJ Intrinsic476753
|
||||
Node: FPut Intrinsic (function)477072
|
||||
Node: FPutC Intrinsic (function)477808
|
||||
Node: IDate Intrinsic (VXT)478601
|
||||
Node: IIAbs Intrinsic479320
|
||||
Node: IIAnd Intrinsic479630
|
||||
Node: IIBClr Intrinsic479935
|
||||
Node: IIBits Intrinsic480244
|
||||
Node: IIBSet Intrinsic480554
|
||||
Node: IIDiM Intrinsic480863
|
||||
Node: IIDInt Intrinsic481169
|
||||
Node: IIDNnt Intrinsic481478
|
||||
Node: IIEOr Intrinsic481787
|
||||
Node: IIFix Intrinsic482092
|
||||
Node: IInt Intrinsic482395
|
||||
Node: IIOr Intrinsic482694
|
||||
Node: IIQint Intrinsic482994
|
||||
Node: IIQNnt Intrinsic483302
|
||||
Node: IIShftC Intrinsic483613
|
||||
Node: IISign Intrinsic483927
|
||||
Node: IMax0 Intrinsic484237
|
||||
Node: IMax1 Intrinsic484542
|
||||
Node: IMin0 Intrinsic484846
|
||||
Node: IMin1 Intrinsic485150
|
||||
Node: IMod Intrinsic485453
|
||||
Node: INInt Intrinsic485753
|
||||
Node: INot Intrinsic486055
|
||||
Node: IZExt Intrinsic486355
|
||||
Node: JIAbs Intrinsic486658
|
||||
Node: JIAnd Intrinsic486962
|
||||
Node: JIBClr Intrinsic487267
|
||||
Node: JIBits Intrinsic487576
|
||||
Node: JIBSet Intrinsic487886
|
||||
Node: JIDiM Intrinsic488195
|
||||
Node: JIDInt Intrinsic488501
|
||||
Node: JIDNnt Intrinsic488810
|
||||
Node: JIEOr Intrinsic489119
|
||||
Node: JIFix Intrinsic489424
|
||||
Node: JInt Intrinsic489727
|
||||
Node: JIOr Intrinsic490026
|
||||
Node: JIQint Intrinsic490326
|
||||
Node: JIQNnt Intrinsic490634
|
||||
Node: JIShft Intrinsic490944
|
||||
Node: JIShftC Intrinsic491255
|
||||
Node: JISign Intrinsic491569
|
||||
Node: JMax0 Intrinsic491879
|
||||
Node: JMax1 Intrinsic492184
|
||||
Node: JMin0 Intrinsic492488
|
||||
Node: JMin1 Intrinsic492792
|
||||
Node: JMod Intrinsic493095
|
||||
Node: JNInt Intrinsic493395
|
||||
Node: JNot Intrinsic493697
|
||||
Node: JZExt Intrinsic493997
|
||||
Node: Kill Intrinsic (function)494310
|
||||
Node: Link Intrinsic (function)494992
|
||||
Node: QAbs Intrinsic495804
|
||||
Node: QACos Intrinsic496114
|
||||
Node: QACosD Intrinsic496418
|
||||
Node: QASin Intrinsic496726
|
||||
Node: QASinD Intrinsic497032
|
||||
Node: QATan Intrinsic497340
|
||||
Node: QATan2 Intrinsic497646
|
||||
Node: QATan2D Intrinsic497956
|
||||
Node: QATanD Intrinsic498270
|
||||
Node: QCos Intrinsic498579
|
||||
Node: QCosD Intrinsic498880
|
||||
Node: QCosH Intrinsic499183
|
||||
Node: QDiM Intrinsic499486
|
||||
Node: QExp Intrinsic499785
|
||||
Node: QExt Intrinsic500083
|
||||
Node: QExtD Intrinsic500382
|
||||
Node: QFloat Intrinsic500686
|
||||
Node: QInt Intrinsic500993
|
||||
Node: QLog Intrinsic501293
|
||||
Node: QLog10 Intrinsic501593
|
||||
Node: QMax1 Intrinsic501900
|
||||
Node: QMin1 Intrinsic502205
|
||||
Node: QMod Intrinsic502508
|
||||
Node: QNInt Intrinsic502808
|
||||
Node: QSin Intrinsic503110
|
||||
Node: QSinD Intrinsic503410
|
||||
Node: QSinH Intrinsic503713
|
||||
Node: QSqRt Intrinsic504017
|
||||
Node: QTan Intrinsic504320
|
||||
Node: QTanD Intrinsic504620
|
||||
Node: QTanH Intrinsic504923
|
||||
Node: Rename Intrinsic (function)505239
|
||||
Node: Secnds Intrinsic506044
|
||||
Node: Signal Intrinsic (function)506419
|
||||
Node: SinD Intrinsic507530
|
||||
Node: SnglQ Intrinsic507842
|
||||
Node: SymLnk Intrinsic (function)508157
|
||||
Node: System Intrinsic (function)509025
|
||||
Node: TanD Intrinsic510352
|
||||
Node: Time Intrinsic (VXT)510669
|
||||
Node: UMask Intrinsic (function)511200
|
||||
Node: Unlink Intrinsic (function)511808
|
||||
Node: ZExt Intrinsic512537
|
||||
Node: Other Compilers512825
|
||||
Node: Dropping f2c Compatibility515205
|
||||
Node: Compilers Other Than f2c518031
|
||||
Node: Other Languages519830
|
||||
Node: Interoperating with C and C++520082
|
||||
Node: C Interfacing Tools521115
|
||||
Node: C Access to Type Information522043
|
||||
Node: f2c Skeletons and Prototypes522730
|
||||
Node: C++ Considerations524428
|
||||
Node: Startup Code525083
|
||||
Node: Installation525994
|
||||
Node: Prerequisites527150
|
||||
Node: Problems Installing535614
|
||||
Node: General Problems536240
|
||||
Node: GNU C Required537003
|
||||
Node: Patching GNU CC Necessary537704
|
||||
Node: Building GNU CC Necessary538554
|
||||
Node: Missing strtoul538900
|
||||
Node: Object File Differences540314
|
||||
Node: Cleanup Kills Stage Directories541011
|
||||
Node: Missing gperf?541431
|
||||
Node: Cross-compiler Problems542819
|
||||
Node: Settings545024
|
||||
Node: Larger File Unit Numbers546102
|
||||
Node: Always Flush Output547685
|
||||
Node: Maximum Stackable Size549545
|
||||
Node: Floating-point Bit Patterns550401
|
||||
Node: Large Initialization551142
|
||||
Node: Alpha Problems Fixed552731
|
||||
Node: Quick Start553618
|
||||
Node: Complete Installation564031
|
||||
Node: Unpacking564611
|
||||
Node: Merging Distributions567700
|
||||
Node: Installing f77573149
|
||||
Node: Installing f2c574494
|
||||
Node: Patching GNU Fortran577419
|
||||
Node: Where to Install578937
|
||||
Node: Configuring gcc582282
|
||||
Node: Building gcc584054
|
||||
Node: Bootstrap Build586061
|
||||
Node: Straight Build587807
|
||||
Node: Pre-installation Checks589196
|
||||
Node: Installation of Binaries592622
|
||||
Node: Updating Documentation593983
|
||||
Node: Missing bison?594837
|
||||
Node: Missing makeinfo?596183
|
||||
Node: Distributing Binaries596708
|
||||
Node: Debugging and Interfacing602653
|
||||
Node: Main Program Unit605337
|
||||
Node: Procedures607834
|
||||
Node: Functions610495
|
||||
Node: Names612113
|
||||
Node: Common Blocks615254
|
||||
Node: Local Equivalence Areas617287
|
||||
Node: Complex Variables619974
|
||||
Node: Arrays621304
|
||||
Node: Adjustable Arrays624638
|
||||
Node: Alternate Entry Points627497
|
||||
Node: Alternate Returns634199
|
||||
Node: Assigned Statement Labels635100
|
||||
Node: Run-time Library Errors636945
|
||||
Node: Collected Fortran Wisdom638897
|
||||
Node: Advantages Over f2c640333
|
||||
Node: Language Extensions641242
|
||||
Node: Compiler Options641749
|
||||
Node: Compiler Speed642201
|
||||
Node: Program Speed642911
|
||||
Node: Ease of Debugging644496
|
||||
Node: Character and Hollerith Constants646926
|
||||
Node: Block Data and Libraries647720
|
||||
Node: Loops651044
|
||||
Node: Working Programs656260
|
||||
Node: Not My Type656940
|
||||
Node: Variables Assumed To Be Zero658871
|
||||
Node: Variables Assumed To Be Saved659925
|
||||
Node: Unwanted Variables661295
|
||||
Node: Unused Arguments662175
|
||||
Node: Surprising Interpretations of Code662638
|
||||
Node: Aliasing Assumed To Work663484
|
||||
Node: Output Assumed To Flush669400
|
||||
Node: Large File Unit Numbers670806
|
||||
Node: Overly Convenient Options672088
|
||||
Node: Faster Programs675698
|
||||
Node: Aligned Data676144
|
||||
Node: Prefer Automatic Uninitialized Variables679988
|
||||
Node: Avoid f2c Compatibility681354
|
||||
Node: Use Submodel Options681822
|
||||
Node: Trouble682645
|
||||
Node: But-bugs684261
|
||||
Node: Signal 11 and Friends686035
|
||||
Node: Cannot Link Fortran Programs688114
|
||||
Node: Large Common Blocks689397
|
||||
Node: Debugger Problems689823
|
||||
Node: NeXTStep Problems690345
|
||||
Node: Stack Overflow692167
|
||||
Node: Nothing Happens694180
|
||||
Node: Strange Behavior at Run Time695794
|
||||
Node: Floating-point Errors698087
|
||||
Node: Actual Bugs702664
|
||||
Node: Missing Features713415
|
||||
Node: Better Source Model715132
|
||||
Node: Fortran 90 Support716901
|
||||
Node: Intrinsics in PARAMETER Statements718002
|
||||
Node: SELECT CASE on CHARACTER Type718888
|
||||
Node: RECURSIVE Keyword719186
|
||||
Node: Increasing Precision/Range719613
|
||||
Node: Popular Non-standard Types721150
|
||||
Node: Full Support for Compiler Types721567
|
||||
Node: Array Bounds Expressions722239
|
||||
Node: POINTER Statements722686
|
||||
Node: Sensible Non-standard Constructs723569
|
||||
Node: FLUSH Statement725894
|
||||
Node: Expressions in FORMAT Statements726280
|
||||
Node: Explicit Assembler Code727459
|
||||
Node: Q Edit Descriptor727748
|
||||
Node: Old-style PARAMETER Statements728252
|
||||
Node: TYPE and ACCEPT I/O Statements728986
|
||||
Node: STRUCTURE UNION RECORD MAP729552
|
||||
Node: OPEN CLOSE and INQUIRE Keywords730038
|
||||
Node: ENCODE and DECODE730470
|
||||
Node: Suppressing Space Padding731571
|
||||
Node: Fortran Preprocessor732797
|
||||
Node: Bit Operations on Floating-point Data733370
|
||||
Node: POSIX Standard733884
|
||||
Node: Floating-point Exception Handling734128
|
||||
Node: Nonportable Conversions735170
|
||||
Node: Large Automatic Arrays735706
|
||||
Node: Support for Threads736113
|
||||
Node: Gracefully Handle Sensible Bad Code736538
|
||||
Node: Non-standard Conversions737293
|
||||
Node: Non-standard Intrinsics737636
|
||||
Node: Modifying DO Variable738052
|
||||
Node: Better Pedantic Compilation738728
|
||||
Node: Warn About Implicit Conversions739356
|
||||
Node: Invalid Use of Hollerith Constant739943
|
||||
Node: Dummy Array Without Dimensioning Dummy740486
|
||||
Node: Invalid FORMAT Specifiers741399
|
||||
Node: Ambiguous Dialects741800
|
||||
Node: Unused Labels742211
|
||||
Node: Informational Messages742433
|
||||
Node: Uninitialized Variables at Run Time742836
|
||||
Node: Bounds Checking at Run Time743443
|
||||
Node: Labels Visible to Debugger743891
|
||||
Node: Disappointments744297
|
||||
Node: Mangling of Names744935
|
||||
Node: Multiple Definitions of External Names745785
|
||||
Node: Limitation on Implicit Declarations747148
|
||||
Node: Non-bugs747432
|
||||
Node: Backslash in Constants748557
|
||||
Node: Initializing Before Specifying753446
|
||||
Node: Context-Sensitive Intrinsicness754588
|
||||
Node: Context-Sensitive Constants756484
|
||||
Node: Equivalence Versus Equality759441
|
||||
Node: Order of Side Effects761951
|
||||
Node: Warnings and Errors763679
|
||||
Node: Open Questions765363
|
||||
Node: Bugs766511
|
||||
Node: Bug Criteria768016
|
||||
Node: Bug Lists772439
|
||||
Node: Bug Reporting773211
|
||||
Node: Sending Patches786658
|
||||
Node: Service792142
|
||||
Node: Adding Options792610
|
||||
Node: Projects796659
|
||||
Node: Efficiency797504
|
||||
Node: Better Optimization800401
|
||||
Node: Simplify Porting803771
|
||||
Node: More Extensions805526
|
||||
Node: Machine Model808727
|
||||
Node: Internals Documentation810013
|
||||
Node: Internals Improvements810327
|
||||
Node: Better Diagnostics813871
|
||||
Node: Diagnostics814788
|
||||
Node: CMPAMBIG816085
|
||||
Node: EXPIMP822559
|
||||
Node: INTGLOB823795
|
||||
Node: LEX826039
|
||||
Node: GLOBALS831431
|
||||
Node: Index833284
|
||||
|
||||
End Tag Table
|
1073
gcc/f/g77.info-1
1073
gcc/f/g77.info-1
File diff suppressed because it is too large
Load Diff
1462
gcc/f/g77.info-10
1462
gcc/f/g77.info-10
File diff suppressed because it is too large
Load Diff
1608
gcc/f/g77.info-11
1608
gcc/f/g77.info-11
File diff suppressed because it is too large
Load Diff
1443
gcc/f/g77.info-12
1443
gcc/f/g77.info-12
File diff suppressed because it is too large
Load Diff
1144
gcc/f/g77.info-13
1144
gcc/f/g77.info-13
File diff suppressed because it is too large
Load Diff
1145
gcc/f/g77.info-14
1145
gcc/f/g77.info-14
File diff suppressed because it is too large
Load Diff
1175
gcc/f/g77.info-15
1175
gcc/f/g77.info-15
File diff suppressed because it is too large
Load Diff
1210
gcc/f/g77.info-16
1210
gcc/f/g77.info-16
File diff suppressed because it is too large
Load Diff
@ -1,968 +0,0 @@
|
||||
This is Info file g77.info, produced by Makeinfo version 1.68 from the
|
||||
input file g77.texi.
|
||||
|
||||
This file explains how to use the GNU Fortran system.
|
||||
|
||||
Published by the Free Software Foundation 59 Temple Place - Suite 330
|
||||
Boston, MA 02111-1307 USA
|
||||
|
||||
Copyright (C) 1995-1997 Free Software Foundation, Inc.
|
||||
|
||||
Permission is granted to make and distribute verbatim copies of this
|
||||
manual provided the copyright notice and this permission notice are
|
||||
preserved on all copies.
|
||||
|
||||
Permission is granted to copy and distribute modified versions of
|
||||
this manual under the conditions for verbatim copying, provided also
|
||||
that the sections entitled "GNU General Public License," "Funding for
|
||||
Free Software," and "Protect Your Freedom--Fight `Look And Feel'" are
|
||||
included exactly as in the original, and provided that the entire
|
||||
resulting derived work is distributed under the terms of a permission
|
||||
notice identical to this one.
|
||||
|
||||
Permission is granted to copy and distribute translations of this
|
||||
manual into another language, under the above conditions for modified
|
||||
versions, except that the sections entitled "GNU General Public
|
||||
License," "Funding for Free Software," and "Protect Your Freedom--Fight
|
||||
`Look And Feel'", and this permission notice, may be included in
|
||||
translations approved by the Free Software Foundation instead of in the
|
||||
original English.
|
||||
|
||||
Contributed by James Craig Burley (<burley@gnu.ai.mit.edu>).
|
||||
Inspired by a first pass at translating `g77-0.5.16/f/DOC' that was
|
||||
contributed to Craig by David Ronis (<ronis@onsager.chem.mcgill.ca>).
|
||||
|
||||
INFO-DIR-SECTION Fortran Programming
|
||||
START-INFO-DIR-ENTRY
|
||||
* g77: (g77). The GNU Fortran compilation system.
|
||||
END-INFO-DIR-ENTRY
|
||||
|
||||
|
||||
File: g77.info, Node: Floating-point Exception Handling, Next: Nonportable Conversions, Prev: POSIX Standard, Up: Missing Features
|
||||
|
||||
Floating-point Exception Handling
|
||||
---------------------------------
|
||||
|
||||
The `gcc' backend and, consequently, `g77', currently provides no
|
||||
control over whether or not floating-point exceptions are trapped or
|
||||
ignored. (Ignoring them typically results in NaN values being
|
||||
propagated in systems that conform to IEEE 754.) The behaviour is
|
||||
inherited from the system-dependent startup code.
|
||||
|
||||
Most systems provide some C-callable mechanism to change this; this
|
||||
can be invoked at startup using `gcc''s `constructor' attribute. For
|
||||
example, just compiling and linking the following C code with your
|
||||
program will turn on exception trapping for the "common" exceptions on
|
||||
an x86-based GNU system:
|
||||
|
||||
#include <fpu_control.h>
|
||||
void __attribute__ ((constructor))
|
||||
trapfpe () {
|
||||
(void) __setfpucw (_FPU_DEFAULT &
|
||||
~(_FPU_MASK_IM | _FPU_MASK_ZM | _FPU_MASK_OM));
|
||||
}
|
||||
|
||||
|
||||
File: g77.info, Node: Nonportable Conversions, Next: Large Automatic Arrays, Prev: Floating-point Exception Handling, Up: Missing Features
|
||||
|
||||
Nonportable Conversions
|
||||
-----------------------
|
||||
|
||||
`g77' doesn't accept some particularly nonportable, silent data-type
|
||||
conversions such as `LOGICAL' to `REAL' (as in `A=.FALSE.', where `A'
|
||||
is type `REAL'), that other compilers might quietly accept.
|
||||
|
||||
Some of these conversions are accepted by `g77' when the `-fugly'
|
||||
option is specified. Perhaps it should accept more or all of them.
|
||||
|
||||
|
||||
File: g77.info, Node: Large Automatic Arrays, Next: Support for Threads, Prev: Nonportable Conversions, Up: Missing Features
|
||||
|
||||
Large Automatic Arrays
|
||||
----------------------
|
||||
|
||||
Currently, automatic arrays always are allocated on the stack. For
|
||||
situations where the stack cannot be made large enough, `g77' should
|
||||
offer a compiler option that specifies allocation of automatic arrays
|
||||
in heap storage.
|
||||
|
||||
|
||||
File: g77.info, Node: Support for Threads, Next: Increasing Precision/Range, Prev: Large Automatic Arrays, Up: Missing Features
|
||||
|
||||
Support for Threads
|
||||
-------------------
|
||||
|
||||
Neither the code produced by `g77' nor the `libf2c' library are
|
||||
thread-safe, nor does `g77' have support for parallel processing (other
|
||||
than the instruction-level parallelism available on some processors).
|
||||
A package such as PVM might help here.
|
||||
|
||||
|
||||
File: g77.info, Node: Gracefully Handle Sensible Bad Code, Next: Non-standard Conversions, Prev: Increasing Precision/Range, Up: Missing Features
|
||||
|
||||
Gracefully Handle Sensible Bad Code
|
||||
-----------------------------------
|
||||
|
||||
`g77' generally should continue processing for warnings and
|
||||
recoverable (user) errors whenever possible--that is, it shouldn't
|
||||
gratuitously make bad or useless code.
|
||||
|
||||
For example:
|
||||
|
||||
INTRINSIC ZABS
|
||||
CALL FOO(ZABS)
|
||||
END
|
||||
|
||||
When compiling the above with `-ff2c-intrinsics-disable', `g77' should
|
||||
indeed complain about passing `ZABS', but it still should compile,
|
||||
instead of rejecting the entire `CALL' statement. (Some of this is
|
||||
related to improving the compiler internals to improve how statements
|
||||
are analyzed.)
|
||||
|
||||
|
||||
File: g77.info, Node: Non-standard Conversions, Next: Non-standard Intrinsics, Prev: Gracefully Handle Sensible Bad Code, Up: Missing Features
|
||||
|
||||
Non-standard Conversions
|
||||
------------------------
|
||||
|
||||
`-Wconversion' and related should flag places where non-standard
|
||||
conversions are found. Perhaps much of this would be part of `-Wugly*'.
|
||||
|
||||
|
||||
File: g77.info, Node: Non-standard Intrinsics, Next: Modifying DO Variable, Prev: Non-standard Conversions, Up: Missing Features
|
||||
|
||||
Non-standard Intrinsics
|
||||
-----------------------
|
||||
|
||||
`g77' needs a new option, like `-Wintrinsics', to warn about use of
|
||||
non-standard intrinsics without explicit `INTRINSIC' statements for
|
||||
them. This would help find code that might fail silently when ported
|
||||
to another compiler.
|
||||
|
||||
|
||||
File: g77.info, Node: Modifying DO Variable, Next: Better Pedantic Compilation, Prev: Non-standard Intrinsics, Up: Missing Features
|
||||
|
||||
Modifying `DO' Variable
|
||||
-----------------------
|
||||
|
||||
`g77' should warn about modifying `DO' variables via `EQUIVALENCE'.
|
||||
(The internal information gathered to produce this warning might also
|
||||
be useful in setting the internal "doiter" flag for a variable or even
|
||||
array reference within a loop, since that might produce faster code
|
||||
someday.)
|
||||
|
||||
For example, this code is invalid, so `g77' should warn about the
|
||||
invalid assignment to `NOTHER':
|
||||
|
||||
EQUIVALENCE (I, NOTHER)
|
||||
DO I = 1, 100
|
||||
IF (I.EQ. 10) NOTHER = 20
|
||||
END DO
|
||||
|
||||
|
||||
File: g77.info, Node: Better Pedantic Compilation, Next: Warn About Implicit Conversions, Prev: Modifying DO Variable, Up: Missing Features
|
||||
|
||||
Better Pedantic Compilation
|
||||
---------------------------
|
||||
|
||||
`g77' needs to support `-fpedantic' more thoroughly, and use it only
|
||||
to generate warnings instead of rejecting constructs outright. Have it
|
||||
warn: if a variable that dimensions an array is not a dummy or placed
|
||||
explicitly in `COMMON' (F77 does not allow it to be placed in `COMMON'
|
||||
via `EQUIVALENCE'); if specification statements follow
|
||||
statement-function-definition statements; about all sorts of syntactic
|
||||
extensions.
|
||||
|
||||
|
||||
File: g77.info, Node: Warn About Implicit Conversions, Next: Invalid Use of Hollerith Constant, Prev: Better Pedantic Compilation, Up: Missing Features
|
||||
|
||||
Warn About Implicit Conversions
|
||||
-------------------------------
|
||||
|
||||
`g77' needs a `-Wpromotions' option to warn if source code appears
|
||||
to expect automatic, silent, and somewhat dangerous compiler-assisted
|
||||
conversion of `REAL(KIND=1)' constants to `REAL(KIND=2)' based on
|
||||
context.
|
||||
|
||||
For example, it would warn about cases like this:
|
||||
|
||||
DOUBLE PRECISION FOO
|
||||
PARAMETER (TZPHI = 9.435784839284958)
|
||||
FOO = TZPHI * 3D0
|
||||
|
||||
|
||||
File: g77.info, Node: Invalid Use of Hollerith Constant, Next: Dummy Array Without Dimensioning Dummy, Prev: Warn About Implicit Conversions, Up: Missing Features
|
||||
|
||||
Invalid Use of Hollerith Constant
|
||||
---------------------------------
|
||||
|
||||
`g77' should disallow statements like `RETURN 2HAB', which are
|
||||
invalid in both source forms (unlike `RETURN (2HAB)', which probably
|
||||
still makes no sense but at least can be reliably parsed). Fixed-form
|
||||
processing rejects it, but not free-form, except in a way that is a bit
|
||||
difficult to understand.
|
||||
|
||||
|
||||
File: g77.info, Node: Dummy Array Without Dimensioning Dummy, Next: Invalid FORMAT Specifiers, Prev: Invalid Use of Hollerith Constant, Up: Missing Features
|
||||
|
||||
Dummy Array Without Dimensioning Dummy
|
||||
--------------------------------------
|
||||
|
||||
`g77' should complain when a list of dummy arguments containing an
|
||||
adjustable dummy array does not also contain every variable listed in
|
||||
the dimension list of the adjustable array.
|
||||
|
||||
Currently, `g77' does complain about a variable that dimensions an
|
||||
array but doesn't appear in any dummy list or `COMMON' area, but this
|
||||
needs to be extended to catch cases where it doesn't appear in every
|
||||
dummy list that also lists any arrays it dimensions.
|
||||
|
||||
For example, `g77' should warn about the entry point `ALT' below,
|
||||
since it includes `ARRAY' but not `ISIZE' in its list of arguments:
|
||||
|
||||
SUBROUTINE PRIMARY(ARRAY, ISIZE)
|
||||
REAL ARRAY(ISIZE)
|
||||
ENTRY ALT(ARRAY)
|
||||
|
||||
|
||||
File: g77.info, Node: Invalid FORMAT Specifiers, Next: Ambiguous Dialects, Prev: Dummy Array Without Dimensioning Dummy, Up: Missing Features
|
||||
|
||||
Invalid FORMAT Specifiers
|
||||
-------------------------
|
||||
|
||||
`g77' should check `FORMAT' specifiers for validity as it does
|
||||
`FORMAT' statements.
|
||||
|
||||
For example, a diagnostic would be produced for:
|
||||
|
||||
PRINT 'HI THERE!' !User meant PRINT *, 'HI THERE!'
|
||||
|
||||
|
||||
File: g77.info, Node: Ambiguous Dialects, Next: Unused Labels, Prev: Invalid FORMAT Specifiers, Up: Missing Features
|
||||
|
||||
Ambiguous Dialects
|
||||
------------------
|
||||
|
||||
`g77' needs a set of options such as `-Wugly*', `-Wautomatic',
|
||||
`-Wvxt', `-Wf90', and so on. These would warn about places in the
|
||||
user's source where ambiguities are found, helpful in resolving
|
||||
ambiguities in the program's dialect or dialects.
|
||||
|
||||
|
||||
File: g77.info, Node: Unused Labels, Next: Informational Messages, Prev: Ambiguous Dialects, Up: Missing Features
|
||||
|
||||
Unused Labels
|
||||
-------------
|
||||
|
||||
`g77' should warn about unused labels when `-Wunused' is in effect.
|
||||
|
||||
|
||||
File: g77.info, Node: Informational Messages, Next: Uninitialized Variables at Run Time, Prev: Unused Labels, Up: Missing Features
|
||||
|
||||
Informational Messages
|
||||
----------------------
|
||||
|
||||
`g77' needs an option to suppress information messages (notes).
|
||||
`-w' does this but also suppresses warnings. The default should be to
|
||||
suppress info messages.
|
||||
|
||||
Perhaps info messages should simply be eliminated.
|
||||
|
||||
|
||||
File: g77.info, Node: Uninitialized Variables at Run Time, Next: Bounds Checking at Run Time, Prev: Informational Messages, Up: Missing Features
|
||||
|
||||
Uninitialized Variables at Run Time
|
||||
-----------------------------------
|
||||
|
||||
`g77' needs an option to initialize everything (not otherwise
|
||||
explicitly initialized) to "weird" (machine-dependent) values, e.g.
|
||||
NaNs, bad (non-`NULL') pointers, and largest-magnitude integers, would
|
||||
help track down references to some kinds of uninitialized variables at
|
||||
run time.
|
||||
|
||||
Note that use of the options `-O -Wuninitialized' can catch many
|
||||
such bugs at compile time.
|
||||
|
||||
|
||||
File: g77.info, Node: Bounds Checking at Run Time, Next: Labels Visible to Debugger, Prev: Uninitialized Variables at Run Time, Up: Missing Features
|
||||
|
||||
Bounds Checking at Run Time
|
||||
---------------------------
|
||||
|
||||
`g77' should offer run-time bounds-checking of array/subscript
|
||||
references in a fashion similar to `f2c'.
|
||||
|
||||
Note that `g77' already warns about references to out-of-bounds
|
||||
elements of arrays when it detects these at compile time.
|
||||
|
||||
|
||||
File: g77.info, Node: Labels Visible to Debugger, Prev: Bounds Checking at Run Time, Up: Missing Features
|
||||
|
||||
Labels Visible to Debugger
|
||||
--------------------------
|
||||
|
||||
`g77' should output debugging information for statements labels, for
|
||||
use by debuggers that know how to support them. Same with weirder
|
||||
things like construct names. It is not yet known if any debug formats
|
||||
or debuggers support these.
|
||||
|
||||
|
||||
File: g77.info, Node: Disappointments, Next: Non-bugs, Prev: Missing Features, Up: Trouble
|
||||
|
||||
Disappointments and Misunderstandings
|
||||
=====================================
|
||||
|
||||
These problems are perhaps regrettable, but we don't know any
|
||||
practical way around them for now.
|
||||
|
||||
* Menu:
|
||||
|
||||
* Mangling of Names:: `SUBROUTINE FOO' is given
|
||||
external name `foo_'.
|
||||
* Multiple Definitions of External Names:: No doing both `COMMON /FOO/'
|
||||
and `SUBROUTINE FOO'.
|
||||
* Limitation on Implicit Declarations:: No `IMPLICIT CHARACTER*(*)'.
|
||||
|
||||
|
||||
File: g77.info, Node: Mangling of Names, Next: Multiple Definitions of External Names, Up: Disappointments
|
||||
|
||||
Mangling of Names in Source Code
|
||||
--------------------------------
|
||||
|
||||
The current external-interface design, which includes naming of
|
||||
external procedures, COMMON blocks, and the library interface, has
|
||||
various usability problems, including things like adding underscores
|
||||
where not really necessary (and preventing easier inter-language
|
||||
operability) and yet not providing complete namespace freedom for user
|
||||
C code linked with Fortran apps (due to the naming of functions in the
|
||||
library, among other things).
|
||||
|
||||
Project GNU should at least get all this "right" for systems it
|
||||
fully controls, such as the Hurd, and provide defaults and options for
|
||||
compatibility with existing systems and interoperability with popular
|
||||
existing compilers.
|
||||
|
||||
|
||||
File: g77.info, Node: Multiple Definitions of External Names, Next: Limitation on Implicit Declarations, Prev: Mangling of Names, Up: Disappointments
|
||||
|
||||
Multiple Definitions of External Names
|
||||
--------------------------------------
|
||||
|
||||
`g77' doesn't allow a common block and an external procedure or
|
||||
`BLOCK DATA' to have the same name. Some systems allow this, but `g77'
|
||||
does not, to be compatible with `f2c'.
|
||||
|
||||
`g77' could special-case the way it handles `BLOCK DATA', since it
|
||||
is not compatible with `f2c' in this particular area (necessarily,
|
||||
since `g77' offers an important feature here), but it is likely that
|
||||
such special-casing would be very annoying to people with programs that
|
||||
use `EXTERNAL FOO', with no other mention of `FOO' in the same program
|
||||
unit, to refer to external procedures, since the result would be that
|
||||
`g77' would treat these references as requests to force-load BLOCK DATA
|
||||
program units.
|
||||
|
||||
In that case, if `g77' modified names of `BLOCK DATA' so they could
|
||||
have the same names as `COMMON', users would find that their programs
|
||||
wouldn't link because the `FOO' procedure didn't have its name
|
||||
translated the same way.
|
||||
|
||||
(Strictly speaking, `g77' could emit a
|
||||
null-but-externally-satisfying definition of `FOO' with its name
|
||||
transformed as if it had been a `BLOCK DATA', but that probably invites
|
||||
more trouble than it's worth.)
|
||||
|
||||
|
||||
File: g77.info, Node: Limitation on Implicit Declarations, Prev: Multiple Definitions of External Names, Up: Disappointments
|
||||
|
||||
Limitation on Implicit Declarations
|
||||
-----------------------------------
|
||||
|
||||
`g77' disallows `IMPLICIT CHARACTER*(*)'. This is not
|
||||
standard-conforming.
|
||||
|
||||
|
||||
File: g77.info, Node: Non-bugs, Next: Warnings and Errors, Prev: Disappointments, Up: Trouble
|
||||
|
||||
Certain Changes We Don't Want to Make
|
||||
=====================================
|
||||
|
||||
This section lists changes that people frequently request, but which
|
||||
we do not make because we think GNU Fortran is better without them.
|
||||
|
||||
* Menu:
|
||||
|
||||
* Backslash in Constants:: Why `'\\'' is a constant that
|
||||
is one, not two, characters long.
|
||||
* Initializing Before Specifying:: Why `DATA VAR/1/' can't precede
|
||||
`COMMON VAR'.
|
||||
* Context-Sensitive Intrinsicness:: Why `CALL SQRT' won't work.
|
||||
* Context-Sensitive Constants:: Why `9.435784839284958' is a
|
||||
single-precision constant,
|
||||
and might be interpreted as
|
||||
`9.435785' or similar.
|
||||
* Equivalence Versus Equality:: Why `.TRUE. .EQ. .TRUE.' won't work.
|
||||
* Order of Side Effects:: Why `J = IFUNC() - IFUNC()' might
|
||||
not behave as expected.
|
||||
|
||||
|
||||
File: g77.info, Node: Backslash in Constants, Next: Initializing Before Specifying, Up: Non-bugs
|
||||
|
||||
Backslash in Constants
|
||||
----------------------
|
||||
|
||||
In the opinion of many experienced Fortran users, `-fno-backslash'
|
||||
should be the default, not `-fbackslash', as currently set by `g77'.
|
||||
|
||||
First of all, you can always specify `-fno-backslash' to turn off
|
||||
this processing.
|
||||
|
||||
Despite not being within the spirit (though apparently within the
|
||||
letter) of the ANSI FORTRAN 77 standard, `g77' defaults to
|
||||
`-fbackslash' because that is what most UNIX `f77' commands default to,
|
||||
and apparently lots of code depends on this feature.
|
||||
|
||||
This is a particularly troubling issue. The use of a C construct in
|
||||
the midst of Fortran code is bad enough, worse when it makes existing
|
||||
Fortran programs stop working (as happens when programs written for
|
||||
non-UNIX systems are ported to UNIX systems with compilers that provide
|
||||
the `-fbackslash' feature as the default--sometimes with no option to
|
||||
turn it off).
|
||||
|
||||
The author of GNU Fortran wished, for reasons of linguistic purity,
|
||||
to make `-fno-backslash' the default for GNU Fortran and thus require
|
||||
users of UNIX `f77' and `f2c' to specify `-fbackslash' to get the UNIX
|
||||
behavior.
|
||||
|
||||
However, the realization that `g77' is intended as a replacement for
|
||||
*UNIX* `f77', caused the author to choose to make `g77' as compatible
|
||||
with `f77' as feasible, which meant making `-fbackslash' the default.
|
||||
|
||||
The primary focus on compatibility is at the source-code level, and
|
||||
the question became "What will users expect a replacement for `f77' to
|
||||
do, by default?" Although at least one UNIX `f77' does not provide
|
||||
`-fbackslash' as a default, it appears that the majority of them do,
|
||||
which suggests that the majority of code that is compiled by UNIX `f77'
|
||||
compilers expects `-fbackslash' to be the default.
|
||||
|
||||
It is probably the case that more code exists that would *not* work
|
||||
with `-fbackslash' in force than code that requires it be in force.
|
||||
|
||||
However, most of *that* code is not being compiled with `f77', and
|
||||
when it is, new build procedures (shell scripts, makefiles, and so on)
|
||||
must be set up anyway so that they work under UNIX. That makes a much
|
||||
more natural and safe opportunity for non-UNIX users to adapt their
|
||||
build procedures for `g77''s default of `-fbackslash' than would exist
|
||||
for the majority of UNIX `f77' users who would have to modify existing,
|
||||
working build procedures to explicitly specify `-fbackslash' if that was
|
||||
not the default.
|
||||
|
||||
One suggestion has been to configure the default for `-fbackslash'
|
||||
(and perhaps other options as well) based on the configuration of `g77'.
|
||||
|
||||
This is technically quite straightforward, but will be avoided even
|
||||
in cases where not configuring defaults to be dependent on a particular
|
||||
configuration greatly inconveniences some users of legacy code.
|
||||
|
||||
Many users appreciate the GNU compilers because they provide an
|
||||
environment that is uniform across machines. These users would be
|
||||
inconvenienced if the compiler treated things like the format of the
|
||||
source code differently on certain machines.
|
||||
|
||||
Occasionally users write programs intended only for a particular
|
||||
machine type. On these occasions, the users would benefit if the GNU
|
||||
Fortran compiler were to support by default the same dialect as the
|
||||
other compilers on that machine. But such applications are rare. And
|
||||
users writing a program to run on more than one type of machine cannot
|
||||
possibly benefit from this kind of compatibility. (This is consistent
|
||||
with the design goals for `gcc'. To change them for `g77', you must
|
||||
first change them for `gcc'. Do not ask the maintainers of `g77' to do
|
||||
this for you, or to disassociate `g77' from the widely understood, if
|
||||
not widely agreed-upon, goals for GNU compilers in general.)
|
||||
|
||||
This is why GNU Fortran does and will treat backslashes in the same
|
||||
fashion on all types of machines (by default). *Note Direction of
|
||||
Language Development::, for more information on this overall philosophy
|
||||
guiding the development of the GNU Fortran language.
|
||||
|
||||
Of course, users strongly concerned about portability should indicate
|
||||
explicitly in their build procedures which options are expected by
|
||||
their source code, or write source code that has as few such
|
||||
expectations as possible.
|
||||
|
||||
For example, avoid writing code that depends on backslash (`\')
|
||||
being interpreted either way in particular, such as by starting a
|
||||
program unit with:
|
||||
|
||||
CHARACTER BACKSL
|
||||
PARAMETER (BACKSL = '\\')
|
||||
|
||||
Then, use concatenation of `BACKSL' anyplace a backslash is desired.
|
||||
In this way, users can write programs which have the same meaning in
|
||||
many Fortran dialects.
|
||||
|
||||
(However, this technique does not work for Hollerith constants--which
|
||||
is just as well, since the only generally portable uses for Hollerith
|
||||
constants are in places where character constants can and should be
|
||||
used instead, for readability.)
|
||||
|
||||
|
||||
File: g77.info, Node: Initializing Before Specifying, Next: Context-Sensitive Intrinsicness, Prev: Backslash in Constants, Up: Non-bugs
|
||||
|
||||
Initializing Before Specifying
|
||||
------------------------------
|
||||
|
||||
`g77' does not allow `DATA VAR/1/' to appear in the source code
|
||||
before `COMMON VAR', `DIMENSION VAR(10)', `INTEGER VAR', and so on. In
|
||||
general, `g77' requires initialization of a variable or array to be
|
||||
specified *after* all other specifications of attributes (type, size,
|
||||
placement, and so on) of that variable or array are specified (though
|
||||
*confirmation* of data type is permitted).
|
||||
|
||||
It is *possible* `g77' will someday allow all of this, even though
|
||||
it is not allowed by the FORTRAN 77 standard.
|
||||
|
||||
Then again, maybe it is better to have `g77' always require
|
||||
placement of `DATA' so that it can possibly immediately write constants
|
||||
to the output file, thus saving time and space.
|
||||
|
||||
That is, `DATA A/1000000*1/' should perhaps always be immediately
|
||||
writable to canonical assembler, unless it's already known to be in a
|
||||
`COMMON' area following as-yet-uninitialized stuff, and to do this it
|
||||
cannot be followed by `COMMON A'.
|
||||
|
||||
|
||||
File: g77.info, Node: Context-Sensitive Intrinsicness, Next: Context-Sensitive Constants, Prev: Initializing Before Specifying, Up: Non-bugs
|
||||
|
||||
Context-Sensitive Intrinsicness
|
||||
-------------------------------
|
||||
|
||||
`g77' treats procedure references to *possible* intrinsic names as
|
||||
always enabling their intrinsic nature, regardless of whether the
|
||||
*form* of the reference is valid for that intrinsic.
|
||||
|
||||
For example, `CALL SQRT' is interpreted by `g77' as an invalid
|
||||
reference to the `SQRT' intrinsic function, because the reference is a
|
||||
subroutine invocation.
|
||||
|
||||
First, `g77' recognizes the statement `CALL SQRT' as a reference to
|
||||
a *procedure* named `SQRT', not to a *variable* with that name (as it
|
||||
would for a statement such as `V = SQRT').
|
||||
|
||||
Next, `g77' establishes that, in the program unit being compiled,
|
||||
`SQRT' is an intrinsic--not a subroutine that happens to have the same
|
||||
name as an intrinsic (as would be the case if, for example, `EXTERNAL
|
||||
SQRT' was present).
|
||||
|
||||
Finally, `g77' recognizes that the *form* of the reference is
|
||||
invalid for that particular intrinsic. That is, it recognizes that it
|
||||
is invalid for an intrinsic *function*, such as `SQRT', to be invoked as
|
||||
a *subroutine*.
|
||||
|
||||
At that point, `g77' issues a diagnostic.
|
||||
|
||||
Some users claim that it is "obvious" that `CALL SQRT' references an
|
||||
external subroutine of their own, not an intrinsic function.
|
||||
|
||||
However, `g77' knows about intrinsic subroutines, not just
|
||||
functions, and is able to support both having the same names, for
|
||||
example.
|
||||
|
||||
As a result of this, `g77' rejects calls to intrinsics that are not
|
||||
subroutines, and function invocations of intrinsics that are not
|
||||
functions, just as it (and most compilers) rejects invocations of
|
||||
intrinsics with the wrong number (or types) of arguments.
|
||||
|
||||
So, use the `EXTERNAL SQRT' statement in a program unit that calls a
|
||||
user-written subroutine named `SQRT'.
|
||||
|
||||
|
||||
File: g77.info, Node: Context-Sensitive Constants, Next: Equivalence Versus Equality, Prev: Context-Sensitive Intrinsicness, Up: Non-bugs
|
||||
|
||||
Context-Sensitive Constants
|
||||
---------------------------
|
||||
|
||||
`g77' does not use context to determine the types of constants or
|
||||
named constants (`PARAMETER'), except for (non-standard) typeless
|
||||
constants such as `'123'O'.
|
||||
|
||||
For example, consider the following statement:
|
||||
|
||||
PRINT *, 9.435784839284958 * 2D0
|
||||
|
||||
`g77' will interpret the (truncated) constant `9.435784839284958' as a
|
||||
`REAL(KIND=1)', not `REAL(KIND=2)', constant, because the suffix `D0'
|
||||
is not specified.
|
||||
|
||||
As a result, the output of the above statement when compiled by
|
||||
`g77' will appear to have "less precision" than when compiled by other
|
||||
compilers.
|
||||
|
||||
In these and other cases, some compilers detect the fact that a
|
||||
single-precision constant is used in a double-precision context and
|
||||
therefore interpret the single-precision constant as if it was
|
||||
*explicitly* specified as a double-precision constant. (This has the
|
||||
effect of appending *decimal*, not *binary*, zeros to the fractional
|
||||
part of the number--producing different computational results.)
|
||||
|
||||
The reason this misfeature is dangerous is that a slight, apparently
|
||||
innocuous change to the source code can change the computational
|
||||
results. Consider:
|
||||
|
||||
REAL ALMOST, CLOSE
|
||||
DOUBLE PRECISION FIVE
|
||||
PARAMETER (ALMOST = 5.000000000001)
|
||||
FIVE = 5
|
||||
CLOSE = 5.000000000001
|
||||
PRINT *, 5.000000000001 - FIVE
|
||||
PRINT *, ALMOST - FIVE
|
||||
PRINT *, CLOSE - FIVE
|
||||
END
|
||||
|
||||
Running the above program should result in the same value being printed
|
||||
three times. With `g77' as the compiler, it does.
|
||||
|
||||
However, compiled by many other compilers, running the above program
|
||||
would print two or three distinct values, because in two or three of
|
||||
the statements, the constant `5.000000000001', which on most systems is
|
||||
exactly equal to `5.' when interpreted as a single-precision constant,
|
||||
is instead interpreted as a double-precision constant, preserving the
|
||||
represented precision. However, this "clever" promotion of type does
|
||||
not extend to variables or, in some compilers, to named constants.
|
||||
|
||||
Since programmers often are encouraged to replace manifest constants
|
||||
or permanently-assigned variables with named constants (`PARAMETER' in
|
||||
Fortran), and might need to replace some constants with variables
|
||||
having the same values for pertinent portions of code, it is important
|
||||
that compilers treat code so modified in the same way so that the
|
||||
results of such programs are the same. `g77' helps in this regard by
|
||||
treating constants just the same as variables in terms of determining
|
||||
their types in a context-independent way.
|
||||
|
||||
Still, there is a lot of existing Fortran code that has been written
|
||||
to depend on the way other compilers freely interpret constants' types
|
||||
based on context, so anything `g77' can do to help flag cases of this
|
||||
in such code could be very helpful.
|
||||
|
||||
|
||||
File: g77.info, Node: Equivalence Versus Equality, Next: Order of Side Effects, Prev: Context-Sensitive Constants, Up: Non-bugs
|
||||
|
||||
Equivalence Versus Equality
|
||||
---------------------------
|
||||
|
||||
Use of `.EQ.' and `.NE.' on `LOGICAL' operands is not supported,
|
||||
except via `-fugly', which is not recommended except for legacy code
|
||||
(where the behavior expected by the *code* is assumed).
|
||||
|
||||
Legacy code should be changed, as resources permit, to use `.EQV.'
|
||||
and `.NEQV.' instead, as these are permitted by the various Fortran
|
||||
standards.
|
||||
|
||||
New code should never be written expecting `.EQ.' or `.NE.' to work
|
||||
if either of its operands is `LOGICAL'.
|
||||
|
||||
The problem with supporting this "feature" is that there is unlikely
|
||||
to be consensus on how it works, as illustrated by the following sample
|
||||
program:
|
||||
|
||||
LOGICAL L,M,N
|
||||
DATA L,M,N /3*.FALSE./
|
||||
IF (L.AND.M.EQ.N) PRINT *,'L.AND.M.EQ.N'
|
||||
END
|
||||
|
||||
The issue raised by the above sample program is: what is the
|
||||
precedence of `.EQ.' (and `.NE.') when applied to `LOGICAL' operands?
|
||||
|
||||
Some programmers will argue that it is the same as the precedence
|
||||
for `.EQ.' when applied to numeric (such as `INTEGER') operands. By
|
||||
this interpretation, the subexpression `M.EQ.N' must be evaluated first
|
||||
in the above program, resulting in a program that, when run, does not
|
||||
execute the `PRINT' statement.
|
||||
|
||||
Other programmers will argue that the precedence is the same as the
|
||||
precedence for `.EQV.', which is restricted by the standards to
|
||||
`LOGICAL' operands. By this interpretation, the subexpression
|
||||
`L.AND.M' must be evaluated first, resulting in a program that *does*
|
||||
execute the `PRINT' statement.
|
||||
|
||||
Assigning arbitrary semantic interpretations to syntactic expressions
|
||||
that might legitimately have more than one "obvious" interpretation is
|
||||
generally unwise.
|
||||
|
||||
The creators of the various Fortran standards have done a good job
|
||||
in this case, requiring a distinct set of operators (which have their
|
||||
own distinct precedence) to compare `LOGICAL' operands. This
|
||||
requirement results in expression syntax with more certain precedence
|
||||
(without requiring substantial context), making it easier for
|
||||
programmers to read existing code. `g77' will avoid muddying up
|
||||
elements of the Fortran language that were well-designed in the first
|
||||
place.
|
||||
|
||||
(Ask C programmers about the precedence of expressions such as `(a)
|
||||
& (b)' and `(a) - (b)'--they cannot even tell you, without knowing more
|
||||
context, whether the `&' and `-' operators are infix (binary) or unary!)
|
||||
|
||||
|
||||
File: g77.info, Node: Order of Side Effects, Prev: Equivalence Versus Equality, Up: Non-bugs
|
||||
|
||||
Order of Side Effects
|
||||
---------------------
|
||||
|
||||
`g77' does not necessarily produce code that, when run, performs
|
||||
side effects (such as those performed by function invocations) in the
|
||||
same order as in some other compiler--or even in the same order as
|
||||
another version, port, or invocation (using different command-line
|
||||
options) of `g77'.
|
||||
|
||||
It is never safe to depend on the order of evaluation of side
|
||||
effects. For example, an expression like this may very well behave
|
||||
differently from one compiler to another:
|
||||
|
||||
J = IFUNC() - IFUNC()
|
||||
|
||||
There is no guarantee that `IFUNC' will be evaluated in any particular
|
||||
order. Either invocation might happen first. If `IFUNC' returns 5 the
|
||||
first time it is invoked, and returns 12 the second time, `J' might end
|
||||
up with the value `7', or it might end up with `-7'.
|
||||
|
||||
Generally, in Fortran, procedures with side-effects intended to be
|
||||
visible to the caller are best designed as *subroutines*, not functions.
|
||||
Examples of such side-effects include:
|
||||
|
||||
* The generation of random numbers that are intended to influence
|
||||
return values.
|
||||
|
||||
* Performing I/O (other than internal I/O to local variables).
|
||||
|
||||
* Updating information in common blocks.
|
||||
|
||||
An example of a side-effect that is not intended to be visible to
|
||||
the caller is a function that maintains a cache of recently calculated
|
||||
results, intended solely to speed repeated invocations of the function
|
||||
with identical arguments. Such a function can be safely used in
|
||||
expressions, because if the compiler optimizes away one or more calls
|
||||
to the function, operation of the program is unaffected (aside from
|
||||
being speeded up).
|
||||
|
||||
|
||||
File: g77.info, Node: Warnings and Errors, Prev: Non-bugs, Up: Trouble
|
||||
|
||||
Warning Messages and Error Messages
|
||||
===================================
|
||||
|
||||
The GNU compiler can produce two kinds of diagnostics: errors and
|
||||
warnings. Each kind has a different purpose:
|
||||
|
||||
*Errors* report problems that make it impossible to compile your
|
||||
program. GNU Fortran reports errors with the source file name,
|
||||
line number, and column within the line where the problem is
|
||||
apparent.
|
||||
|
||||
*Warnings* report other unusual conditions in your code that
|
||||
*might* indicate a problem, although compilation can (and does)
|
||||
proceed. Warning messages also report the source file name, line
|
||||
number, and column information, but include the text `warning:' to
|
||||
distinguish them from error messages.
|
||||
|
||||
Warnings might indicate danger points where you should check to make
|
||||
sure that your program really does what you intend; or the use of
|
||||
obsolete features; or the use of nonstandard features of GNU Fortran.
|
||||
Many warnings are issued only if you ask for them, with one of the `-W'
|
||||
options (for instance, `-Wall' requests a variety of useful warnings).
|
||||
|
||||
*Note:* Currently, the text of the line and a pointer to the column
|
||||
is printed in most `g77' diagnostics. Probably, as of version 0.6,
|
||||
`g77' will no longer print the text of the source line, instead printing
|
||||
the column number following the file name and line number in a form
|
||||
that GNU Emacs recognizes. This change is expected to speed up and
|
||||
reduce the memory usage of the `g77' compiler.
|
||||
|
||||
*Note Options to Request or Suppress Warnings: Warning Options, for
|
||||
more detail on these and related command-line options.
|
||||
|
||||
|
||||
File: g77.info, Node: Open Questions, Next: Bugs, Prev: Trouble, Up: Top
|
||||
|
||||
Open Questions
|
||||
**************
|
||||
|
||||
Please consider offering useful answers to these questions!
|
||||
|
||||
* How do system administrators and users manage multiple incompatible
|
||||
Fortran compilers on their systems? How can `g77' contribute to
|
||||
this, or at least avoiding intefering with it?
|
||||
|
||||
Currently, `g77' provides rudimentary ways to choose whether to
|
||||
overwrite portions of other Fortran compilation systems (such as
|
||||
the `f77' command and the `libf2c' library). Is this sufficient?
|
||||
What happens when users choose not to overwrite these--does `g77'
|
||||
work properly in all such installations, picking up its own
|
||||
versions, or does it pick up the existing "alien" versions it
|
||||
didn't overwrite with its own, possibly leading to subtle bugs?
|
||||
|
||||
* `LOC()' and other intrinsics are probably somewhat misclassified.
|
||||
Is the a need for more precise classification of intrinsics, and
|
||||
if so, what are the appropriate groupings? Is there a need to
|
||||
individually enable/disable/delete/hide intrinsics from the
|
||||
command line?
|
||||
|
||||
|
||||
File: g77.info, Node: Bugs, Next: Service, Prev: Open Questions, Up: Top
|
||||
|
||||
Reporting Bugs
|
||||
**************
|
||||
|
||||
Your bug reports play an essential role in making GNU Fortran
|
||||
reliable.
|
||||
|
||||
When you encounter a problem, the first thing to do is to see if it
|
||||
is already known. *Note Trouble::. If it isn't known, then you should
|
||||
report the problem.
|
||||
|
||||
Reporting a bug might help you by bringing a solution to your
|
||||
problem, or it might not. (If it does not, look in the service
|
||||
directory; see *Note Service::.) In any case, the principal function
|
||||
of a bug report is to help the entire community by making the next
|
||||
version of GNU Fortran work better. Bug reports are your contribution
|
||||
to the maintenance of GNU Fortran.
|
||||
|
||||
Since the maintainers are very overloaded, we cannot respond to every
|
||||
bug report. However, if the bug has not been fixed, we are likely to
|
||||
send you a patch and ask you to tell us whether it works.
|
||||
|
||||
In order for a bug report to serve its purpose, you must include the
|
||||
information that makes for fixing the bug.
|
||||
|
||||
* Menu:
|
||||
|
||||
* Criteria: Bug Criteria. Have you really found a bug?
|
||||
* Where: Bug Lists. Where to send your bug report.
|
||||
* Reporting: Bug Reporting. How to report a bug effectively.
|
||||
* Patches: Sending Patches. How to send a patch for GNU Fortran.
|
||||
|
||||
*Note Known Causes of Trouble with GNU Fortran: Trouble, for
|
||||
information on problems we already know about.
|
||||
|
||||
*Note How To Get Help with GNU Fortran: Service, for information on
|
||||
where to ask for help.
|
||||
|
||||
|
||||
File: g77.info, Node: Bug Criteria, Next: Bug Lists, Up: Bugs
|
||||
|
||||
Have You Found a Bug?
|
||||
=====================
|
||||
|
||||
If you are not sure whether you have found a bug, here are some
|
||||
guidelines:
|
||||
|
||||
* If the compiler gets a fatal signal, for any input whatever, that
|
||||
is a compiler bug. Reliable compilers never crash--they just
|
||||
remain obsolete.
|
||||
|
||||
* If the compiler produces invalid assembly code, for any input
|
||||
whatever, that is a compiler bug, unless the compiler reports
|
||||
errors (not just warnings) which would ordinarily prevent the
|
||||
assembler from being run.
|
||||
|
||||
* If the compiler produces valid assembly code that does not
|
||||
correctly execute the input source code, that is a compiler bug.
|
||||
|
||||
However, you must double-check to make sure, because you might
|
||||
have run into an incompatibility between GNU Fortran and
|
||||
traditional Fortran. These incompatibilities might be considered
|
||||
bugs, but they are inescapable consequences of valuable features.
|
||||
|
||||
Or you might have a program whose behavior is undefined, which
|
||||
happened by chance to give the desired results with another
|
||||
Fortran compiler. It is best to check the relevant Fortran
|
||||
standard thoroughly if it is possible that the program indeed does
|
||||
something undefined.
|
||||
|
||||
After you have localized the error to a single source line, it
|
||||
should be easy to check for these things. If your program is
|
||||
correct and well defined, you have found a compiler bug.
|
||||
|
||||
It might help if, in your submission, you identified the specific
|
||||
language in the relevant Fortran standard that specifies the
|
||||
desired behavior, if it isn't likely to be obvious and agreed-upon
|
||||
by all Fortran users.
|
||||
|
||||
* If the compiler produces an error message for valid input, that is
|
||||
a compiler bug.
|
||||
|
||||
* If the compiler does not produce an error message for invalid
|
||||
input, that is a compiler bug. However, you should note that your
|
||||
idea of "invalid input" might be someone else's idea of "an
|
||||
extension" or "support for traditional practice".
|
||||
|
||||
* If you are an experienced user of Fortran compilers, your
|
||||
suggestions for improvement of GNU Fortran are welcome in any case.
|
||||
|
||||
Many, perhaps most, bug reports against `g77' turn out to be bugs in
|
||||
the user's code. While we find such bug reports educational, they
|
||||
sometimes take a considerable amount of time to track down or at least
|
||||
respond to--time we could be spending making `g77', not some user's
|
||||
code, better.
|
||||
|
||||
Some steps you can take to verify that the bug is not certainly in
|
||||
the code you're compiling with `g77':
|
||||
|
||||
* Compile your code using the `g77' options `-W -Wall -O'. These
|
||||
options enable many useful warning; the `-O' option enables flow
|
||||
analysis that enables the uninitialized-variable warning.
|
||||
|
||||
If you investigate the warnings and find evidence of possible bugs
|
||||
in your code, fix them first and retry `g77'.
|
||||
|
||||
* Compile your code using the `g77' options `-finit-local-zero',
|
||||
`-fno-automatic', `-ffloat-store', and various combinations
|
||||
thereof.
|
||||
|
||||
If your code works with any of these combinations, that is not
|
||||
proof that the bug isn't in `g77'--a `g77' bug exposed by your
|
||||
code might simply be avoided, or have a different, more subtle
|
||||
effect, when different options are used--but it can be a strong
|
||||
indicator that your code is making unawarranted assumptions about
|
||||
the Fortran dialect and/or underlying machine it is being compiled
|
||||
and run on.
|
||||
|
||||
*Note Overly Convenient Command-Line Options: Overly Convenient
|
||||
Options, for information on the `-fno-automatic' and
|
||||
`-finit-local-zero' options and how to convert their use into
|
||||
selective changes in your own code.
|
||||
|
||||
* Validate your code with `ftnchek' or a similar code-checking tool.
|
||||
`ftncheck' can be found at `ftp://ftp.netlib.org/fortran' or
|
||||
`ftp://ftp.dsm.fordham.edu'.
|
||||
|
||||
* Try your code out using other Fortran compilers, such as `f2c'.
|
||||
If it does not work on at least one other compiler (assuming the
|
||||
compiler supports the features the code needs), that is a strong
|
||||
indicator of a bug in the code.
|
||||
|
||||
However, even if your code works on many compilers *except* `g77',
|
||||
that does *not* mean the bug is in `g77'. It might mean the bug
|
||||
is in your code, and that `g77' simply exposes it more readily
|
||||
than other compilers.
|
||||
|
||||
|
||||
File: g77.info, Node: Bug Lists, Next: Bug Reporting, Prev: Bug Criteria, Up: Bugs
|
||||
|
||||
Where to Report Bugs
|
||||
====================
|
||||
|
||||
Send bug reports for GNU Fortran to <fortran@gnu.ai.mit.edu>.
|
||||
|
||||
Often people think of posting bug reports to a newsgroup instead of
|
||||
mailing them. This sometimes appears to work, but it has one problem
|
||||
which can be crucial: a newsgroup posting does not contain a mail path
|
||||
back to the sender. Thus, if maintainers need more information, they
|
||||
might be unable to reach you. For this reason, you should always send
|
||||
bug reports by mail to the proper mailing list.
|
||||
|
||||
As a last resort, send bug reports on paper to:
|
||||
|
||||
GNU Compiler Bugs
|
||||
Free Software Foundation
|
||||
59 Temple Place - Suite 330
|
||||
Boston, MA 02111-1307, USA
|
||||
|
1125
gcc/f/g77.info-18
1125
gcc/f/g77.info-18
File diff suppressed because it is too large
Load Diff
@ -1,296 +0,0 @@
|
||||
This is Info file g77.info, produced by Makeinfo version 1.68 from the
|
||||
input file g77.texi.
|
||||
|
||||
This file explains how to use the GNU Fortran system.
|
||||
|
||||
Published by the Free Software Foundation 59 Temple Place - Suite 330
|
||||
Boston, MA 02111-1307 USA
|
||||
|
||||
Copyright (C) 1995-1997 Free Software Foundation, Inc.
|
||||
|
||||
Permission is granted to make and distribute verbatim copies of this
|
||||
manual provided the copyright notice and this permission notice are
|
||||
preserved on all copies.
|
||||
|
||||
Permission is granted to copy and distribute modified versions of
|
||||
this manual under the conditions for verbatim copying, provided also
|
||||
that the sections entitled "GNU General Public License," "Funding for
|
||||
Free Software," and "Protect Your Freedom--Fight `Look And Feel'" are
|
||||
included exactly as in the original, and provided that the entire
|
||||
resulting derived work is distributed under the terms of a permission
|
||||
notice identical to this one.
|
||||
|
||||
Permission is granted to copy and distribute translations of this
|
||||
manual into another language, under the above conditions for modified
|
||||
versions, except that the sections entitled "GNU General Public
|
||||
License," "Funding for Free Software," and "Protect Your Freedom--Fight
|
||||
`Look And Feel'", and this permission notice, may be included in
|
||||
translations approved by the Free Software Foundation instead of in the
|
||||
original English.
|
||||
|
||||
Contributed by James Craig Burley (<burley@gnu.ai.mit.edu>).
|
||||
Inspired by a first pass at translating `g77-0.5.16/f/DOC' that was
|
||||
contributed to Craig by David Ronis (<ronis@onsager.chem.mcgill.ca>).
|
||||
|
||||
INFO-DIR-SECTION Fortran Programming
|
||||
START-INFO-DIR-ENTRY
|
||||
* g77: (g77). The GNU Fortran compilation system.
|
||||
END-INFO-DIR-ENTRY
|
||||
|
||||
|
||||
File: g77.info, Node: EXPIMP, Next: INTGLOB, Prev: CMPAMBIG, Up: Diagnostics
|
||||
|
||||
`EXPIMP'
|
||||
========
|
||||
|
||||
Intrinsic INTRINSIC referenced ...
|
||||
|
||||
The INTRINSIC is explicitly declared in one program unit in the
|
||||
source file and implicitly used as an intrinsic in another program unit
|
||||
in the same source file.
|
||||
|
||||
This diagnostic is designed to catch cases where a program might
|
||||
depend on using the name INTRINSIC as an intrinsic in one program unit
|
||||
and as a global name (such as the name of a subroutine or function) in
|
||||
another, but `g77' recognizes the name as an intrinsic in both cases.
|
||||
|
||||
After verifying that the program unit making implicit use of the
|
||||
intrinsic is indeed written expecting the intrinsic, add an `INTRINSIC
|
||||
INTRINSIC' statement to that program unit to prevent this warning.
|
||||
|
||||
This and related warnings are disabled by using the `-Wno-globals'
|
||||
option when compiling.
|
||||
|
||||
Note that this warning is not issued for standard intrinsics.
|
||||
Standard intrinsics include those described in the FORTRAN 77 standard
|
||||
and, if `-ff90' is specified, those described in the Fortran 90
|
||||
standard. Such intrinsics are not as likely to be confused with user
|
||||
procedures as intrinsics provided as extensions to the standard by
|
||||
`g77'.
|
||||
|
||||
|
||||
File: g77.info, Node: INTGLOB, Next: LEX, Prev: EXPIMP, Up: Diagnostics
|
||||
|
||||
`INTGLOB'
|
||||
=========
|
||||
|
||||
Same name `INTRINSIC' given ...
|
||||
|
||||
The name INTRINSIC is used for a global entity (a common block or a
|
||||
program unit) in one program unit and implicitly used as an intrinsic
|
||||
in another program unit.
|
||||
|
||||
This diagnostic is designed to catch cases where a program intends
|
||||
to use a name entirely as a global name, but `g77' recognizes the name
|
||||
as an intrinsic in the program unit that references the name, a
|
||||
situation that would likely produce incorrect code.
|
||||
|
||||
For example:
|
||||
|
||||
INTEGER FUNCTION TIME()
|
||||
...
|
||||
END
|
||||
...
|
||||
PROGRAM SAMP
|
||||
INTEGER TIME
|
||||
PRINT *, 'Time is ', TIME()
|
||||
END
|
||||
|
||||
The above example defines a program unit named `TIME', but the
|
||||
reference to `TIME' in the main program unit `SAMP' is normally treated
|
||||
by `g77' as a reference to the intrinsic `TIME()' (unless a
|
||||
command-line option that prevents such treatment has been specified).
|
||||
|
||||
As a result, the program `SAMP' will *not* invoke the `TIME'
|
||||
function in the same source file.
|
||||
|
||||
Since `g77' recognizes `libU77' procedures as intrinsics, and since
|
||||
some existing code uses the same names for its own procedures as used
|
||||
by some `libU77' procedures, this situation is expected to arise often
|
||||
enough to make this sort of warning worth issuing.
|
||||
|
||||
After verifying that the program unit making implicit use of the
|
||||
intrinsic is indeed written expecting the intrinsic, add an `INTRINSIC
|
||||
INTRINSIC' statement to that program unit to prevent this warning.
|
||||
|
||||
Or, if you believe the program unit is designed to invoke the
|
||||
program-defined procedure instead of the intrinsic (as recognized by
|
||||
`g77'), add an `EXTERNAL INTRINSIC' statement to the program unit that
|
||||
references the name to prevent this warning.
|
||||
|
||||
This and related warnings are disabled by using the `-Wno-globals'
|
||||
option when compiling.
|
||||
|
||||
Note that this warning is not issued for standard intrinsics.
|
||||
Standard intrinsics include those described in the FORTRAN 77 standard
|
||||
and, if `-ff90' is specified, those described in the Fortran 90
|
||||
standard. Such intrinsics are not as likely to be confused with user
|
||||
procedures as intrinsics provided as extensions to the standard by
|
||||
`g77'.
|
||||
|
||||
|
||||
File: g77.info, Node: LEX, Next: GLOBALS, Prev: INTGLOB, Up: Diagnostics
|
||||
|
||||
`LEX'
|
||||
=====
|
||||
|
||||
Unrecognized character ...
|
||||
Invalid first character ...
|
||||
Line too long ...
|
||||
Non-numeric character ...
|
||||
Continuation indicator ...
|
||||
Label at ... invalid with continuation line indicator ...
|
||||
Character constant ...
|
||||
Continuation line ...
|
||||
Statement at ... begins with invalid token
|
||||
|
||||
Although the diagnostics identify specific problems, they can be
|
||||
produced when general problems such as the following occur:
|
||||
|
||||
* The source file contains something other than Fortran code.
|
||||
|
||||
If the code in the file does not look like many of the examples
|
||||
elsewhere in this document, it might not be Fortran code. (Note
|
||||
that Fortran code often is written in lower case letters, while
|
||||
the examples in this document use upper case letters, for
|
||||
stylistic reasons.)
|
||||
|
||||
For example, if the file contains lots of strange-looking
|
||||
characters, it might be APL source code; if it contains lots of
|
||||
parentheses, it might be Lisp source code; if it contains lots of
|
||||
bugs, it might be C++ source code.
|
||||
|
||||
* The source file contains free-form Fortran code, but `-ffree-form'
|
||||
was not specified on the command line to compile it.
|
||||
|
||||
Free form is a newer form for Fortran code. The older, classic
|
||||
form is called fixed form.
|
||||
|
||||
Fixed-form code is visually fairly distinctive, because numerical
|
||||
labels and comments are all that appear in the first five columns
|
||||
of a line, the sixth column is reserved to denote continuation
|
||||
lines, and actual statements start at or beyond column 7. Spaces
|
||||
generally are not significant, so if you see statements such as
|
||||
`REALX,Y' and `DO10I=1,100', you are looking at fixed-form code.
|
||||
Comment lines are indicated by the letter `C' or the symbol `*' in
|
||||
column 1. (Some code uses `!' or `/*' to begin in-line comments,
|
||||
which many compilers support.)
|
||||
|
||||
Free-form code is distinguished from fixed-form source primarily
|
||||
by the fact that statements may start anywhere. (If lots of
|
||||
statements start in columns 1 through 6, that's a strong indicator
|
||||
of free-form source.) Consecutive keywords must be separated by
|
||||
spaces, so `REALX,Y' is not valid, while `REAL X,Y' is. There are
|
||||
no comment lines per se, but `!' starts a comment anywhere in a
|
||||
line (other than within a character or hollerith constant).
|
||||
|
||||
*Note Source Form::, for more information.
|
||||
|
||||
* The source file is in fixed form and has been edited without
|
||||
sensitivity to the column requirements.
|
||||
|
||||
Statements in fixed-form code must be entirely contained within
|
||||
columns 7 through 72 on a given line. Starting them "early" is
|
||||
more likely to result in diagnostics than finishing them "late",
|
||||
though both kinds of errors are often caught at compile time.
|
||||
|
||||
For example, if the following code fragment is edited by following
|
||||
the commented instructions literally, the result, shown afterward,
|
||||
would produce a diagnostic when compiled:
|
||||
|
||||
C On XYZZY systems, remove "C" on next line:
|
||||
C CALL XYZZY_RESET
|
||||
|
||||
The result of editing the above line might be:
|
||||
|
||||
C On XYZZY systems, remove "C" on next line:
|
||||
CALL XYZZY_RESET
|
||||
|
||||
However, that leaves the first `C' in the `CALL' statement in
|
||||
column 6, making it a comment line, which is not really what the
|
||||
author intended, and which is likely to result in one of the
|
||||
above-listed diagnostics.
|
||||
|
||||
*Replacing* the `C' in column 1 with a space is the proper change
|
||||
to make, to ensure the `CALL' keyword starts in or after column 7.
|
||||
|
||||
Another common mistake like this is to forget that fixed-form
|
||||
source lines are significant through only column 72, and that,
|
||||
normally, any text beyond column 72 is ignored or is diagnosed at
|
||||
compile time.
|
||||
|
||||
*Note Source Form::, for more information.
|
||||
|
||||
* The source file requires preprocessing, and the preprocessing is
|
||||
not being specified at compile time.
|
||||
|
||||
A source file containing lines beginning with `#define',
|
||||
`#include', `#if', and so on is likely one that requires
|
||||
preprocessing.
|
||||
|
||||
If the file's suffix is `.f' or `.for', the file will normally be
|
||||
compiled *without* preprocessing by `g77'.
|
||||
|
||||
Change the file's suffix from `.f' to `.F' (or, on systems with
|
||||
case-insensitive file names, to `.fpp') or from `.for' to `.fpp'.
|
||||
`g77' compiles files with such names *with* preprocessing.
|
||||
|
||||
Or, learn how to use `gcc''s `-x' option to specify the language
|
||||
`f77-cpp-input' for Fortran files that require preprocessing.
|
||||
*Note gcc: (Using and Porting GNU CC)Overall Options.
|
||||
|
||||
* The source file is preprocessed, and the results of preprocessing
|
||||
result in syntactic errors that are not necessarily obvious to
|
||||
someone examining the source file itself.
|
||||
|
||||
Examples of errors resulting from preprocessor macro expansion
|
||||
include exceeding the line-length limit, improperly starting,
|
||||
terminating, or incorporating the apostrophe or double-quote in a
|
||||
character constant, improperly forming a hollerith constant, and
|
||||
so on.
|
||||
|
||||
*Note Options Controlling the Kind of Output: Overall Options, for
|
||||
suggestions about how to use, and not use, preprocessing for
|
||||
Fortran code.
|
||||
|
||||
|
||||
File: g77.info, Node: GLOBALS, Prev: LEX, Up: Diagnostics
|
||||
|
||||
`GLOBALS'
|
||||
=========
|
||||
|
||||
Global name NAME defined at ... already defined...
|
||||
Global name NAME at ... has different type...
|
||||
Too many arguments passed to NAME at ...
|
||||
Too few arguments passed to NAME at ...
|
||||
Argument #N of NAME is ...
|
||||
|
||||
These messages all identify disagreements about the global procedure
|
||||
named NAME among different program units (usually including NAME
|
||||
itself).
|
||||
|
||||
These disagreements, if not diagnosed, could result in a compiler
|
||||
crash if the compiler attempted to inline a reference to NAME within a
|
||||
calling program unit that disagreed with the NAME program unit
|
||||
regarding whether the procedure is a subroutine or function, the type
|
||||
of the return value of the procedure (if it is a function), the number
|
||||
of arguments the procedure accepts, or the type of each argument.
|
||||
|
||||
Such disagreements *should* be fixed in the Fortran code itself.
|
||||
However, if that is not immediately practical, and the code has been
|
||||
working for some time, it is possible it will work when compiled by
|
||||
`g77' with the `-fno-globals' option.
|
||||
|
||||
The `-fno-globals' option disables these diagnostics, and also
|
||||
disables all inlining of references to global procedures to avoid
|
||||
compiler crashes. The diagnostics are actually produced, but as
|
||||
warnings, unless the `-Wno-globals' option also is specified.
|
||||
|
||||
After using `-fno-globals' to work around these problems, it is wise
|
||||
to stop using that option and address them by fixing the Fortran code,
|
||||
because such problems, while they might not actually result in bugs on
|
||||
some systems, indicate that the code is not as portable as it could be.
|
||||
In particular, the code might appear to work on a particular system,
|
||||
but have bugs that affect the reliability of the data without
|
||||
exhibiting any other outward manifestations of the bugs.
|
||||
|
968
gcc/f/g77.info-2
968
gcc/f/g77.info-2
@ -1,968 +0,0 @@
|
||||
This is Info file g77.info, produced by Makeinfo version 1.68 from the
|
||||
input file g77.texi.
|
||||
|
||||
This file explains how to use the GNU Fortran system.
|
||||
|
||||
Published by the Free Software Foundation 59 Temple Place - Suite 330
|
||||
Boston, MA 02111-1307 USA
|
||||
|
||||
Copyright (C) 1995-1997 Free Software Foundation, Inc.
|
||||
|
||||
Permission is granted to make and distribute verbatim copies of this
|
||||
manual provided the copyright notice and this permission notice are
|
||||
preserved on all copies.
|
||||
|
||||
Permission is granted to copy and distribute modified versions of
|
||||
this manual under the conditions for verbatim copying, provided also
|
||||
that the sections entitled "GNU General Public License," "Funding for
|
||||
Free Software," and "Protect Your Freedom--Fight `Look And Feel'" are
|
||||
included exactly as in the original, and provided that the entire
|
||||
resulting derived work is distributed under the terms of a permission
|
||||
notice identical to this one.
|
||||
|
||||
Permission is granted to copy and distribute translations of this
|
||||
manual into another language, under the above conditions for modified
|
||||
versions, except that the sections entitled "GNU General Public
|
||||
License," "Funding for Free Software," and "Protect Your Freedom--Fight
|
||||
`Look And Feel'", and this permission notice, may be included in
|
||||
translations approved by the Free Software Foundation instead of in the
|
||||
original English.
|
||||
|
||||
Contributed by James Craig Burley (<burley@gnu.ai.mit.edu>).
|
||||
Inspired by a first pass at translating `g77-0.5.16/f/DOC' that was
|
||||
contributed to Craig by David Ronis (<ronis@onsager.chem.mcgill.ca>).
|
||||
|
||||
INFO-DIR-SECTION Fortran Programming
|
||||
START-INFO-DIR-ENTRY
|
||||
* g77: (g77). The GNU Fortran compilation system.
|
||||
END-INFO-DIR-ENTRY
|
||||
|
||||
|
||||
File: g77.info, Node: Overall Options, Next: Shorthand Options, Prev: Option Summary, Up: Invoking G77
|
||||
|
||||
Options Controlling the Kind of Output
|
||||
======================================
|
||||
|
||||
Compilation can involve as many as four stages: preprocessing, code
|
||||
generation (often what is really meant by the term "compilation"),
|
||||
assembly, and linking, always in that order. The first three stages
|
||||
apply to an individual source file, and end by producing an object
|
||||
file; linking combines all the object files (those newly compiled, and
|
||||
those specified as input) into an executable file.
|
||||
|
||||
For any given input file, the file name suffix determines what kind
|
||||
of program is contained in the file--that is, the language in which the
|
||||
program is written is generally indicated by the suffix. Suffixes
|
||||
specific to GNU Fortran are listed below. *Note gcc: (Using and
|
||||
Porting GNU CC)Overall Options, for information on suffixes recognized
|
||||
by GNU CC.
|
||||
|
||||
`FILE.f'
|
||||
|
||||
`FILE.for'
|
||||
Fortran source code that should not be preprocessed.
|
||||
|
||||
Such source code cannot contain any preprocessor directives, such
|
||||
as `#include', `#define', `#if', and so on.
|
||||
|
||||
`FILE.F'
|
||||
|
||||
`FILE.fpp'
|
||||
Fortran source code that must be preprocessed (by the C
|
||||
preprocessor `cpp', which is part of GNU CC).
|
||||
|
||||
Note that preprocessing is not extended to the contents of files
|
||||
included by the `INCLUDE' directive--the `#include' preprocessor
|
||||
directive must be used instead.
|
||||
|
||||
`FILE.r'
|
||||
Ratfor source code, which must be preprocessed by the `ratfor'
|
||||
command, which is available separately (as it is not yet part of
|
||||
the GNU Fortran distribution).
|
||||
|
||||
UNIX users typically use the `FILE.f' and `FILE.F' nomenclature.
|
||||
Users of other operating systems, especially those that cannot
|
||||
distinguish upper-case letters from lower-case letters in their file
|
||||
names, typically use the `FILE.for' and `FILE.fpp' nomenclature.
|
||||
|
||||
Use of the preprocessor `cpp' allows use of C-like constructs such
|
||||
as `#define' and `#include', but can lead to unexpected, even mistaken,
|
||||
results due to Fortran's source file format. It is recommended that
|
||||
use of the C preprocessor be limited to `#include' and, in conjunction
|
||||
with `#define', only `#if' and related directives, thus avoiding
|
||||
in-line macro expansion entirely. This recommendation applies
|
||||
especially when using the traditional fixed source form. With free
|
||||
source form, fewer unexpected transformations are likely to happen, but
|
||||
use of constructs such as Hollerith and character constants can
|
||||
nevertheless present problems, especially when these are continued
|
||||
across multiple source lines. These problems result, primarily, from
|
||||
differences between the way such constants are interpreted by the C
|
||||
preprocessor and by a Fortran compiler.
|
||||
|
||||
Another example of a problem that results from using the C
|
||||
preprocessor is that a Fortran comment line that happens to contain any
|
||||
characters "interesting" to the C preprocessor, such as a backslash at
|
||||
the end of the line, is not recognized by the preprocessor as a comment
|
||||
line, so instead of being passed through "raw", the line is edited
|
||||
according to the rules for the preprocessor. For example, the
|
||||
backslash at the end of the line is removed, along with the subsequent
|
||||
newline, resulting in the next line being effectively commented
|
||||
out--unfortunate if that line is a non-comment line of important code!
|
||||
|
||||
*Note:* The `-traditional' and `-undef' flags are supplied to `cpp'
|
||||
by default, to avoid unpleasant surprises. *Note Options Controlling
|
||||
the Preprocessor: (gcc)Preprocessor Options. This means that ANSI C
|
||||
preprocessor features (such as the `#' operator) aren't available, and
|
||||
only variables in the C reserved namespace (generally, names with a
|
||||
leading underscore) are liable to substitution by C predefines. Thus,
|
||||
if you want to do system-specific tests, use, for example, `#ifdef
|
||||
__linux__' rather than `#ifdef linux'. Use the `-v' option to see
|
||||
exactly how the preprocessor is invoked.
|
||||
|
||||
The following options that affect overall processing are recognized
|
||||
by the `g77' and `gcc' commands in a GNU Fortran installation:
|
||||
|
||||
`--driver=COMMAND'
|
||||
This works when invoking only the `g77' command, not when invoking
|
||||
the `gcc' command. *Note GNU Fortran Command Options: Invoking
|
||||
G77, for information on this option.
|
||||
|
||||
`-fversion'
|
||||
Ensure that the `g77'-specific version of the compiler phase is
|
||||
reported, if run. (This is supplied automatically when `-v' or
|
||||
`--verbose' is specified as a command-line option for `g77' or
|
||||
`gcc' and when the resulting commands compile Fortran source
|
||||
files.)
|
||||
|
||||
`-fset-g77-defaults'
|
||||
Set up whatever `gcc' options are to apply to Fortran
|
||||
compilations, and avoid running internal consistency checks that
|
||||
might take some time.
|
||||
|
||||
As of version 0.5.20, this is equivalent to `-fmove-all-movables
|
||||
-freduce-all-givs -frerun-loop-opt -fargument-noalias-global'.
|
||||
|
||||
This option is supplied automatically when compiling Fortran code
|
||||
via the `g77' or `gcc' command. The description of this option is
|
||||
provided so that users seeing it in the output of, say, `g77 -v'
|
||||
understand why it is there.
|
||||
|
||||
Also, developers who run `f771' directly might want to specify it
|
||||
by hand to get the same defaults as they would running `f771' via
|
||||
`g77' or `gcc'. However, such developers should, after linking a
|
||||
new `f771' executable, invoke it without this option once, e.g.
|
||||
via `./f771 -quiet < /dev/null', to ensure that they have not
|
||||
introduced any internal inconsistencies (such as in the table of
|
||||
intrinsics) before proceeding--`g77' will crash with a diagnostic
|
||||
if it detects an inconsistency.
|
||||
|
||||
`-fno-silent'
|
||||
Print (to `stderr') the names of the program units as they are
|
||||
compiled, in a form similar to that used by popular UNIX `f77'
|
||||
implementations and `f2c'.
|
||||
|
||||
*Note Options Controlling the Kind of Output: (gcc)Overall Options,
|
||||
for information on more options that control the overall operation of
|
||||
the `gcc' command (and, by extension, the `g77' command).
|
||||
|
||||
|
||||
File: g77.info, Node: Shorthand Options, Next: Fortran Dialect Options, Prev: Overall Options, Up: Invoking G77
|
||||
|
||||
Shorthand Options
|
||||
=================
|
||||
|
||||
The following options serve as "shorthand" for other options
|
||||
accepted by the compiler:
|
||||
|
||||
`-fugly'
|
||||
Specify that certain "ugly" constructs are to be quietly accepted.
|
||||
Same as:
|
||||
|
||||
-fugly-args -fugly-assign -fugly-assumed
|
||||
-fugly-comma -fugly-complex -fugly-init
|
||||
-fugly-logint
|
||||
|
||||
These constructs are considered inappropriate to use in new or
|
||||
well-maintained portable Fortran code, but widely used in old code.
|
||||
*Note Distensions::, for more information.
|
||||
|
||||
*Note:* The `-fugly' option is likely to be removed in a future
|
||||
version. Implicitly enabling all the `-fugly-*' options is
|
||||
unlikely to be feasible, or sensible, in the future, so users
|
||||
should learn to specify only those `-fugly-*' options they really
|
||||
need for a particular source file.
|
||||
|
||||
`-fno-ugly'
|
||||
Specify that all "ugly" constructs are to be noisily rejected.
|
||||
Same as:
|
||||
|
||||
-fno-ugly-args -fno-ugly-assign -fno-ugly-assumed
|
||||
-fno-ugly-comma -fno-ugly-complex -fno-ugly-init
|
||||
-fno-ugly-logint
|
||||
|
||||
*Note Distensions::, for more information.
|
||||
|
||||
`-ff66'
|
||||
Specify that the program is written in idiomatic FORTRAN 66. Same
|
||||
as `-fonetrip -fugly-assumed'.
|
||||
|
||||
The `-fno-f66' option is the inverse of `-ff66'. As such, it is
|
||||
the same as `-fno-onetrip -fno-ugly-assumed'.
|
||||
|
||||
The meaning of this option is likely to be refined as future
|
||||
versions of `g77' provide more compatibility with other existing
|
||||
and obsolete Fortran implementations.
|
||||
|
||||
`-ff77'
|
||||
Specify that the program is written in idiomatic UNIX FORTRAN 77
|
||||
and/or the dialect accepted by the `f2c' product. Same as
|
||||
`-fbackslash -fno-typeless-boz'.
|
||||
|
||||
The meaning of this option is likely to be refined as future
|
||||
versions of `g77' provide more compatibility with other existing
|
||||
and obsolete Fortran implementations.
|
||||
|
||||
`-fno-f77'
|
||||
The `-fno-f77' option is *not* the inverse of `-ff77'. It
|
||||
specifies that the program is not written in idiomatic UNIX
|
||||
FORTRAN 77 or `f2c', but in a more widely portable dialect.
|
||||
`-fno-f77' is the same as `-fno-backslash'.
|
||||
|
||||
The meaning of this option is likely to be refined as future
|
||||
versions of `g77' provide more compatibility with other existing
|
||||
and obsolete Fortran implementations.
|
||||
|
||||
|
||||
File: g77.info, Node: Fortran Dialect Options, Next: Warning Options, Prev: Shorthand Options, Up: Invoking G77
|
||||
|
||||
Options Controlling Fortran Dialect
|
||||
===================================
|
||||
|
||||
The following options control the dialect of Fortran that the
|
||||
compiler accepts:
|
||||
|
||||
`-ffree-form'
|
||||
|
||||
`-fno-fixed-form'
|
||||
Specify that the source file is written in free form (introduced
|
||||
in Fortran 90) instead of the more-traditional fixed form.
|
||||
|
||||
`-ff90'
|
||||
Allow certain Fortran-90 constructs.
|
||||
|
||||
This option controls whether certain Fortran 90 constructs are
|
||||
recognized. (Other Fortran 90 constructs might or might not be
|
||||
recognized depending on other options such as `-fvxt',
|
||||
`-ff90-intrinsics-enable', and the current level of support for
|
||||
Fortran 90.)
|
||||
|
||||
*Note Fortran 90::, for more information.
|
||||
|
||||
`-fvxt'
|
||||
Specify the treatment of certain constructs that have different
|
||||
meanings depending on whether the code is written in GNU Fortran
|
||||
(based on FORTRAN 77 and akin to Fortran 90) or VXT Fortran (more
|
||||
like VAX FORTRAN).
|
||||
|
||||
The default is `-fno-vxt'. `-fvxt' specifies that the VXT Fortran
|
||||
interpretations for those constructs are to be chosen.
|
||||
|
||||
*Note VXT Fortran::, for more information.
|
||||
|
||||
`-fdollar-ok'
|
||||
Allow `$' as a valid character in a symbol name.
|
||||
|
||||
`-fno-backslash'
|
||||
Specify that `\' is not to be specially interpreted in character
|
||||
and Hollerith constants a la C and many UNIX Fortran compilers.
|
||||
|
||||
For example, with `-fbackslash' in effect, `A\nB' specifies three
|
||||
characters, with the second one being newline. With
|
||||
`-fno-backslash', it specifies four characters, `A', `\', `n', and
|
||||
`B'.
|
||||
|
||||
Note that `g77' implements a fairly general form of backslash
|
||||
processing that is incompatible with the narrower forms supported
|
||||
by some other compilers. For example, `'A\003B'' is a
|
||||
three-character string in `g77', whereas other compilers that
|
||||
support backslash might not support the three-octal-digit form,
|
||||
and thus treat that string as longer than three characters.
|
||||
|
||||
*Note Backslash in Constants::, for information on why
|
||||
`-fbackslash' is the default instead of `-fno-backslash'.
|
||||
|
||||
`-fno-ugly-args'
|
||||
Disallow passing Hollerith and typeless constants as actual
|
||||
arguments (for example, `CALL FOO(4HABCD)').
|
||||
|
||||
*Note Ugly Implicit Argument Conversion::, for more information.
|
||||
|
||||
`-fugly-assign'
|
||||
Use the same storage for a given variable regardless of whether it
|
||||
is used to hold an assigned-statement label (as in `ASSIGN 10 TO
|
||||
I') or used to hold numeric data (as in `I = 3').
|
||||
|
||||
*Note Ugly Assigned Labels::, for more information.
|
||||
|
||||
`-fugly-assumed'
|
||||
Assume any dummy array with a final dimension specified as `1' is
|
||||
really an assumed-size array, as if `*' had been specified for the
|
||||
final dimension instead of `1'.
|
||||
|
||||
For example, `DIMENSION X(1)' is treated as if it had read
|
||||
`DIMENSION X(*)'.
|
||||
|
||||
*Note Ugly Assumed-Size Arrays::, for more information.
|
||||
|
||||
`-fugly-comma'
|
||||
Treat a trailing comma in an argument list as specification of a
|
||||
trailing null argument, and treat an empty argument list as
|
||||
specification of a single null argument.
|
||||
|
||||
For example, `CALL FOO(,)' is treated as `CALL FOO(%VAL(0),
|
||||
%VAL(0))'. That is, *two* null arguments are specified by the
|
||||
procedure call when `-fugly-comma' is in force. And `F = FUNC()'
|
||||
is treated as `F = FUNC(%VAL(0))'.
|
||||
|
||||
The default behavior, `-fno-ugly-comma', is to ignore a single
|
||||
trailing comma in an argument list.
|
||||
|
||||
*Note Ugly Null Arguments::, for more information.
|
||||
|
||||
`-fugly-complex'
|
||||
Do not complain about `REAL(EXPR)' or `AIMAG(EXPR)' when EXPR is a
|
||||
`COMPLEX' type other than `COMPLEX(KIND=1)'--usually this is used
|
||||
to permit `COMPLEX(KIND=2)' (`DOUBLE COMPLEX') operands.
|
||||
|
||||
The `-ff90' option controls the interpretation of this construct.
|
||||
|
||||
*Note Ugly Complex Part Extraction::, for more information.
|
||||
|
||||
`-fno-ugly-init'
|
||||
Disallow use of Hollerith and typeless constants as initial values
|
||||
(in `PARAMETER' and `DATA' statements), and use of character
|
||||
constants to initialize numeric types and vice versa.
|
||||
|
||||
For example, `DATA I/'F'/, CHRVAR/65/, J/4HABCD/' is disallowed by
|
||||
`-fno-ugly-init'.
|
||||
|
||||
*Note Ugly Conversion of Initializers::, for more information.
|
||||
|
||||
`-fugly-logint'
|
||||
Treat `INTEGER' and `LOGICAL' variables and expressions as
|
||||
potential stand-ins for each other.
|
||||
|
||||
For example, automatic conversion between `INTEGER' and `LOGICAL'
|
||||
is enabled, for many contexts, via this option.
|
||||
|
||||
*Note Ugly Integer Conversions::, for more information.
|
||||
|
||||
`-fonetrip'
|
||||
Imperative executable `DO' loops are to be executed at least once
|
||||
each time they are reached.
|
||||
|
||||
ANSI FORTRAN 77 and more recent versions of the Fortran standard
|
||||
specify that the body of an imperative `DO' loop is not executed
|
||||
if the number of iterations calculated from the parameters of the
|
||||
loop is less than 1. (For example, `DO 10 I = 1, 0'.) Such a
|
||||
loop is called a "zero-trip loop".
|
||||
|
||||
Prior to ANSI FORTRAN 77, many compilers implemented `DO' loops
|
||||
such that the body of a loop would be executed at least once, even
|
||||
if the iteration count was zero. Fortran code written assuming
|
||||
this behavior is said to require "one-trip loops". For example,
|
||||
some code written to the FORTRAN 66 standard expects this behavior
|
||||
from its `DO' loops, although that standard did not specify this
|
||||
behavior.
|
||||
|
||||
The `-fonetrip' option specifies that the source file(s) being
|
||||
compiled require one-trip loops.
|
||||
|
||||
This option affects only those loops specified by the (imperative)
|
||||
`DO' statement and by implied-`DO' lists in I/O statements. Loops
|
||||
specified by implied-`DO' lists in `DATA' and specification
|
||||
(non-executable) statements are not affected.
|
||||
|
||||
`-ftypeless-boz'
|
||||
Specifies that prefix-radix non-decimal constants, such as
|
||||
`Z'ABCD'', are typeless instead of `INTEGER(KIND=1)'.
|
||||
|
||||
You can test for yourself whether a particular compiler treats the
|
||||
prefix form as `INTEGER(KIND=1)' or typeless by running the
|
||||
following program:
|
||||
|
||||
EQUIVALENCE (I, R)
|
||||
R = Z'ABCD1234'
|
||||
J = Z'ABCD1234'
|
||||
IF (J .EQ. I) PRINT *, 'Prefix form is TYPELESS'
|
||||
IF (J .NE. I) PRINT *, 'Prefix form is INTEGER'
|
||||
END
|
||||
|
||||
Reports indicate that many compilers process this form as
|
||||
`INTEGER(KIND=1)', though a few as typeless, and at least one
|
||||
based on a command-line option specifying some kind of
|
||||
compatibility.
|
||||
|
||||
`-fintrin-case-initcap'
|
||||
|
||||
`-fintrin-case-upper'
|
||||
|
||||
`-fintrin-case-lower'
|
||||
|
||||
`-fintrin-case-any'
|
||||
Specify expected case for intrinsic names. `-fintrin-case-lower'
|
||||
is the default.
|
||||
|
||||
`-fmatch-case-initcap'
|
||||
|
||||
`-fmatch-case-upper'
|
||||
|
||||
`-fmatch-case-lower'
|
||||
|
||||
`-fmatch-case-any'
|
||||
Specify expected case for keywords. `-fmatch-case-lower' is the
|
||||
default.
|
||||
|
||||
`-fsource-case-upper'
|
||||
|
||||
`-fsource-case-lower'
|
||||
|
||||
`-fsource-case-preserve'
|
||||
Specify whether source text other than character and Hollerith
|
||||
constants is to be translated to uppercase, to lowercase, or
|
||||
preserved as is. `-fsource-case-lower' is the default.
|
||||
|
||||
`-fsymbol-case-initcap'
|
||||
|
||||
`-fsymbol-case-upper'
|
||||
|
||||
`-fsymbol-case-lower'
|
||||
|
||||
`-fsymbol-case-any'
|
||||
Specify valid cases for user-defined symbol names.
|
||||
`-fsymbol-case-any' is the default.
|
||||
|
||||
`-fcase-strict-upper'
|
||||
Same as `-fintrin-case-upper -fmatch-case-upper
|
||||
-fsource-case-preserve -fsymbol-case-upper'. (Requires all
|
||||
pertinent source to be in uppercase.)
|
||||
|
||||
`-fcase-strict-lower'
|
||||
Same as `-fintrin-case-lower -fmatch-case-lower
|
||||
-fsource-case-preserve -fsymbol-case-lower'. (Requires all
|
||||
pertinent source to be in lowercase.)
|
||||
|
||||
`-fcase-initcap'
|
||||
Same as `-fintrin-case-initcap -fmatch-case-initcap
|
||||
-fsource-case-preserve -fsymbol-case-initcap'. (Requires all
|
||||
pertinent source to be in initial capitals, as in `Print
|
||||
*,SqRt(Value)'.)
|
||||
|
||||
`-fcase-upper'
|
||||
Same as `-fintrin-case-any -fmatch-case-any -fsource-case-upper
|
||||
-fsymbol-case-any'. (Maps all pertinent source to uppercase.)
|
||||
|
||||
`-fcase-lower'
|
||||
Same as `-fintrin-case-any -fmatch-case-any -fsource-case-lower
|
||||
-fsymbol-case-any'. (Maps all pertinent source to lowercase.)
|
||||
|
||||
`-fcase-preserve'
|
||||
Same as `-fintrin-case-any -fmatch-case-any -fsource-case-preserve
|
||||
-fsymbol-case-any'. (Preserves all case in user-defined symbols,
|
||||
while allowing any-case matching of intrinsics and keywords. For
|
||||
example, `call Foo(i,I)' would pass two *different* variables
|
||||
named `i' and `I' to a procedure named `Foo'.)
|
||||
|
||||
`-ff2c-intrinsics-delete'
|
||||
|
||||
`-ff2c-intrinsics-hide'
|
||||
|
||||
`-ff2c-intrinsics-disable'
|
||||
|
||||
`-ff2c-intrinsics-enable'
|
||||
Specify status of f2c-specific intrinsics.
|
||||
`-ff2c-intrinsics-enable' is the default.
|
||||
|
||||
`-ff90-intrinsics-delete'
|
||||
|
||||
`-ff90-intrinsics-hide'
|
||||
|
||||
`-ff90-intrinsics-disable'
|
||||
|
||||
`-ff90-intrinsics-enable'
|
||||
Specify status of F90-specific intrinsics.
|
||||
`-ff90-intrinsics-enable' is the default.
|
||||
|
||||
`-fgnu-intrinsics-delete'
|
||||
|
||||
`-fgnu-intrinsics-hide'
|
||||
|
||||
`-fgnu-intrinsics-disable'
|
||||
|
||||
`-fgnu-intrinsics-enable'
|
||||
Specify status of Digital's COMPLEX-related intrinsics.
|
||||
`-fgnu-intrinsics-enable' is the default.
|
||||
|
||||
`-fmil-intrinsics-delete'
|
||||
|
||||
`-fmil-intrinsics-hide'
|
||||
|
||||
`-fmil-intrinsics-disable'
|
||||
|
||||
`-fmil-intrinsics-enable'
|
||||
Specify status of MIL-STD-1753-specific intrinsics.
|
||||
`-fmil-intrinsics-enable' is the default.
|
||||
|
||||
`-funix-intrinsics-delete'
|
||||
|
||||
`-funix-intrinsics-hide'
|
||||
|
||||
`-funix-intrinsics-disable'
|
||||
|
||||
`-funix-intrinsics-enable'
|
||||
Specify status of UNIX intrinsics. `-funix-intrinsics-enable' is
|
||||
the default.
|
||||
|
||||
`-fvxt-intrinsics-delete'
|
||||
|
||||
`-fvxt-intrinsics-hide'
|
||||
|
||||
`-fvxt-intrinsics-disable'
|
||||
|
||||
`-fvxt-intrinsics-enable'
|
||||
Specify status of VXT intrinsics. `-fvxt-intrinsics-enable' is
|
||||
the default.
|
||||
|
||||
`-ffixed-line-length-N'
|
||||
Set column after which characters are ignored in typical fixed-form
|
||||
lines in the source file, and through which spaces are assumed (as
|
||||
if padded to that length) after the ends of short fixed-form lines.
|
||||
|
||||
Popular values for N include 72 (the standard and the default), 80
|
||||
(card image), and 132 (corresponds to "extended-source" options in
|
||||
some popular compilers). N may be `none', meaning that the entire
|
||||
line is meaningful and that continued character constants never
|
||||
have implicit spaces appended to them to fill out the line.
|
||||
`-ffixed-line-length-0' means the same thing as
|
||||
`-ffixed-line-length-none'.
|
||||
|
||||
*Note Source Form::, for more information.
|
||||
|
||||
|
||||
File: g77.info, Node: Warning Options, Next: Debugging Options, Prev: Fortran Dialect Options, Up: Invoking G77
|
||||
|
||||
Options to Request or Suppress Warnings
|
||||
=======================================
|
||||
|
||||
Warnings are diagnostic messages that report constructions which are
|
||||
not inherently erroneous but which are risky or suggest there might
|
||||
have been an error.
|
||||
|
||||
You can request many specific warnings with options beginning `-W',
|
||||
for example `-Wimplicit' to request warnings on implicit declarations.
|
||||
Each of these specific warning options also has a negative form
|
||||
beginning `-Wno-' to turn off warnings; for example, `-Wno-implicit'.
|
||||
This manual lists only one of the two forms, whichever is not the
|
||||
default.
|
||||
|
||||
These options control the amount and kinds of warnings produced by
|
||||
GNU Fortran:
|
||||
|
||||
`-fsyntax-only'
|
||||
Check the code for syntax errors, but don't do anything beyond
|
||||
that.
|
||||
|
||||
`-pedantic'
|
||||
Issue warnings for uses of extensions to ANSI FORTRAN 77.
|
||||
`-pedantic' also applies to C-language constructs where they occur
|
||||
in GNU Fortran source files, such as use of `\e' in a character
|
||||
constant within a directive like `#include'.
|
||||
|
||||
Valid ANSI FORTRAN 77 programs should compile properly with or
|
||||
without this option. However, without this option, certain GNU
|
||||
extensions and traditional Fortran features are supported as well.
|
||||
With this option, many of them are rejected.
|
||||
|
||||
Some users try to use `-pedantic' to check programs for strict ANSI
|
||||
conformance. They soon find that it does not do quite what they
|
||||
want--it finds some non-ANSI practices, but not all. However,
|
||||
improvements to `g77' in this area are welcome.
|
||||
|
||||
`-pedantic-errors'
|
||||
Like `-pedantic', except that errors are produced rather than
|
||||
warnings.
|
||||
|
||||
`-fpedantic'
|
||||
Like `-pedantic', but applies only to Fortran constructs.
|
||||
|
||||
`-w'
|
||||
Inhibit all warning messages.
|
||||
|
||||
`-Wno-globals'
|
||||
Inhibit warnings about use of a name as both a global name (a
|
||||
subroutine, function, or block data program unit, or a common
|
||||
block) and implicitly as the name of an intrinsic in a source file.
|
||||
|
||||
Also inhibit warnings about inconsistent invocations and/or
|
||||
definitions of global procedures (function and subroutines). Such
|
||||
inconsistencies include different numbers of arguments and
|
||||
different types of arguments.
|
||||
|
||||
`-Wimplicit'
|
||||
Warn whenever a variable, array, or function is implicitly
|
||||
declared. Has an effect similar to using the `IMPLICIT NONE'
|
||||
statement in every program unit. (Some Fortran compilers provide
|
||||
this feature by an option named `-u' or `/WARNINGS=DECLARATIONS'.)
|
||||
|
||||
`-Wunused'
|
||||
Warn whenever a variable is unused aside from its declaration.
|
||||
|
||||
`-Wuninitialized'
|
||||
Warn whenever an automatic variable is used without first being
|
||||
initialized.
|
||||
|
||||
These warnings are possible only in optimizing compilation,
|
||||
because they require data-flow information that is computed only
|
||||
when optimizing. If you don't specify `-O', you simply won't get
|
||||
these warnings.
|
||||
|
||||
These warnings occur only for variables that are candidates for
|
||||
register allocation. Therefore, they do not occur for a variable
|
||||
whose address is taken, or whose size is other than 1, 2, 4 or 8
|
||||
bytes. Also, they do not occur for arrays, even when they are in
|
||||
registers.
|
||||
|
||||
Note that there might be no warning about a variable that is used
|
||||
only to compute a value that itself is never used, because such
|
||||
computations may be deleted by data-flow analysis before the
|
||||
warnings are printed.
|
||||
|
||||
These warnings are made optional because GNU Fortran is not smart
|
||||
enough to see all the reasons why the code might be correct
|
||||
despite appearing to have an error. Here is one example of how
|
||||
this can happen:
|
||||
|
||||
SUBROUTINE DISPAT(J)
|
||||
IF (J.EQ.1) I=1
|
||||
IF (J.EQ.2) I=4
|
||||
IF (J.EQ.3) I=5
|
||||
CALL FOO(I)
|
||||
END
|
||||
|
||||
If the value of `J' is always 1, 2 or 3, then `I' is always
|
||||
initialized, but GNU Fortran doesn't know this. Here is another
|
||||
common case:
|
||||
|
||||
SUBROUTINE MAYBE(FLAG)
|
||||
LOGICAL FLAG
|
||||
IF (FLAG) VALUE = 9.4
|
||||
...
|
||||
IF (FLAG) PRINT *, VALUE
|
||||
END
|
||||
|
||||
This has no bug because `VALUE' is used only if it is set.
|
||||
|
||||
`-Wall'
|
||||
The `-Wunused' and `-Wuninitialized' options combined. These are
|
||||
all the options which pertain to usage that we recommend avoiding
|
||||
and that we believe is easy to avoid. (As more warnings are added
|
||||
to `g77', some might be added to the list enabled by `-Wall'.)
|
||||
|
||||
The remaining `-W...' options are not implied by `-Wall' because
|
||||
they warn about constructions that we consider reasonable to use, on
|
||||
occasion, in clean programs.
|
||||
|
||||
`-Wsurprising'
|
||||
Warn about "suspicious" constructs that are interpreted by the
|
||||
compiler in a way that might well be surprising to someone reading
|
||||
the code. These differences can result in subtle,
|
||||
compiler-dependent (even machine-dependent) behavioral differences.
|
||||
The constructs warned about include:
|
||||
|
||||
* Expressions having two arithmetic operators in a row, such as
|
||||
`X*-Y'. Such a construct is nonstandard, and can produce
|
||||
unexpected results in more complicated situations such as
|
||||
`X**-Y*Z'. `g77', along with many other compilers, interprets
|
||||
this example differently than many programmers, and a few
|
||||
other compilers. Specifically, `g77' interprets `X**-Y*Z' as
|
||||
`(X**(-Y))*Z', while others might think it should be
|
||||
interpreted as `X**(-(Y*Z))'.
|
||||
|
||||
A revealing example is the constant expression `2**-2*1.',
|
||||
which `g77' evaluates to .25, while others might evaluate it
|
||||
to 0., the difference resulting from the way precedence
|
||||
affects type promotion.
|
||||
|
||||
(The `-fpedantic' option also warns about expressions having
|
||||
two arithmetic operators in a row.)
|
||||
|
||||
* Expressions with a unary minus followed by an operand and then
|
||||
a binary operator other than plus or minus. For example,
|
||||
`-2**2' produces a warning, because the precedence is
|
||||
`-(2**2)', yielding -4, not `(-2)**2', which yields 4, and
|
||||
which might represent what a programmer expects.
|
||||
|
||||
An example of an expression producing different results in a
|
||||
surprising way is `-I*S', where I holds the value
|
||||
`-2147483648' and S holds `0.5'. On many systems, negating I
|
||||
results in the same value, not a positive number, because it
|
||||
is already the lower bound of what an `INTEGER(KIND=1)'
|
||||
variable can hold. So, the expression evaluates to a
|
||||
positive number, while the "expected" interpretation,
|
||||
`(-I)*S', would evaluate to a negative number.
|
||||
|
||||
Even cases such as `-I*J' produce warnings, even though, in
|
||||
most configurations and situations, there is no computational
|
||||
difference between the results of the two
|
||||
interpretations--the purpose of this warning is to warn about
|
||||
differing interpretations and encourage a better style of
|
||||
coding, not to identify only those places where bugs might
|
||||
exist in the user's code.
|
||||
|
||||
* `DO' loops with `DO' variables that are not of integral
|
||||
type--that is, using `REAL' variables as loop control
|
||||
variables. Although such loops can be written to work in the
|
||||
"obvious" way, the way `g77' is required by the Fortran
|
||||
standard to interpret such code is likely to be quite
|
||||
different from the way many programmers expect. (This is
|
||||
true of all `DO' loops, but the differences are pronounced
|
||||
for non-integral loop control variables.)
|
||||
|
||||
*Note Loops::, for more information.
|
||||
|
||||
`-Werror'
|
||||
Make all warnings into errors.
|
||||
|
||||
`-W'
|
||||
Turns on "extra warnings" and, if optimization is specified via
|
||||
`-O', the `-Wuninitialized' option. (This might change in future
|
||||
versions of `g77'.)
|
||||
|
||||
"Extra warnings" are issued for:
|
||||
|
||||
* Unused parameters to a procedure (when `-Wunused' also is
|
||||
specified).
|
||||
|
||||
* Overflows involving floating-point constants (not available
|
||||
for certain configurations).
|
||||
|
||||
*Note Options to Request or Suppress Warnings: (gcc)Warning Options,
|
||||
for information on more options offered by the GBE shared by `g77',
|
||||
`gcc', and other GNU compilers.
|
||||
|
||||
Some of these have no effect when compiling programs written in
|
||||
Fortran:
|
||||
|
||||
`-Wcomment'
|
||||
|
||||
`-Wformat'
|
||||
|
||||
`-Wparentheses'
|
||||
|
||||
`-Wswitch'
|
||||
|
||||
`-Wtraditional'
|
||||
|
||||
`-Wshadow'
|
||||
|
||||
`-Wid-clash-LEN'
|
||||
|
||||
`-Wlarger-than-LEN'
|
||||
|
||||
`-Wconversion'
|
||||
|
||||
`-Waggregate-return'
|
||||
|
||||
`-Wredundant-decls'
|
||||
These options all could have some relevant meaning for GNU Fortran
|
||||
programs, but are not yet supported.
|
||||
|
||||
|
||||
File: g77.info, Node: Debugging Options, Next: Optimize Options, Prev: Warning Options, Up: Invoking G77
|
||||
|
||||
Options for Debugging Your Program or GNU Fortran
|
||||
=================================================
|
||||
|
||||
GNU Fortran has various special options that are used for debugging
|
||||
either your program or `g77'.
|
||||
|
||||
`-g'
|
||||
Produce debugging information in the operating system's native
|
||||
format (stabs, COFF, XCOFF, or DWARF). GDB can work with this
|
||||
debugging information.
|
||||
|
||||
Support for this option in Fortran programs is incomplete. In
|
||||
particular, names of variables and arrays in common blocks or that
|
||||
are storage-associated via `EQUIVALENCE' are unavailable to the
|
||||
debugger.
|
||||
|
||||
However, version 0.5.19 of `g77' does provide this information in
|
||||
a rudimentary way, as controlled by the `-fdebug-kludge' option.
|
||||
|
||||
*Note Options for Code Generation Conventions: Code Gen Options,
|
||||
for more information.
|
||||
|
||||
*Note Options for Debugging Your Program or GNU CC: (gcc)Debugging
|
||||
Options, for more information on debugging options.
|
||||
|
||||
|
||||
File: g77.info, Node: Optimize Options, Next: Preprocessor Options, Prev: Debugging Options, Up: Invoking G77
|
||||
|
||||
Options That Control Optimization
|
||||
=================================
|
||||
|
||||
Most Fortran users will want to use no optimization when developing
|
||||
and testing programs, and use `-O' or `-O2' when compiling programs for
|
||||
late-cycle testing and for production use.
|
||||
|
||||
The following flags have particular applicability when compiling
|
||||
Fortran programs:
|
||||
|
||||
`-malign-double'
|
||||
(Intel 386 architecture only.)
|
||||
|
||||
Noticeably improves performance of `g77' programs making heavy use
|
||||
of `REAL(KIND=2)' (`DOUBLE PRECISION') data on some systems. In
|
||||
particular, systems using Pentium, Pentium Pro, 586, and 686
|
||||
implementations of the i386 architecture execute programs faster
|
||||
when `REAL(KIND=2)' (`DOUBLE PRECISION') data are aligned on
|
||||
64-bit boundaries in memory.
|
||||
|
||||
This option can, at least, make benchmark results more consistent
|
||||
across various system configurations, versions of the program, and
|
||||
data sets.
|
||||
|
||||
*Note:* The warning in the `gcc' documentation about this option
|
||||
does not apply, generally speaking, to Fortran code compiled by
|
||||
`g77'.
|
||||
|
||||
*Also note:* `g77' fixes a `gcc' backend bug to allow
|
||||
`-malign-double' to work generally, not just with
|
||||
statically-allocated data.
|
||||
|
||||
*Also also note:* The negative form of `-malign-double' is
|
||||
`-mno-align-double', not `-benign-double'.
|
||||
|
||||
`-ffloat-store'
|
||||
Might help a Fortran program that depends on exact IEEE conformance
|
||||
on some machines, but might slow down a program that doesn't.
|
||||
|
||||
`-fforce-mem'
|
||||
|
||||
`-fforce-addr'
|
||||
Might improve optimization of loops.
|
||||
|
||||
`-fno-inline'
|
||||
Don't compile statement functions inline. Might reduce the size
|
||||
of a program unit--which might be at expense of some speed (though
|
||||
it should compile faster). Note that if you are not optimizing,
|
||||
no functions can be expanded inline.
|
||||
|
||||
`-ffast-math'
|
||||
Might allow some programs designed to not be too dependent on IEEE
|
||||
behavior for floating-point to run faster, or die trying.
|
||||
|
||||
`-fstrength-reduce'
|
||||
Might make some loops run faster.
|
||||
|
||||
`-frerun-cse-after-loop'
|
||||
|
||||
`-fexpensive-optimizations'
|
||||
|
||||
`-fdelayed-branch'
|
||||
|
||||
`-fschedule-insns'
|
||||
|
||||
`-fschedule-insns2'
|
||||
|
||||
`-fcaller-saves'
|
||||
Might improve performance on some code.
|
||||
|
||||
`-funroll-loops'
|
||||
Definitely improves performance on some code.
|
||||
|
||||
`-funroll-all-loops'
|
||||
Definitely improves performance on some code.
|
||||
|
||||
`-fno-move-all-movables'
|
||||
|
||||
`-fno-reduce-all-givs'
|
||||
|
||||
`-fno-rerun-loop-opt'
|
||||
Each of these might improve performance on some code.
|
||||
|
||||
Analysis of Fortran code optimization and the resulting
|
||||
optimizations triggered by the above options were contributed by
|
||||
Toon Moene (<toon@moene.indiv.nluug.nl>).
|
||||
|
||||
These three options are intended to be removed someday, once they
|
||||
have helped determine the efficacy of various approaches to
|
||||
improving the performance of Fortran code.
|
||||
|
||||
Please let us know how use of these options affects the
|
||||
performance of your production code. We're particularly
|
||||
interested in code that runs faster when these options are
|
||||
*disabled*, and in non-Fortran code that benefits when they are
|
||||
*enabled* via the above `gcc' command-line options.
|
||||
|
||||
*Note Options That Control Optimization: (gcc)Optimize Options, for
|
||||
more information on options to optimize the generated machine code.
|
||||
|
||||
|
||||
File: g77.info, Node: Preprocessor Options, Next: Directory Options, Prev: Optimize Options, Up: Invoking G77
|
||||
|
||||
Options Controlling the Preprocessor
|
||||
====================================
|
||||
|
||||
These options control the C preprocessor, which is run on each C
|
||||
source file before actual compilation.
|
||||
|
||||
*Note Options Controlling the Preprocessor: (gcc)Preprocessor
|
||||
Options, for information on C preprocessor options.
|
||||
|
||||
Some of these options also affect how `g77' processes the `INCLUDE'
|
||||
directive. Since this directive is processed even when preprocessing
|
||||
is not requested, it is not described in this section. *Note Options
|
||||
for Directory Search: Directory Options, for information on how `g77'
|
||||
processes the `INCLUDE' directive.
|
||||
|
||||
However, the `INCLUDE' directive does not apply preprocessing to the
|
||||
contents of the included file itself.
|
||||
|
||||
Therefore, any file that contains preprocessor directives (such as
|
||||
`#include', `#define', and `#if') must be included via the `#include'
|
||||
directive, not via the `INCLUDE' directive. Therefore, any file
|
||||
containing preprocessor directives, if included, is necessarily
|
||||
included by a file that itself contains preprocessor directives.
|
||||
|
||||
|
||||
File: g77.info, Node: Directory Options, Next: Code Gen Options, Prev: Preprocessor Options, Up: Invoking G77
|
||||
|
||||
Options for Directory Search
|
||||
============================
|
||||
|
||||
These options affect how the `cpp' preprocessor searches for files
|
||||
specified via the `#include' directive. Therefore, when compiling
|
||||
Fortran programs, they are meaningful when the preproecssor is used.
|
||||
|
||||
Some of these options also affect how `g77' searches for files
|
||||
specified via the `INCLUDE' directive, although files included by that
|
||||
directive are not, themselves, preprocessed. These options are:
|
||||
|
||||
`-I-'
|
||||
|
||||
`-IDIR'
|
||||
These affect interpretation of the `INCLUDE' directive (as well as
|
||||
of the `#include' directive of the `cpp' preprocessor).
|
||||
|
||||
Note that `-IDIR' must be specified *without* any spaces between
|
||||
`-I' and the directory name--that is, `-Ifoo/bar' is valid, but
|
||||
`-I foo/bar' is rejected by the `g77' compiler (though the
|
||||
preprocessor supports the latter form). Also note that the
|
||||
general behavior of `-I' and `INCLUDE' is pretty much the same as
|
||||
of `-I' with `#include' in the `cpp' preprocessor, with regard to
|
||||
looking for `header.gcc' files and other such things.
|
||||
|
||||
*Note Options for Directory Search: (gcc)Directory Options, for
|
||||
information on the `-I' option.
|
||||
|
2122
gcc/f/g77.info-20
2122
gcc/f/g77.info-20
File diff suppressed because it is too large
Load Diff
397
gcc/f/g77.info-3
397
gcc/f/g77.info-3
@ -1,397 +0,0 @@
|
||||
This is Info file g77.info, produced by Makeinfo version 1.68 from the
|
||||
input file g77.texi.
|
||||
|
||||
This file explains how to use the GNU Fortran system.
|
||||
|
||||
Published by the Free Software Foundation 59 Temple Place - Suite 330
|
||||
Boston, MA 02111-1307 USA
|
||||
|
||||
Copyright (C) 1995-1997 Free Software Foundation, Inc.
|
||||
|
||||
Permission is granted to make and distribute verbatim copies of this
|
||||
manual provided the copyright notice and this permission notice are
|
||||
preserved on all copies.
|
||||
|
||||
Permission is granted to copy and distribute modified versions of
|
||||
this manual under the conditions for verbatim copying, provided also
|
||||
that the sections entitled "GNU General Public License," "Funding for
|
||||
Free Software," and "Protect Your Freedom--Fight `Look And Feel'" are
|
||||
included exactly as in the original, and provided that the entire
|
||||
resulting derived work is distributed under the terms of a permission
|
||||
notice identical to this one.
|
||||
|
||||
Permission is granted to copy and distribute translations of this
|
||||
manual into another language, under the above conditions for modified
|
||||
versions, except that the sections entitled "GNU General Public
|
||||
License," "Funding for Free Software," and "Protect Your Freedom--Fight
|
||||
`Look And Feel'", and this permission notice, may be included in
|
||||
translations approved by the Free Software Foundation instead of in the
|
||||
original English.
|
||||
|
||||
Contributed by James Craig Burley (<burley@gnu.ai.mit.edu>).
|
||||
Inspired by a first pass at translating `g77-0.5.16/f/DOC' that was
|
||||
contributed to Craig by David Ronis (<ronis@onsager.chem.mcgill.ca>).
|
||||
|
||||
INFO-DIR-SECTION Fortran Programming
|
||||
START-INFO-DIR-ENTRY
|
||||
* g77: (g77). The GNU Fortran compilation system.
|
||||
END-INFO-DIR-ENTRY
|
||||
|
||||
|
||||
File: g77.info, Node: Code Gen Options, Next: Environment Variables, Prev: Directory Options, Up: Invoking G77
|
||||
|
||||
Options for Code Generation Conventions
|
||||
=======================================
|
||||
|
||||
These machine-independent options control the interface conventions
|
||||
used in code generation.
|
||||
|
||||
Most of them have both positive and negative forms; the negative form
|
||||
of `-ffoo' would be `-fno-foo'. In the table below, only one of the
|
||||
forms is listed--the one which is not the default. You can figure out
|
||||
the other form by either removing `no-' or adding it.
|
||||
|
||||
`-fno-automatic'
|
||||
Treat each program unit as if the `SAVE' statement was specified
|
||||
for every local variable and array referenced in it. Does not
|
||||
affect common blocks. (Some Fortran compilers provide this option
|
||||
under the name `-static'.)
|
||||
|
||||
`-finit-local-zero'
|
||||
Specify that variables and arrays that are local to a program unit
|
||||
(not in a common block and not passed as an argument) are to be
|
||||
initialized to binary zeros.
|
||||
|
||||
Since there is a run-time penalty for initialization of variables
|
||||
that are not given the `SAVE' attribute, it might be a good idea
|
||||
to also use `-fno-automatic' with `-finit-local-zero'.
|
||||
|
||||
`-fno-f2c'
|
||||
Do not generate code designed to be compatible with code generated
|
||||
by `f2c'; use the GNU calling conventions instead.
|
||||
|
||||
The `f2c' calling conventions require functions that return type
|
||||
`REAL(KIND=1)' to actually return the C type `double', and
|
||||
functions that return type `COMPLEX' to return the values via an
|
||||
extra argument in the calling sequence that points to where to
|
||||
store the return value. Under the GNU calling conventions, such
|
||||
functions simply return their results as they would in GNU
|
||||
C--`REAL(KIND=1)' functions return the C type `float', and
|
||||
`COMPLEX' functions return the GNU C type `complex' (or its
|
||||
`struct' equivalent).
|
||||
|
||||
This does not affect the generation of code that interfaces with
|
||||
the `libf2c' library.
|
||||
|
||||
However, because the `libf2c' library uses `f2c' calling
|
||||
conventions, `g77' rejects attempts to pass intrinsics implemented
|
||||
by routines in this library as actual arguments when `-fno-f2c' is
|
||||
used, to avoid bugs when they are actually called by code
|
||||
expecting the GNU calling conventions to work.
|
||||
|
||||
For example, `INTRINSIC ABS;CALL FOO(ABS)' is rejected when
|
||||
`-fno-f2c' is in force. (Future versions of the `g77' run-time
|
||||
library might offer routines that provide GNU-callable versions of
|
||||
the routines that implement the `f2c'-callable intrinsics that may
|
||||
be passed as actual arguments, so that valid programs need not be
|
||||
rejected when `-fno-f2c' is used.)
|
||||
|
||||
*Caution:* If `-fno-f2c' is used when compiling any source file
|
||||
used in a program, it must be used when compiling *all* Fortran
|
||||
source files used in that program.
|
||||
|
||||
`-ff2c-library'
|
||||
Specify that use of `libf2c' is required. This is the default for
|
||||
the current version of `g77'.
|
||||
|
||||
Currently it is not valid to specify `-fno-f2c-library'. This
|
||||
option is provided so users can specify it in shell scripts that
|
||||
build programs and libraries that require the `libf2c' library,
|
||||
even when being compiled by future versions of `g77' that might
|
||||
otherwise default to generating code for an incompatible library.
|
||||
|
||||
`-fno-underscoring'
|
||||
Do not transform names of entities specified in the Fortran source
|
||||
file by appending underscores to them.
|
||||
|
||||
With `-funderscoring' in effect, `g77' appends two underscores to
|
||||
names with underscores and one underscore to external names with
|
||||
no underscores. (`g77' also appends two underscores to internal
|
||||
names with underscores to avoid naming collisions with external
|
||||
names. The `-fno-second-underscore' option disables appending of
|
||||
the second underscore in all cases.)
|
||||
|
||||
This is done to ensure compatibility with code produced by many
|
||||
UNIX Fortran compilers, including `f2c', which perform the same
|
||||
transformations.
|
||||
|
||||
Use of `-fno-underscoring' is not recommended unless you are
|
||||
experimenting with issues such as integration of (GNU) Fortran into
|
||||
existing system environments (vis-a-vis existing libraries, tools,
|
||||
and so on).
|
||||
|
||||
For example, with `-funderscoring', and assuming other defaults
|
||||
like `-fcase-lower' and that `j()' and `max_count()' are external
|
||||
functions while `my_var' and `lvar' are local variables, a
|
||||
statement like
|
||||
|
||||
I = J() + MAX_COUNT (MY_VAR, LVAR)
|
||||
|
||||
is implemented as something akin to:
|
||||
|
||||
i = j_() + max_count__(&my_var__, &lvar);
|
||||
|
||||
With `-fno-underscoring', the same statement is implemented as:
|
||||
|
||||
i = j() + max_count(&my_var, &lvar);
|
||||
|
||||
Use of `-fno-underscoring' allows direct specification of
|
||||
user-defined names while debugging and when interfacing
|
||||
`g77'-compiled code with other languages.
|
||||
|
||||
Note that just because the names match does *not* mean that the
|
||||
interface implemented by `g77' for an external name matches the
|
||||
interface implemented by some other language for that same name.
|
||||
That is, getting code produced by `g77' to link to code produced
|
||||
by some other compiler using this or any other method can be only a
|
||||
small part of the overall solution--getting the code generated by
|
||||
both compilers to agree on issues other than naming can require
|
||||
significant effort, and, unlike naming disagreements, linkers
|
||||
normally cannot detect disagreements in these other areas.
|
||||
|
||||
Also, note that with `-fno-underscoring', the lack of appended
|
||||
underscores introduces the very real possibility that a
|
||||
user-defined external name will conflict with a name in a system
|
||||
library, which could make finding unresolved-reference bugs quite
|
||||
difficult in some cases--they might occur at program run time, and
|
||||
show up only as buggy behavior at run time.
|
||||
|
||||
In future versions of `g77', we hope to improve naming and linking
|
||||
issues so that debugging always involves using the names as they
|
||||
appear in the source, even if the names as seen by the linker are
|
||||
mangled to prevent accidental linking between procedures with
|
||||
incompatible interfaces.
|
||||
|
||||
`-fno-second-underscore'
|
||||
Do not append a second underscore to names of entities specified
|
||||
in the Fortran source file.
|
||||
|
||||
This option has no effect if `-fno-underscoring' is in effect.
|
||||
|
||||
Otherwise, with this option, an external name such as `MAX_COUNT'
|
||||
is implemented as a reference to the link-time external symbol
|
||||
`max_count_', instead of `max_count__'.
|
||||
|
||||
`-fno-ident'
|
||||
Ignore the `#ident' directive.
|
||||
|
||||
`-fzeros'
|
||||
Treat initial values of zero as if they were any other value.
|
||||
|
||||
As of version 0.5.18, `g77' normally treats `DATA' and other
|
||||
statements that are used to specify initial values of zero for
|
||||
variables and arrays as if no values were actually specified, in
|
||||
the sense that no diagnostics regarding multiple initializations
|
||||
are produced.
|
||||
|
||||
This is done to speed up compiling of programs that initialize
|
||||
large arrays to zeros.
|
||||
|
||||
Use `-fzeros' to revert to the simpler, slower behavior that can
|
||||
catch multiple initializations by keeping track of all
|
||||
initializations, zero or otherwise.
|
||||
|
||||
*Caution:* Future versions of `g77' might disregard this option
|
||||
(and its negative form, the default) or interpret it somewhat
|
||||
differently. The interpretation changes will affect only
|
||||
non-standard programs; standard-conforming programs should not be
|
||||
affected.
|
||||
|
||||
`-fdebug-kludge'
|
||||
Emit information on `COMMON' and `EQUIVALENCE' members that might
|
||||
help users of debuggers work around lack of proper debugging
|
||||
information on such members.
|
||||
|
||||
As of version 0.5.19, `g77' offers this option to emit information
|
||||
on members of aggregate areas to help users while debugging. This
|
||||
information consists of establishing the type and contents of each
|
||||
such member so that, when a debugger is asked to print the
|
||||
contents, the printed information provides rudimentary debugging
|
||||
information. This information identifies the name of the
|
||||
aggregate area (either the `COMMON' block name, or the
|
||||
`g77'-assigned name for the `EQUIVALENCE' name) and the offset, in
|
||||
bytes, of the member from the beginning of the area.
|
||||
|
||||
Using `gdb', this information is not coherently displayed in the
|
||||
Fortran language mode, so temporarily switching to the C language
|
||||
mode to display the information is suggested. Use `set language
|
||||
c' and `set language fortran' to accomplish this.
|
||||
|
||||
For example:
|
||||
|
||||
COMMON /X/A,B
|
||||
EQUIVALENCE (C,D)
|
||||
CHARACTER XX*50
|
||||
EQUIVALENCE (I,XX(20:20))
|
||||
END
|
||||
|
||||
GDB is free software and you are welcome to distribute copies of it
|
||||
under certain conditions; type "show copying" to see the conditions.
|
||||
There is absolutely no warranty for GDB; type "show warranty" for details.
|
||||
GDB 4.16 (lm-gnits-dwim), Copyright 1996 Free Software Foundation, Inc...
|
||||
(gdb) b MAIN__
|
||||
Breakpoint 1 at 0t1200000201120112: file cd.f, line 5.
|
||||
(gdb) r
|
||||
Starting program: /home/user/a.out
|
||||
|
||||
Breakpoint 1, MAIN__ () at cd.f:5
|
||||
Current language: auto; currently fortran
|
||||
(gdb) set language c
|
||||
Warning: the current language does not match this frame.
|
||||
(gdb) p a
|
||||
$2 = "At (COMMON) `x_' plus 0 bytes"
|
||||
(gdb) p b
|
||||
$3 = "At (COMMON) `x_' plus 4 bytes"
|
||||
(gdb) p c
|
||||
$4 = "At (EQUIVALENCE) `__g77_equiv_c' plus 0 bytes"
|
||||
(gdb) p d
|
||||
$5 = "At (EQUIVALENCE) `__g77_equiv_c' plus 0 bytes"
|
||||
(gdb) p i
|
||||
$6 = "At (EQUIVALENCE) `__g77_equiv_xx' plus 20 bytes"
|
||||
(gdb) p xx
|
||||
$7 = "At (EQUIVALENCE) `__g77_equiv_xx' plus 1 bytes"
|
||||
(gdb) set language fortran
|
||||
(gdb)
|
||||
|
||||
Use `-fdebug-kludge' to generate this information, which might
|
||||
make some programs noticeably larger.
|
||||
|
||||
*Caution:* Future versions of `g77' might disregard this option
|
||||
(and its negative form). Current plans call for this to happen
|
||||
when published versions of `g77' and `gdb' exist that provide
|
||||
proper access to debugging information on `COMMON' and
|
||||
`EQUIVALENCE' members.
|
||||
|
||||
`-fno-emulate-complex'
|
||||
Implement `COMPLEX' arithmetic using the facilities in the `gcc'
|
||||
back end that provide direct support of `complex' arithmetic,
|
||||
instead of emulating the arithmetic.
|
||||
|
||||
`gcc' has some known problems in its back-end support for
|
||||
`complex' arithmetic, due primarily to the support not being
|
||||
completed as of version 2.7.2.2. Other front ends for the `gcc'
|
||||
back end avoid this problem by emulating `complex' arithmetic at a
|
||||
higher level, so the back end sees arithmetic on the real and
|
||||
imaginary components. To make `g77' more portable to systems
|
||||
where `complex' support in the `gcc' back end is particularly
|
||||
troublesome, `g77' now defaults to performing the same kinds of
|
||||
emulations done by these other front ends.
|
||||
|
||||
Use `-fno-emulate-complex' to try the `complex' support in the
|
||||
`gcc' back end, in case it works and produces faster programs. So
|
||||
far, all the known bugs seem to involve compile-time crashes,
|
||||
rather than the generation of incorrect code.
|
||||
|
||||
Use of this option should not affect how Fortran code compiled by
|
||||
`g77' works in terms of its interfaces to other code, e.g. that
|
||||
compiled by `f2c'.
|
||||
|
||||
*Caution:* Future versions of `g77' are likely to change the
|
||||
default for this option to `-fno-emulate-complex', and perhaps
|
||||
someday ignore both forms of this option.
|
||||
|
||||
Also, it is possible that use of the `-fno-emulate-complex' option
|
||||
could result in incorrect code being silently produced by `g77'.
|
||||
But, this is generally true of compilers anyway, so, as usual, test
|
||||
the programs you compile before assuming they are working.
|
||||
|
||||
`-falias-check'
|
||||
|
||||
`-fargument-alias'
|
||||
|
||||
`-fargument-noalias'
|
||||
|
||||
`-fno-argument-noalias-global'
|
||||
These options specify to what degree aliasing (overlap) is
|
||||
permitted between arguments (passed as pointers) and `COMMON'
|
||||
(external, or public) storage.
|
||||
|
||||
The default for Fortran code, as mandated by the FORTRAN 77 and
|
||||
Fortran 90 standards, is `-fargument-noalias-global'. The default
|
||||
for code written in the C language family is `-fargument-alias'.
|
||||
|
||||
Note that, on some systems, compiling with `-fforce-addr' in
|
||||
effect can produce more optimal code when the default aliasing
|
||||
options are in effect (and when optimization is enabled).
|
||||
|
||||
*Note Aliasing Assumed To Work::, for detailed information on the
|
||||
implications of compiling Fortran code that depends on the ability
|
||||
to alias dummy arguments.
|
||||
|
||||
`-fno-globals'
|
||||
Disable diagnostics about inter-procedural analysis problems, such
|
||||
as disagreements about the type of a function or a procedure's
|
||||
argument, that might cause a compiler crash when attempting to
|
||||
inline a reference to a procedure within a program unit. (The
|
||||
diagnostics themselves are still produced, but as warnings, unless
|
||||
`-Wno-globals' is specified, in which case no relevant diagnostics
|
||||
are produced.)
|
||||
|
||||
Further, this option disables such inlining, to avoid compiler
|
||||
crashes resulting from incorrect code that would otherwise be
|
||||
diagnosed.
|
||||
|
||||
As such, this option might be quite useful when compiling
|
||||
existing, "working" code that happens to have a few bugs that do
|
||||
not generally show themselves, but `g77' exposes via a diagnostic.
|
||||
|
||||
Use of this option therefore has the effect of instructing `g77'
|
||||
to behave more like it did up through version 0.5.19.1, when it
|
||||
paid little or no attention to disagreements between program units
|
||||
about a procedure's type and argument information, and when it
|
||||
performed no inlining of procedures (except statement functions).
|
||||
|
||||
Without this option, `g77' defaults to performing the potentially
|
||||
inlining procedures as it started doing in version 0.5.20, but as
|
||||
of version 0.5.21, it also diagnoses disagreements that might
|
||||
cause such inlining to crash the compiler.
|
||||
|
||||
*Note Options for Code Generation Conventions: (gcc)Code Gen
|
||||
Options, for information on more options offered by the GBE shared by
|
||||
`g77', `gcc', and other GNU compilers.
|
||||
|
||||
Some of these do *not* work when compiling programs written in
|
||||
Fortran:
|
||||
|
||||
`-fpcc-struct-return'
|
||||
|
||||
`-freg-struct-return'
|
||||
You should not use these except strictly the same way as you used
|
||||
them to build the version of `libf2c' with which you will be
|
||||
linking all code compiled by `g77' with the same option.
|
||||
|
||||
`-fshort-double'
|
||||
This probably either has no effect on Fortran programs, or makes
|
||||
them act loopy.
|
||||
|
||||
`-fno-common'
|
||||
Do not use this when compiling Fortran programs, or there will be
|
||||
Trouble.
|
||||
|
||||
`-fpack-struct'
|
||||
This probably will break any calls to the `libf2c' library, at the
|
||||
very least, even if it is built with the same option.
|
||||
|
||||
|
||||
File: g77.info, Node: Environment Variables, Prev: Code Gen Options, Up: Invoking G77
|
||||
|
||||
Environment Variables Affecting GNU Fortran
|
||||
===========================================
|
||||
|
||||
GNU Fortran currently does not make use of any environment variables
|
||||
to control its operation above and beyond those that affect the
|
||||
operation of `gcc'.
|
||||
|
||||
*Note Environment Variables Affecting GNU CC: (gcc)Environment
|
||||
Variables, for information on environment variables.
|
||||
|
1117
gcc/f/g77.info-4
1117
gcc/f/g77.info-4
File diff suppressed because it is too large
Load Diff
1305
gcc/f/g77.info-5
1305
gcc/f/g77.info-5
File diff suppressed because it is too large
Load Diff
1131
gcc/f/g77.info-6
1131
gcc/f/g77.info-6
File diff suppressed because it is too large
Load Diff
1869
gcc/f/g77.info-7
1869
gcc/f/g77.info-7
File diff suppressed because it is too large
Load Diff
2055
gcc/f/g77.info-8
2055
gcc/f/g77.info-8
File diff suppressed because it is too large
Load Diff
1844
gcc/f/g77.info-9
1844
gcc/f/g77.info-9
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user