Advertisement
magneto903

wasm_right_code

Mar 23rd, 2021
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. //wasm_module.main();
  2.  
  3. wasm_module.init_edges_cpp();
  4.  
  5.  
  6. for (var i=0; i < all_edges.length; i++) {
  7.   wasm_module.add_edge_cpp(i, all_edges[i][0], all_edges[i][1], all_edges[i][2]);
  8. }
  9.  
  10. wasm_module.fill_graph_cpp();
  11. wasm_module.init_cpp(162);
  12. var s_t = performance.now()
  13. for (var i=0; i < 10; i++) {
  14.  
  15.   /*wasm_module.init_cpp();*/
  16.   wasm_module.get_dists_cpp(157, 162);
  17.  
  18.  
  19. }
  20. console.log((performance.now() - s_t)/10)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement