replica nfl jerseysreplica nfl jerseyssoccer jerseyreplica nfl jerseys forums.silverfrost.com :: View topic - Compiler V6.0 crashes on short code with /opt
forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Compiler V6.0 crashes on short code with /opt

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Support
View previous topic :: View next topic  
Author Message
mecej4



Joined: 31 Oct 2006
Posts: 1899

PostPosted: Thu Mar 17, 2011 10:43 am    Post subject: Compiler V6.0 crashes on short code with /opt Reply with quote

When FTN95 V6.0 is run on the code below with the /opt option, it crashes.

Code:
      SUBROUTINE TFBU(N,X,F,G)
      implicit none
      INTEGER N
      REAL X(N),G(N),F
      REAL FA,S1,T,BET
      INTEGER J

      BET=14
      FA=1.73
      DO J=1,N
        IF(J.NE.3) THEN
          T=SQRT(X(J)**2+3.0/J)
          S1=LOG(T)
          G(J)=G(J)+(X(J)*(SIN(S1)**5+COS(S1)**5+
     +         5*SIN(S1)**4*COS(S1)-
     +         5*SIN(S1)*COS(S1)**4)/T)*FA
        ELSE
          G(J)=G(J)+BET*N*FA
        ENDIF
      END DO
      F=0.5D0*F
      RETURN
      END


When the code is slightly modified as given below, the compiler (again with /opt) gives the puzzling message "*** Operand incompatible with opcode":

Code:
      SUBROUTINE TFBU28(N,X,F,G)
      implicit none
      INTEGER N
      REAL X(N),G(N),F
      REAL FA,S1,T,BET,ALF
      INTEGER J

      ALF=5
      BET=14
      FA=1.73
      DO J=1,N
        IF(J.NE.3) THEN
          T=SQRT(X(J)**2+3.0/J)
          S1=LOG(T)
          G(J)=G(J)+(X(J)*(SIN(S1)**5+COS(S1)**5+
     +         5*SIN(S1)**(ALF-1.0)*COS(S1)-
     +         5*SIN(S1)*COS(S1)**(ALF-1.0))/T)*FA
        ELSE
          G(J)=G(J)+BET*N*FA
        ENDIF
      END DO
      F=0.5D0*F
      RETURN
      END
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 8210
Location: Salford, UK

PostPosted: Thu Mar 17, 2011 11:32 am    Post subject: Reply with quote

OK. I will log this for investigation.
Back to top
View user's profile Send private message AIM Address
sparge



Joined: 11 Apr 2005
Posts: 371

PostPosted: Thu Mar 17, 2011 12:10 pm    Post subject: Reply with quote

This rings a bell. I got that puzzling error message once. If I remember correctly, it turned out to be something to do with a slight change in instruction set between two flavours of Pentium CPU, which the compiler was not aware of. So worth trying on a machine of different vintage, if possible.
Back to top
View user's profile Send private message Send e-mail
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 8210
Location: Salford, UK

PostPosted: Wed Apr 27, 2011 9:18 am    Post subject: Reply with quote

Both of these bugs have now been fixed for the next release.
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Support All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group