Skip to content
Snippets Groups Projects
Commit ec3c17eb authored by Leandre Lacourt's avatar Leandre Lacourt
Browse files

ajout des fichiers tests de base

parent 7ce79ce5
No related branches found
No related tags found
No related merge requests found
Pipeline #184997 passed
type wiz = {
bt: real^2;
cc: bool;
};
function A(wi: wiz) returns (wo: wiz);
let
wo.bt[0] = wi.bt[0] - wi.bt[1];
wo.bt[1] = wi.bt[0] + wi.bt[1];
wo.cc = wi.bt[0] > wi.bt[1];
tel
node B(
w: wiz;
b: bool;
) returns (
x: bool;
r: real;
);
var pr: real;
let
pr = 0.0 -> pre r;
r = if b then w.bt[0] else pr + w.bt[1];
x = false -> (r > 0.0);
tel
node C(i: int; w: wiz) returns (x: bool; o: real);
var r: real;
let
r = (w.bt[0] - w.bt[1]);
o = (0.0 -> pre o) + r;
x = (r >= 42.0);
tel
function D(x,y:real) returns (o: int);
let
o = int(x + 0.5*y);
tel
node multicore(
ii: int;
win: wiz;
bt: bool;
) returns (
xo: bool; cd: int; bto: bool
);
var
btb: bool;
wa: wiz;
cc: real;
r1, r2: real;
let
wa = A(win);
btb,r1 = B(win, bt);
bto,r2 = B(wa, btb);
xo,cc = C(ii, wa);
cd = D(cc, r2);
tel
set -x
if [ -z ${C_COMPILER} ]; then C_COMPILER=gcc; fi
if [ -z ${MAIN_FILE} ]; then MAIN_FILE=multicore_multicore_omp_test.c; fi
$C_COMPILER -fopenmp -o multicore.exec \
lustre_consts.c multicore_multicore_test.c ${EXTRA_C_FILES} multicore_multicore_loop_io.c ${MAIN_FILE} ${C_LIBS}
variables:
- id: 0
name: ii
type: _integer
- id: 1
name: win
type: multicore_wiz
- id: 2
name: bt
type: _boolean
- id: 3
name: xo
type: _boolean
- id: 4
name: cd
type: _integer
- id: 5
name: bto
type: _boolean
- id: 6
name: btb
type: _boolean
- id: 7
name: wa
type: multicore_wiz
- id: 8
name: cc
type: _real
- id: 9
name: r1
type: _real
- id: 10
name: r2
type: _real
channels:
- 0
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
main:
name: multicore_multicore
ctx_type: multicore_multicore_ctx_type
ctx_new: multicore_multicore_ctx_new_ctx
var_in:
- 0
- 1
- 2
var_out:
- 3
- 4
- 5
ch_in:
- 3
- 4
- 7
ch_out:
- 0
- 1
- 2
nodes:
- id: 0
file_name: multicore_A
fct_name: multicore_A_step
ctx: false
- id: 1
file_name: multicore_B
fct_name: multicore_B_step
ctx: true
ctx_tab: multicore_B_ctx_tab
- id: 2
file_name: multicore_C
fct_name: multicore_C_step
ctx: true
ctx_tab: multicore_C_ctx_tab
- id: 3
file_name: multicore_D
fct_name: multicore_D_step
ctx: false
instances:
- id: 0
node: 0
var_in:
- 1
var_out:
- 7
ch_in:
- 3
ch_out:
- 5
- 8
- id: 0
node: 1
var_in:
- 1
- 2
var_out:
- 6
- 9
ch_in:
- 4
ch_out:
- 6
- id: 1
node: 1
var_in:
- 7
- 6
var_out:
- 5
- 10
ch_in:
- 5
- 6
ch_out:
- 2
- 10
- id: 0
node: 2
var_in:
- 0
- 7
var_out:
- 3
- 8
ch_in:
- 7
- 8
ch_out:
- 0
- 9
- id: 0
node: 3
var_in:
- 8
- 10
var_out:
- 4
ch_in:
- 9
- 10
ch_out:
- 1
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment