diff --git a/csv/empty b/csv/empty new file mode 100644 index 0000000..e69de29 diff --git a/csv/skylake_helmholtz_quad_1_1_omp_icc.csv b/csv/skylake_helmholtz_quad_1_1_omp_icc.csv new file mode 100644 index 0000000..29a4748 --- /dev/null +++ b/csv/skylake_helmholtz_quad_1_1_omp_icc.csv @@ -0,0 +1,7 @@ +n,p,f,dof,cell,add,sub,mul,div,mem,byte,time,ninst,nloops,extend_dof,extend_quad +8,1,0,81,64,150,0,287,9,20,2720,1.66416e-05,48,16,2,3 +8,2,0,289,64,456,0,768,16,144,6336,2.451e-05,41,7,3,4 +8,3,0,625,64,1065,0,1435,25,320,11936,3.543e-05,43,10,4,5 +8,4,0,1089,64,1884,0,2412,36,600,19648,6.2704e-05,43,10,5,6 +8,5,0,1681,64,3045,0,3759,49,1008,29472,9.6082e-05,43,10,6,7 +8,6,0,2401,64,4608,0,5536,64,1568,41408,0.000108862,43,10,7,8 diff --git a/csv/skylake_helmholtz_quad_1_1_ve_icc.csv b/csv/skylake_helmholtz_quad_1_1_ve_icc.csv new file mode 100644 index 0000000..404d3fb --- /dev/null +++ b/csv/skylake_helmholtz_quad_1_1_ve_icc.csv @@ -0,0 +1,7 @@ +n,p,f,dof,cell,add,sub,mul,div,mem,byte,time,ninst,nloops,extend_dof,extend_quad +8,1,0,81,64,150,0,287,9,20,2720,1.6164799999999998e-05,48,16,2,3 +8,2,0,289,64,456,0,768,16,144,6336,2.1314e-05,41,7,3,4 +8,3,0,625,64,1065,0,1435,25,320,11936,3.4331999999999996e-05,43,10,4,5 +8,4,0,1089,64,1884,0,2412,36,600,19648,5.2356e-05,43,10,5,6 +8,5,0,1681,64,3045,0,3759,49,1008,29472,8.3018e-05,43,10,6,7 +8,6,0,2401,64,4608,0,5536,64,1568,41408,0.00011086399999999999,43,10,7,8 diff --git a/csv/skylake_helmholtz_quad_1_4_omp_icc.csv b/csv/skylake_helmholtz_quad_1_4_omp_icc.csv new file mode 100644 index 0000000..88de256 --- /dev/null +++ b/csv/skylake_helmholtz_quad_1_4_omp_icc.csv @@ -0,0 +1,7 @@ +n,p,f,dof,cell,add,sub,mul,div,mem,byte,time,ninst,nloops,extend_dof,extend_quad +8,1,0,81,64,150,0,287,9,20,2720,2.5033999999999998e-05,48,16,2,3 +8,2,0,289,64,456,0,768,16,144,6336,3.2378e-05,41,7,3,4 +8,3,0,625,64,1065,0,1435,25,320,11936,6.6184e-05,43,10,4,5 +8,4,0,1089,64,1884,0,2412,36,600,19648,8.2254e-05,43,10,5,6 +8,5,0,1681,64,3045,0,3759,49,1008,29472,0.000116158,43,10,6,7 +8,6,0,2401,64,4608,0,5536,64,1568,41408,0.0001575,43,10,7,8 diff --git a/csv/skylake_helmholtz_quad_1_4_ve_icc.csv b/csv/skylake_helmholtz_quad_1_4_ve_icc.csv new file mode 100644 index 0000000..f66e07a --- /dev/null +++ b/csv/skylake_helmholtz_quad_1_4_ve_icc.csv @@ -0,0 +1,7 @@ +n,p,f,dof,cell,add,sub,mul,div,mem,byte,time,ninst,nloops,extend_dof,extend_quad +8,1,0,81,64,150,0,287,9,20,2720,1.51158e-05,48,16,2,3 +8,2,0,289,64,456,0,768,16,144,6336,2.1124e-05,41,7,3,4 +8,3,0,625,64,1065,0,1435,25,320,11936,2.7084e-05,43,10,4,5 +8,4,0,1089,64,1884,0,2412,36,600,19648,3.581e-05,43,10,5,6 +8,5,0,1681,64,3045,0,3759,49,1008,29472,5.2022e-05,43,10,6,7 +8,6,0,2401,64,4608,0,5536,64,1568,41408,6.5326e-05,43,10,7,8 diff --git a/oneform.py b/oneform.py index a9fac8c..9560cfa 100644 --- a/oneform.py +++ b/oneform.py @@ -77,12 +77,17 @@ print("CELLS= {0}".format(cells)) print("DOFS= {0}".format(dofs)) + from loopy.program import make_program + knl = compile_form(y_form, coffee=False)[0].ast warnings = list(knl.silenced_warnings) warnings.extend(["insn_count_subgroups_upper_bound", "no_lid_found"]) knl = knl.copy(silenced_warnings=warnings) - op_map = lp.get_op_map(knl) - mem_map = lp.get_mem_access_map(knl, subgroup_size=1) + knl.options.ignore_boostable_into = True + + program = make_program(knl) + op_map = lp.get_op_map(program, subgroup_size=1) + mem_map = lp.get_mem_access_map(program, subgroup_size=1) for op in ['add', 'sub', 'mul', 'div']: print("{0}S= {1}".format(op.upper(), op_map.filter_by(name=[op], dtype=[np.float64]).eval_and_sum({}))) diff --git a/run_many_oneforms.sh b/run_many_oneforms.sh index e1d5d65..4f23437 100755 --- a/run_many_oneforms.sh +++ b/run_many_oneforms.sh @@ -1,8 +1,12 @@ #!/bin/bash -batchsize=(1 8) +batchsize=(1 4) # 1: not vectorize, 4: vectorize by 4 mesh=('quad' 'tri' 'hex' 'tetra') +# mesh=('quad') form=('helmholtz' 'mass' 'laplacian' 'elasticity' 'hyperelasticity') -vs=('omp' 've') +# form=('helmholtz') +vs=('omp' 've') # vectorization strategy +export PYOP2_TIME=1 # switch on timing mode +export TJ_NP=1 # number of processes for v in ${vs[@]} do for m in ${mesh[@]} diff --git a/run_oneforms.py b/run_oneforms.py index 79e34c8..50efa0a 100644 --- a/run_oneforms.py +++ b/run_oneforms.py @@ -109,7 +109,7 @@ def get_n(mesh, p): result.append((n, p, f, dofs, cells, adds, subs, muls, divs, mems, bytes, time, instructions, loops, dof_loop_extent, quadrature_loop_extent)) -csvfile = open('results/vector/csv/{0}{1}_{2}_{3}_{4}_{5}{6}.csv'.format(prefix, form, mesh, str(np), simd_width, vect_strategy, suffix), 'w') +csvfile = open('csv/{0}{1}_{2}_{3}_{4}_{5}{6}.csv'.format(prefix, form, mesh, str(np), simd_width, vect_strategy, suffix), 'w') writer = csv.writer(csvfile) writer.writerows(result) csvfile.close()