INFO: No output directory specified (--dir) INFO: Using directory: "Test_mask_20241206_160122" INFO: Regenerating c-file: Test_mask.c DEBUG: CMD: /u/data/pkwi/McStas/mcstas/3.x-dev/bin/mcstas-antlr -t -o ./Test_mask.c Test_mask.instr No initialization present? ----------------------------------------------------------- Generating single GPU kernel or single CPU section layout: ----------------------------------------------------------- Generating GPU/CPU -DFUNNEL layout: -> GPU kernel from component init -> GPU kernel from component test_incoherent -> GPU kernel from component test_material -> GPU kernel from component a1 -> GPU kernel from component source -> GPU kernel from component beam_center -> GPU kernel from component volume_1 -> GPU kernel from component volume_2 -> GPU kernel from component mask_1_1 -> GPU kernel from component mask_1_2 -> GPU kernel from component mask_2_1 -> GPU kernel from component mask_2_2 Component test_sample is NOACC, CPUONLY=False ->FUNNEL mode enabled, SPLIT within buffer. -> GPU kernel from component test_sample -> GPU kernel from component m4pi -> GPU kernel from component m4pi_1 -> GPU kernel from component m4pi_2 -> GPU kernel from component arm_1 -> GPU kernel from component m4pi_both -> GPU kernel from component stop ----------------------------------------------------------- DEBUG: CMD: /u/data/pkwi/McStas/mcstas/3.x-dev/bin/mcstas-antlr finished INFO: Recompiling: ./Test_mask.out DEBUG: CMD: nvc -o ./Test_mask.out ./Test_mask.c -fast -Minfo=accel -acc=gpu -gpu=managed -DOPENACC "./Test_mask.c", line 4497: warning: variable "num" was declared but never referenced [declared_but_not_referenced] int num = 3; ^ Remark: individual warnings can be suppressed with "--diag_suppress " "./Test_mask.c", line 8182: warning: variable "output" was declared but never referenced [declared_but_not_referenced] struct tagging_tree_node_struct *output; ^ "./Test_mask.c", line 8706: warning: variable "permanent_list_length" was declared but never referenced [declared_but_not_referenced] int volume_index,iterate,permanent_list_length = 0; ^ "./Test_mask.c", line 8729: warning: variable "geometry_output" was set but never used [set_but_not_used] int geometry_output; ^ "./Test_mask.c", line 9217: warning: variable "x_vector" was declared but never referenced [declared_but_not_referenced] Coords x_vector = geometry->geometry_parameters.p_box_storage->x_vector; ^ "./Test_mask.c", line 9218: warning: variable "y_vector" was declared but never referenced [declared_but_not_referenced] Coords y_vector = geometry->geometry_parameters.p_box_storage->y_vector; ^ "./Test_mask.c", line 9219: warning: variable "z_vector" was declared but never referenced [declared_but_not_referenced] Coords z_vector = geometry->geometry_parameters.p_box_storage->z_vector; ^ "./Test_mask.c", line 9379: warning: variable "center" was declared but never referenced [declared_but_not_referenced] Coords center = geometry->center; ^ "./Test_mask.c", line 9599: warning: variable "output" was set but never used [set_but_not_used] int output; ^ "./Test_mask.c", line 9758: warning: variable "radius_top" was declared but never referenced [declared_but_not_referenced] double radius_top = geometry->geometry_parameters.p_cone_storage->cone_radius_top; ^ "./Test_mask.c", line 9759: warning: variable "radius_bottom" was declared but never referenced [declared_but_not_referenced] double radius_bottom = geometry->geometry_parameters.p_cone_storage->cone_radius_bottom; ^ "./Test_mask.c", line 10034: warning: statement is unreachable [code_is_unreachable] return 0; ^ "./Test_mask.c", line 9793: warning: variable "center" was declared but never referenced [declared_but_not_referenced] Coords center = geometry->center; ^ "./Test_mask.c", line 9795: warning: variable "normal_x" was declared but never referenced [declared_but_not_referenced] double *normal_x = geometry->geometry_parameters.p_mesh_storage->normal_x; ^ "./Test_mask.c", line 9796: warning: variable "normal_y" was declared but never referenced [declared_but_not_referenced] double *normal_y = geometry->geometry_parameters.p_mesh_storage->normal_y; ^ "./Test_mask.c", line 9797: warning: variable "normal_z" was declared but never referenced [declared_but_not_referenced] double *normal_z = geometry->geometry_parameters.p_mesh_storage->normal_z; ^ "./Test_mask.c", line 9821: warning: variable "verbal" was declared but never referenced [declared_but_not_referenced] int verbal = 0; ^ "./Test_mask.c", line 9830: warning: variable "tmp" was declared but never referenced [declared_but_not_referenced] Coords edge1,edge2,h,s,q,tmp,intersect_pos; ^ "./Test_mask.c", line 9830: warning: variable "intersect_pos" was declared but never referenced [declared_but_not_referenced] Coords edge1,edge2,h,s,q,tmp,intersect_pos; ^ "./Test_mask.c", line 9832: warning: variable "this_facet_t" was declared but never referenced [declared_but_not_referenced] double this_facet_t; ^ "./Test_mask.c", line 9881: warning: variable "C1" was declared but never referenced [declared_but_not_referenced] int C1 = counter; ^ "./Test_mask.c", line 10048: warning: variable "normal_x" was declared but never referenced [declared_but_not_referenced] double *normal_x = geometry->geometry_parameters.p_mesh_storage->normal_x; ^ "./Test_mask.c", line 10049: warning: variable "normal_y" was declared but never referenced [declared_but_not_referenced] double *normal_y = geometry->geometry_parameters.p_mesh_storage->normal_y; ^ "./Test_mask.c", line 10050: warning: variable "normal_z" was declared but never referenced [declared_but_not_referenced] double *normal_z = geometry->geometry_parameters.p_mesh_storage->normal_z; ^ "./Test_mask.c", line 10079: warning: variable "center" was declared but never referenced [declared_but_not_referenced] Coords center = geometry->center; ^ "./Test_mask.c", line 10137: warning: variable "output" was set but never used [set_but_not_used] int output; ^ "./Test_mask.c", line 10153: warning: variable "tmp" was declared but never referenced [declared_but_not_referenced] Coords edge1,edge2,h,s,q,tmp,intersect_pos; ^ "./Test_mask.c", line 10153: warning: variable "intersect_pos" was declared but never referenced [declared_but_not_referenced] Coords edge1,edge2,h,s,q,tmp,intersect_pos; ^ "./Test_mask.c", line 10154: warning: variable "UNION_EPSILON" was declared but never referenced [declared_but_not_referenced] double UNION_EPSILON = 0.0000001; ^ "./Test_mask.c", line 10155: warning: variable "this_facet_t" was declared but never referenced [declared_but_not_referenced] double this_facet_t; ^ "./Test_mask.c", line 10592: warning: variable "vector2" is used before its value is set [used_before_set] if (verbal == 1) printf("vector1 = (%f,%f,%f)\n",vector1.x,vector1.y,vector2.z); ^ "./Test_mask.c", line 10581: warning: variable "seperated" was declared but never referenced [declared_but_not_referenced] int seperated = 0; ^ "./Test_mask.c", line 10658: warning: variable "seperated" was declared but never referenced [declared_but_not_referenced] int seperated = 0; ^ "./Test_mask.c", line 10865: warning: variable "seperated" was declared but never referenced [declared_but_not_referenced] int seperated = 0; ^ "./Test_mask.c", line 10963: warning: variable "solutions" was declared but never referenced [declared_but_not_referenced] int iterate,number_of_solutions,solutions,number_of_positions = 30; ^ "./Test_mask.c", line 11149: warning: variable "seperated" was declared but never referenced [declared_but_not_referenced] int seperated = 0; ^ "./Test_mask.c", line 11342: warning: variable "Y" was declared but never referenced [declared_but_not_referenced] double Y; ^ "./Test_mask.c", line 11343: warning: variable "max_r" was declared but never referenced [declared_but_not_referenced] double max_r; ^ "./Test_mask.c", line 11877: warning: variable "Y" was declared but never referenced [declared_but_not_referenced] double Y; ^ "./Test_mask.c", line 11878: warning: variable "max_r" was declared but never referenced [declared_but_not_referenced] double max_r; ^ "./Test_mask.c", line 12277: warning: variable "square_center" is used before its value is set [used_before_set] Coords box_end_point = coords_sub(coords_set(0,0,-z_depth/2),square_center); ^ "./Test_mask.c", line 12137: warning: variable "is_rectangle" was declared but never referenced [declared_but_not_referenced] int is_rectangle = geometry_box->geometry_parameters.p_box_storage->is_rectangle; ^ "./Test_mask.c", line 12142: warning: variable "y_height2" was declared but never referenced [declared_but_not_referenced] double y_height2 = geometry_box->geometry_parameters.p_box_storage->y_height2; ^ "./Test_mask.c", line 12143: warning: variable "x_vector" was declared but never referenced [declared_but_not_referenced] Coords x_vector = geometry_box->geometry_parameters.p_box_storage->x_vector; ^ "./Test_mask.c", line 12144: warning: variable "y_vector" was declared but never referenced [declared_but_not_referenced] Coords y_vector = geometry_box->geometry_parameters.p_box_storage->y_vector; ^ "./Test_mask.c", line 12151: warning: variable "Y" was declared but never referenced [declared_but_not_referenced] double Y; ^ "./Test_mask.c", line 12152: warning: variable "max_r" was declared but never referenced [declared_but_not_referenced] double max_r; ^ "./Test_mask.c", line 12275: warning: variable "square_offset" was declared but never referenced [declared_but_not_referenced] double square_offset; ^ "./Test_mask.c", line 12541: warning: variable "debug_dist" was set but never used [set_but_not_used] double debug_dist; ^ "./Test_mask.c", line 12607: warning: variable "seperated" was declared but never referenced [declared_but_not_referenced] int seperated = 0; ^ "./Test_mask.c", line 12793: warning: variable "temp_pointer" was declared but never referenced [declared_but_not_referenced] int *temp_pointer; ^ "./Test_mask.c", line 12796: warning: variable "mask_global_index" was declared but never referenced [declared_but_not_referenced] int this_mask_status,mask_index,mask_global_index; ^ "./Test_mask.c", line 12953: warning: variable "temp_pointer" was declared but never referenced [declared_but_not_referenced] int *temp_pointer; ^ "./Test_mask.c", line 12956: warning: variable "mask_global_index" was declared but never referenced [declared_but_not_referenced] int this_mask_status,mask_index,mask_global_index; ^ "./Test_mask.c", line 13875: warning: variable "found_index" was declared but never referenced [declared_but_not_referenced] int mask_index,mask_mode,found_index,logic_ALL; ^ "./Test_mask.c", line 13784: warning: variable "mask_index" was declared but never referenced [declared_but_not_referenced] int volume_index,mask_volume_number,mask_index; ^ "./Test_mask.c", line 14087: warning: variable "mask_index" was declared but never referenced [declared_but_not_referenced] int volume_index,iterate,parent,mask_index,masked_volume_index,ANY_logic,true_parent_volume_number; ^ "./Test_mask.c", line 14277: warning: variable "found_index" was declared but never referenced [declared_but_not_referenced] int volume_index,iterate,iterate2,found_index,I_index,I_volume; ^ "./Test_mask.c", line 14426: warning: variable "string_output" was declared but never referenced [declared_but_not_referenced] char string_output[124]; ^ "./Test_mask.c", line 14830: warning: variable "mask_index" was declared but never referenced [declared_but_not_referenced] int volume_index,iterate,mask_index; ^ "./Test_mask.c", line 16253: warning: variable "tc2" was set but never used [set_but_not_used] Coords tc1, tc2; ^ "./Test_mask.c", line 16291: warning: variable "tc2" was set but never used [set_but_not_used] Coords tc1, tc2; ^ "./Test_mask.c", line 16327: warning: variable "tc2" was set but never used [set_but_not_used] Coords tc1, tc2; ^ "./Test_mask.c", line 16363: warning: variable "tc2" was set but never used [set_but_not_used] Coords tc1, tc2; ^ "./Test_mask.c", line 17110: warning: variable "tc2" was set but never used [set_but_not_used] Coords tc1, tc2; ^ "./Test_mask.c", line 19662: warning: variable "physics_output" was set but never used [set_but_not_used] int physics_output; ^ "./Test_mask.c", line 22799: warning: variable "t" was declared but never referenced [declared_but_not_referenced] time_t t; ^ "./Test_mask.c", line 22800: warning: variable "ct" was set but never used [set_but_not_used] clock_t ct; ^ "./Test_mask.c", line 1506: warning: variable "mcstartdate" was set but never used [set_but_not_used] static long mcstartdate = 0; /* start simulation time */ ^ "./Test_mask.c", line 2909: warning: function "strcpy_valid" was declared but never referenced [declared_but_not_referenced] static char *strcpy_valid(char *valid, char *original) ^ mcgenstate: 91, Generating acc routine seq Generating NVIDIA GPU code particle_getvar: 105, Generating acc routine seq Generating NVIDIA GPU code particle_getvar_void: 139, Generating acc routine seq Generating NVIDIA GPU code particle_setvar_void: 165, Generating acc routine seq Generating NVIDIA GPU code particle_setvar_void_array: 189, Generating acc routine seq Generating NVIDIA GPU code particle_restore: 201, Generating acc routine seq Generating NVIDIA GPU code particle_getuservar_byid: 210, Generating acc routine seq Generating NVIDIA GPU code particle_uservar_init: 222, Generating acc routine seq Generating NVIDIA GPU code noprintf: 1553, Generating acc routine seq Generating NVIDIA GPU code str_comp: 1557, Generating acc routine seq Generating NVIDIA GPU code str_len: 1566, Generating acc routine seq Generating NVIDIA GPU code mcget_ncount: 4118, Generating acc routine seq Generating NVIDIA GPU code coords_set: 4549, Generating acc routine seq Generating NVIDIA GPU code coords_get: 4560, Generating acc routine seq Generating NVIDIA GPU code coords_add: 4569, Generating acc routine seq Generating NVIDIA GPU code coords_sub: 4581, Generating acc routine seq Generating NVIDIA GPU code coords_neg: 4593, Generating acc routine seq Generating NVIDIA GPU code coords_scale: 4603, Generating acc routine seq Generating NVIDIA GPU code coords_sp: 4613, Generating acc routine seq Generating NVIDIA GPU code coords_xp: 4621, Generating acc routine seq Generating NVIDIA GPU code coords_len: 4631, Generating acc routine seq Generating NVIDIA GPU code coords_print: 4653, Generating acc routine seq Generating NVIDIA GPU code coords_norm: 4660, Generating acc routine seq Generating NVIDIA GPU code rot_set_rotation: 4706, Generating acc routine seq Generating NVIDIA GPU code rot_test_identity: 4741, Generating acc routine seq Generating NVIDIA GPU code rot_mul: 4752, Generating acc routine seq Generating NVIDIA GPU code rot_copy: 4769, Generating acc routine seq Generating NVIDIA GPU code rot_transpose: 4780, Generating acc routine seq Generating NVIDIA GPU code rot_apply: 4796, Generating acc routine seq Generating NVIDIA GPU code vec_prod_func: 4825, Generating acc routine seq Generating NVIDIA GPU code scalar_prod: 4836, Generating acc routine seq Generating NVIDIA GPU code norm_func: 4840, Generating acc routine seq Generating NVIDIA GPU code mccoordschange: 5017, Generating acc routine seq Generating NVIDIA GPU code mccoordschange_polarisation: 5048, Generating acc routine seq Generating NVIDIA GPU code normal_vec: 5065, Generating acc routine seq Generating NVIDIA GPU code solve_2nd_order: 5164, Generating acc routine seq Generating NVIDIA GPU code _randvec_target_circle: 5248, Generating acc routine seq Generating NVIDIA GPU code _randvec_target_rect_angular: 5314, Generating acc routine seq Generating NVIDIA GPU code _randvec_target_rect_real: 5391, Generating acc routine seq Generating NVIDIA GPU code kiss_srandom: 5663, Generating acc routine seq Generating NVIDIA GPU code kiss_random: 5673, Generating acc routine seq Generating NVIDIA GPU code _hash: 5699, Generating acc routine seq Generating NVIDIA GPU code _randnorm2: 5740, Generating acc routine seq Generating NVIDIA GPU code _randtriangle: 5751, Generating acc routine seq Generating NVIDIA GPU code _rand01: 5756, Generating acc routine seq Generating NVIDIA GPU code _randpm1: 5764, Generating acc routine seq Generating NVIDIA GPU code _rand0max: 5772, Generating acc routine seq Generating NVIDIA GPU code _randminmax: 5779, Generating acc routine seq Generating NVIDIA GPU code mcsetstate: 6436, Generating acc routine seq Generating NVIDIA GPU code inside_rectangle: 6532, Generating acc routine seq Generating NVIDIA GPU code box_intersect: 6549, Generating acc routine seq Generating NVIDIA GPU code cylinder_intersect: 6664, Generating acc routine seq Generating NVIDIA GPU code sphere_intersect: 6719, Generating acc routine seq Generating NVIDIA GPU code distance_between: 7437, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code length_of_3vector: 7445, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code coords_scalar_mult: 7460, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code on_int_list: 7475, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code print_1d_int_list: 7696, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code update_current_mask_intersect_status: 8026, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code make_tagging_tree_node: 8106, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code initialize_tagging_tree_node: 8129, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code goto_process_node: 8155, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code goto_volume_node: 8175, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code add_statistics_to_node: 8224, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code clear_intersection_table: 8522, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code sample_box_intersect_advanced: 9205, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code sample_box_intersect_simple: 9399, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code r_within_box_simple: 9440, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code r_within_cone: 9459, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code sample_cone_intersect: 9523, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code r_within_box_advanced: 10307, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code sample_sphere_intersect: 10434, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code r_within_sphere: 10456, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code sample_cylinder_intersect: 10501, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code r_within_cylinder: 10562, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code intersect_function: 12683, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code r_within_function: 12715, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code within_which_volume_GPU: 12913, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code Incoherent_physics_my: 15269, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code Incoherent_physics_scattering: 15275, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code physics_my: 15561, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code physics_scattering: 15620, Generating implicit acc routine seq Generating acc routine seq Generating NVIDIA GPU code init: 18874, Generating update device(_beam_center_var,_stop_var,_test_incoherent_var,_mask_2_2_var,_arm_1_var,_test_sample_var,_volume_2_var,_volume_1_var,_m4pi_var,_mask_1_1_var,_mask_1_2_var,_mask_2_1_var,_test_material_var,_m4pi_both_var,_instrument_var,_m4pi_1_var,_a1_var,_m4pi_2_var,_source_var,_init_var) class_Progress_bar_trace: 18918, Generating acc routine seq Generating NVIDIA GPU code class_Source_div_trace: 19008, Generating acc routine seq Generating NVIDIA GPU code class_Arm_trace: 19106, Generating acc routine seq Generating NVIDIA GPU code NVC++-W-1056-External variables used in acc routine need to be in #pragma acc create() - abs_loggers_with_data_array (./Test_mask.c: 20336) NVC++-W-1056-External variables used in acc routine need to be in #pragma acc create() - loggers_with_data_array (./Test_mask.c: 20284) NVC++-W-1056-External variables used in acc routine need to be in #pragma acc create() - loggers_with_data_array (./Test_mask.c: 19329) class_Union_master_trace: 20291, Accelerator restriction: Indirect function/procedure calls are not supported 20343, Accelerator restriction: Indirect function/procedure calls are not supported 20389, Accelerator restriction: Indirect function/procedure calls are not supported class_PSD_monitor_4PI_trace: 20607, Generating acc routine seq Generating NVIDIA GPU code raytrace: 20693, Generating acc routine seq Generating NVIDIA GPU code raytrace_all: 20974, Generating implicit firstprivate(gpu_innerloop) Generating NVIDIA GPU code 20988, #pragma acc loop gang(numgangs), vector(vecsize) /* blockIdx.x threadIdx.x */ 20974, Local memory used for .inl_particle_29244,particleN,.inl_.inl_mcneutron_0_29259,.inl_.X2508_29261,.inl_.inl_.X2703_15_29260 20988, Generating implicit firstprivate(seed,_particle) finally: 22054, Generating update self(_beam_center_var,_stop_var,_test_incoherent_var,_mask_2_2_var,_arm_1_var,_test_sample_var,_volume_2_var,_volume_1_var,_m4pi_var,_mask_1_1_var,_mask_1_2_var,_mask_2_1_var,_test_material_var,_m4pi_both_var,_instrument_var,_m4pi_1_var,_a1_var,_m4pi_2_var,_source_var,_init_var) mcenabletrace: 5898, Generating update device(mcdotrace) nvvmCompileProgram error 9: NVVM_ERROR_COMPILATION. Error: /tmp/nvaccoAcGmQi3M_zf-.gpu (53488, 37): parse use of undefined value '@class_Union_master_trace' NVC++-F-0155-Compiler failed to translate accelerator region (see -Minfo messages): Device compiler exited with error status code (./Test_mask.c: 20974) NVC++/x86-64 Linux 24.7-0: compilation aborted INFO: call to nvc failed with Command 'nvc -o ./Test_mask.out ./Test_mask.c -fast -Minfo=accel -acc=gpu -gpu=managed -DOPENACC' returned non-zero exit status 2. Traceback (most recent call last): File "/u/data/pkwi/McStas/mcstas/3.x-dev/tools/Python/mcrun/mcrun.py", line 595, in main() File "/u/data/pkwi/McStas/mcstas/3.x-dev/tools/Python/mcrun/mcrun.py", line 503, in main mcstas.prepare(options) File "/u/data/pkwi/McStas/mcstas/3.x-dev/tools/Python/mcrun/mccode.py", line 294, in prepare Process(lexer.quote(options.cc)).run(args) File "/u/data/pkwi/McStas/mcstas/3.x-dev/tools/Python/mcrun/mccode.py", line 77, in run raise err File "/u/data/pkwi/McStas/mcstas/3.x-dev/tools/Python/mcrun/mccode.py", line 73, in run proc = run(command, shell=True, check=True, text=True, capture_output=pipe) File "/u/data/pkwi/McStas/mcstas/3.x-dev/miniconda3/lib/python3.10/subprocess.py", line 526, in run raise CalledProcessError(retcode, process.args, subprocess.CalledProcessError: Command 'nvc -o ./Test_mask.out ./Test_mask.c -fast -Minfo=accel -acc=gpu -gpu=managed -DOPENACC' returned non-zero exit status 2.