version 1.51, 2012/12/18 13:19:36
|
version 1.75, 2017/06/28 09:20:33
|
Line 1
|
Line 1
|
/* |
/* |
================================================================================ |
================================================================================ |
RPL/2 (R) version 4.1.12 |
RPL/2 (R) version 4.1.27 |
Copyright (C) 1989-2012 Dr. BERTRAND Joël |
Copyright (C) 1989-2017 Dr. BERTRAND Joël |
|
|
This file is part of RPL/2. |
This file is part of RPL/2. |
|
|
Line 96 instruction_format(struct_processus *s_e
|
Line 96 instruction_format(struct_processus *s_e
|
printf(" { \"CHARACTER*(*)\" }\n"); |
printf(" { \"CHARACTER*(*)\" }\n"); |
printf(" { \"CHARACTER*(%s)\" }\n", d_INT); |
printf(" { \"CHARACTER*(%s)\" }\n", d_INT); |
printf(" { \"BINARY*%s(*)\" }\n", d_INT); |
printf(" { \"BINARY*%s(*)\" }\n", d_INT); |
printf(" { \"BINARY*%s(%s)\" }\n\n", d_INT, d_INT); |
printf(" { \"BINARY*%s(%s)\" }\n", d_INT, d_INT); |
|
printf(" { \"NATIVE*(*)\" }\n\n"); |
|
|
printf(" UNFORMATTED\n"); |
printf(" UNFORMATTED\n"); |
printf(" { \"INTEGER*1\", \"INTEGER*2\", \"INTEGER*4\", " |
printf(" { \"INTEGER*1\", \"INTEGER*2\", \"INTEGER*4\", " |
Line 105 instruction_format(struct_processus *s_e
|
Line 106 instruction_format(struct_processus *s_e
|
"\"LOGICAL*8\" }\n"); |
"\"LOGICAL*8\" }\n"); |
printf(" { \"REAL*4\", \"REAL*8\" }\n"); |
printf(" { \"REAL*4\", \"REAL*8\" }\n"); |
printf(" { \"COMPLEX*8\", \"COMPLEX*16\" }\n"); |
printf(" { \"COMPLEX*8\", \"COMPLEX*16\" }\n"); |
printf(" { \"CHARACTER\" }\n\n"); |
printf(" { \"CHARACTER*(*)\", \"CHARACTER*(%s)\" }\n", d_INT); |
|
printf(" { \"NATIVE*(*)\" }\n\n"); |
|
|
printf(" FLOW\n"); |
printf(" FLOW\n"); |
printf(" { \"LENGTH*(*)\" }\n"); |
printf(" { \"LENGTH*(*)\" }\n"); |
Line 540 instruction_fleche_q(struct_processus *s
|
Line 542 instruction_fleche_q(struct_processus *s
|
|
|
if (y != 0) |
if (y != 0) |
{ |
{ |
z = fabs(objectif - (r1 / r2)); |
z = abs(objectif - (r1 / r2)); |
x = ((real8) 1) / y; |
x = ((real8) 1) / y; |
} |
} |
else |
else |
Line 954 instruction_fleche_row(struct_processus
|
Line 956 instruction_fleche_row(struct_processus
|
nombre_lignes; |
nombre_lignes; |
|
|
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
malloc(nombre_lignes * sizeof(integer8 *))) == NULL) |
malloc(((size_t) nombre_lignes) * sizeof(integer8 *))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
return; |
return; |
Line 969 instruction_fleche_row(struct_processus
|
Line 971 instruction_fleche_row(struct_processus
|
} |
} |
|
|
if ((((integer8 **) (*((struct_matrice *) (*s_objet_resultat) |
if ((((integer8 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i] = malloc(nombre_colonnes * |
.objet)).tableau)[i] = malloc(((size_t) nombre_colonnes) * |
sizeof(integer8))) == NULL) |
sizeof(integer8))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
Line 1000 instruction_fleche_row(struct_processus
|
Line 1002 instruction_fleche_row(struct_processus
|
nombre_lignes; |
nombre_lignes; |
|
|
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
malloc(nombre_lignes * sizeof(real8 *))) == NULL) |
malloc(((size_t) nombre_lignes) * sizeof(real8 *))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
return; |
return; |
Line 1015 instruction_fleche_row(struct_processus
|
Line 1017 instruction_fleche_row(struct_processus
|
} |
} |
|
|
if ((((real8 **) (*((struct_matrice *) (*s_objet_resultat) |
if ((((real8 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i] = malloc(nombre_colonnes * |
.objet)).tableau)[i] = malloc(((size_t) nombre_colonnes) * |
sizeof(real8))) == NULL) |
sizeof(real8))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
Line 1027 instruction_fleche_row(struct_processus
|
Line 1029 instruction_fleche_row(struct_processus
|
for(j = 0; j < nombre_colonnes; j++) |
for(j = 0; j < nombre_colonnes; j++) |
{ |
{ |
((real8 **) (*((struct_matrice *) (*s_objet_resultat) |
((real8 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i][j] = ((integer8 **) |
.objet)).tableau)[i][j] = (real8) ((integer8 **) |
(*((struct_matrice *) (*s_objet).objet)) |
(*((struct_matrice *) (*s_objet).objet)) |
.tableau)[0][j]; |
.tableau)[0][j]; |
} |
} |
Line 1060 instruction_fleche_row(struct_processus
|
Line 1062 instruction_fleche_row(struct_processus
|
nombre_lignes; |
nombre_lignes; |
|
|
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
malloc(nombre_lignes * sizeof(complex16 *))) == NULL) |
malloc(((size_t) nombre_lignes) * sizeof(complex16 *))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
return; |
return; |
Line 1075 instruction_fleche_row(struct_processus
|
Line 1077 instruction_fleche_row(struct_processus
|
} |
} |
|
|
if ((((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
if ((((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i] = malloc(nombre_colonnes * |
.objet)).tableau)[i] = malloc(((size_t) nombre_colonnes) * |
sizeof(complex16))) == NULL) |
sizeof(complex16))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
Line 1087 instruction_fleche_row(struct_processus
|
Line 1089 instruction_fleche_row(struct_processus
|
for(j = 0; j < nombre_colonnes; j++) |
for(j = 0; j < nombre_colonnes; j++) |
{ |
{ |
(((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
(((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i][j]).partie_reelle = |
.objet)).tableau)[i][j]).partie_reelle = (real8) |
((integer8 **) (*((struct_matrice *) |
((integer8 **) (*((struct_matrice *) |
(*s_objet).objet)).tableau)[0][j]; |
(*s_objet).objet)).tableau)[0][j]; |
(((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
(((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
Line 1349 instruction_fleche_col(struct_processus
|
Line 1351 instruction_fleche_col(struct_processus
|
nombre_lignes; |
nombre_lignes; |
|
|
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
malloc(nombre_lignes * sizeof(integer8 *))) == NULL) |
malloc(((size_t) nombre_lignes) * sizeof(integer8 *))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
return; |
return; |
Line 1358 instruction_fleche_col(struct_processus
|
Line 1360 instruction_fleche_col(struct_processus
|
for(i = 0; i < nombre_lignes; i++) |
for(i = 0; i < nombre_lignes; i++) |
{ |
{ |
if ((((integer8 **) (*((struct_matrice *) (*s_objet_resultat) |
if ((((integer8 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i] = malloc(nombre_colonnes * |
.objet)).tableau)[i] = malloc(((size_t) nombre_colonnes) * |
sizeof(integer8))) == NULL) |
sizeof(integer8))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
Line 1398 instruction_fleche_col(struct_processus
|
Line 1400 instruction_fleche_col(struct_processus
|
nombre_lignes; |
nombre_lignes; |
|
|
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
malloc(nombre_lignes * sizeof(real8 *))) == NULL) |
malloc(((size_t) nombre_lignes) * sizeof(real8 *))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
return; |
return; |
Line 1407 instruction_fleche_col(struct_processus
|
Line 1409 instruction_fleche_col(struct_processus
|
for(i = 0; i < nombre_lignes; i++) |
for(i = 0; i < nombre_lignes; i++) |
{ |
{ |
if ((((real8 **) (*((struct_matrice *) (*s_objet_resultat) |
if ((((real8 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i] = malloc(nombre_colonnes * |
.objet)).tableau)[i] = malloc(((size_t) nombre_colonnes) * |
sizeof(real8))) == NULL) |
sizeof(real8))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
Line 1428 instruction_fleche_col(struct_processus
|
Line 1430 instruction_fleche_col(struct_processus
|
for(i = 0; i < nombre_lignes; i++) |
for(i = 0; i < nombre_lignes; i++) |
{ |
{ |
((real8 **) (*((struct_matrice *) (*s_objet_resultat) |
((real8 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i][j] = ((integer8 **) |
.objet)).tableau)[i][j] = (real8) ((integer8 **) |
(*((struct_matrice *) (*s_objet).objet)) |
(*((struct_matrice *) (*s_objet).objet)) |
.tableau)[i][0]; |
.tableau)[i][0]; |
} |
} |
Line 1461 instruction_fleche_col(struct_processus
|
Line 1463 instruction_fleche_col(struct_processus
|
nombre_lignes; |
nombre_lignes; |
|
|
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
if (((*((struct_matrice *) (*s_objet_resultat).objet)).tableau = |
malloc(nombre_lignes * sizeof(complex16 *))) == NULL) |
malloc(((size_t) nombre_lignes) * sizeof(complex16 *))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
return; |
return; |
Line 1470 instruction_fleche_col(struct_processus
|
Line 1472 instruction_fleche_col(struct_processus
|
for(i = 0; i < nombre_lignes; i++) |
for(i = 0; i < nombre_lignes; i++) |
{ |
{ |
if ((((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
if ((((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i] = malloc(nombre_colonnes * |
.objet)).tableau)[i] = malloc(((size_t) nombre_colonnes) * |
sizeof(complex16))) == NULL) |
sizeof(complex16))) == NULL) |
{ |
{ |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
(*s_etat_processus).erreur_systeme = d_es_allocation_memoire; |
Line 1491 instruction_fleche_col(struct_processus
|
Line 1493 instruction_fleche_col(struct_processus
|
for(i = 0; i < nombre_lignes; i++) |
for(i = 0; i < nombre_lignes; i++) |
{ |
{ |
(((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
(((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
.objet)).tableau)[i][j]).partie_reelle = |
.objet)).tableau)[i][j]).partie_reelle = (real8) |
((integer8 **) (*((struct_matrice *) |
((integer8 **) (*((struct_matrice *) |
(*s_objet).objet)).tableau)[i][0]; |
(*s_objet).objet)).tableau)[i][0]; |
(((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |
(((complex16 **) (*((struct_matrice *) (*s_objet_resultat) |