Diff for /rpl/src/analyse.c between versions 1.48 and 1.54

version 1.48, 2011/07/22 07:38:33 version 1.54, 2011/09/14 17:55:59
Line 1 Line 1
 /*  /*
 ================================================================================  ================================================================================
   RPL/2 (R) version 4.1.1    RPL/2 (R) version 4.1.3
   Copyright (C) 1989-2011 Dr. BERTRAND Joël    Copyright (C) 1989-2011 Dr. BERTRAND Joël
   
   This file is part of RPL/2.    This file is part of RPL/2.
Line 544  initialisation_instructions(struct_proce Line 544  initialisation_instructions(struct_proce
     INSTRUCTION("SPAR", instruction_spar);      INSTRUCTION("SPAR", instruction_spar);
     INSTRUCTION("SQRT", instruction_sqrt);      INSTRUCTION("SQRT", instruction_sqrt);
     //INSTRUCTION("SRAD");      //INSTRUCTION("SRAD");
       INSTRUCTION("SREV", instruction_srev);
     //INSTRUCTION("SRNM")      //INSTRUCTION("SRNM")
     //Instruction HP48 (renvoie la norme spectrale d'un tableau. Pour une      //Instruction HP48 (renvoie la norme spectrale d'un tableau. Pour une
     //matrice,      //matrice,
Line 652  initialisation_instructions(struct_proce Line 653  initialisation_instructions(struct_proce
     INSTRUCTION("LCASE", instruction_lcase);      INSTRUCTION("LCASE", instruction_lcase);
     INSTRUCTION("LCHOL", instruction_lchol);      INSTRUCTION("LCHOL", instruction_lchol);
     INSTRUCTION("LCD->", instruction_lcd_fleche);      INSTRUCTION("LCD->", instruction_lcd_fleche);
       INSTRUCTION("LIMIT", instruction_limit);
     //INSTRUCTION("NDIST")      //INSTRUCTION("NDIST")
     //Instruction HP48 (distribution normale, prend la moyenne au niveau 3,      //Instruction HP48 (distribution normale, prend la moyenne au niveau 3,
     //la variance au niveau 2, un réel x au niveau 1 et renvoie la probabilité      //la variance au niveau 2, un réel x au niveau 1 et renvoie la probabilité
Line 833  initialisation_instructions(struct_proce Line 835  initialisation_instructions(struct_proce
     INSTRUCTION("DUPCNTXT", instruction_dupcntxt);      INSTRUCTION("DUPCNTXT", instruction_dupcntxt);
     INSTRUCTION("FUNCTION", instruction_function);      INSTRUCTION("FUNCTION", instruction_function);
     INSTRUCTION("IMPLICIT", instruction_implicit);      INSTRUCTION("IMPLICIT", instruction_implicit);
       INSTRUCTION("INFINITY", instruction_sensible_infinity);
     INSTRUCTION("KEYLABEL", instruction_keylabel);      INSTRUCTION("KEYLABEL", instruction_keylabel);
     INSTRUCTION("KEYTITLE", instruction_keytitle);      INSTRUCTION("KEYTITLE", instruction_keytitle);
     INSTRUCTION("LOGSCALE", instruction_logscale);      INSTRUCTION("LOGSCALE", instruction_logscale);
Line 982  analyse(struct_processus *s_etat_process Line 985  analyse(struct_processus *s_etat_process
      * On autorise l'exécution d'un fork() dans un thread concurrent.       * On autorise l'exécution d'un fork() dans un thread concurrent.
      */       */
   
 #   ifndef SEMAPHORES_NOMMES      if (pthread_mutex_unlock(&((*s_etat_processus).mutex_fork)) != 0)
     if (sem_post(&((*s_etat_processus).semaphore_fork)) != 0)  
     {      {
         (*s_etat_processus).erreur_systeme = d_es_processus;          (*s_etat_processus).erreur_systeme = d_es_processus;
         return;          return;
     }      }
   
     while(sem_wait(&((*s_etat_processus).semaphore_fork)) == -1)      if (pthread_mutex_lock(&((*s_etat_processus).mutex_fork)) != 0)
     {  
         if (errno != EINTR)  
         {  
             (*s_etat_processus).erreur_systeme = d_es_processus;  
             return;  
         }  
     }  
 #   else  
     if (sem_post((*s_etat_processus).semaphore_fork) != 0)  
     {      {
         (*s_etat_processus).erreur_systeme = d_es_processus;          (*s_etat_processus).erreur_systeme = d_es_processus;
         return;          return;
     }      }
   
     while(sem_wait((*s_etat_processus).semaphore_fork) == -1)  
     {  
         if (errno != EINTR)  
         {  
             (*s_etat_processus).erreur_systeme = d_es_processus;  
             return;  
         }  
     }  
 #   endif  
   
     scrutation_injection(s_etat_processus);      scrutation_injection(s_etat_processus);
   
     if (fonction == NULL)      if (fonction == NULL)

Removed from v.1.48  
changed lines
  Added in v.1.54


CVSweb interface <joel.bertrand@systella.fr>