@@ -50,7 +50,7 @@ def git_url(self) -> str:
5050 return "https://github.com/intel/compute-benchmarks.git"
5151
5252 def git_hash (self ) -> str :
53- return "ffd199db86a904451f0697cb25a0e7a6b9f2006f "
53+ return "83b9ae3ebb3563552409f3a317cdc1cf3d3ca6bd "
5454
5555 def setup (self ):
5656 if options .sycl is None :
@@ -113,6 +113,9 @@ def additional_metadata(self) -> dict[str, BenchmarkMetadata]:
113113 "SubmitGraph" : BenchmarkMetadata (
114114 type = "group" , tags = ["submit" , "micro" , "SYCL" , "UR" , "L0" , "graph" ]
115115 ),
116+ "FinalizeGraph" : BenchmarkMetadata (
117+ type = "group" , tags = ["finalize" , "micro" , "SYCL" , "graph" ]
118+ ),
116119 }
117120
118121 def benchmarks (self ) -> list [Benchmark ]:
@@ -169,6 +172,10 @@ def benchmarks(self) -> list[Benchmark]:
169172 ExecImmediateCopyQueue (self , 0 , 1 , "Device" , "Device" , 1024 ),
170173 ExecImmediateCopyQueue (self , 1 , 1 , "Device" , "Host" , 1024 ),
171174 VectorSum (self ),
175+ GraphApiFinalizeGraph (self , RUNTIMES .SYCL , 0 , "Gromacs" ),
176+ GraphApiFinalizeGraph (self , RUNTIMES .SYCL , 1 , "Gromacs" ),
177+ GraphApiFinalizeGraph (self , RUNTIMES .SYCL , 0 , "Llama" ),
178+ GraphApiFinalizeGraph (self , RUNTIMES .SYCL , 1 , "Llama" ),
172179 ]
173180
174181 # Add UR-specific benchmarks
@@ -1005,3 +1012,71 @@ def bin_args(self) -> list[str]:
10051012 f"--measureMode={ self .measure_mode } " ,
10061013 "--iterations=1000" ,
10071014 ]
1015+
1016+
1017+ class GraphApiFinalizeGraph (ComputeBenchmark ):
1018+ def __init__ (
1019+ self ,
1020+ bench ,
1021+ runtime : RUNTIMES ,
1022+ rebuild_graph_every_iteration ,
1023+ graph_structure ,
1024+ ):
1025+ self .rebuild_graph_every_iteration = rebuild_graph_every_iteration
1026+ self .graph_structure = graph_structure
1027+ self .iterations = 10000
1028+ # LLama graph is about 10X the size of Gromacs, so reduce the
1029+ # iterations to avoid excessive benchmark time.
1030+ if graph_structure == "Llama" :
1031+ self .iterations /= 10
1032+
1033+ super ().__init__ (
1034+ bench ,
1035+ f"graph_api_benchmark_{ runtime .value } " ,
1036+ "FinalizeGraph" ,
1037+ runtime ,
1038+ )
1039+
1040+ def explicit_group (self ):
1041+ return f"FinalizeGraph, GraphStructure: { self .graph_structure } "
1042+
1043+ def description (self ) -> str :
1044+ what_is_measured = ""
1045+
1046+ if self .rebuild_graph_every_iteration == 0 :
1047+ what_is_measured = (
1048+ "It measures finalizing the same modifiable graph repeatedly "
1049+ "over multiple iterations."
1050+ )
1051+ else :
1052+ what_is_measured = (
1053+ "It measures finalizing a unique modifiable graph per iteration."
1054+ )
1055+
1056+ return (
1057+ "Measures the time taken to finalize a SYCL graph, using a graph "
1058+ f"structure based on the usage of graphs in { self .graph_structure } . "
1059+ f"{ what_is_measured } "
1060+ )
1061+
1062+ def name (self ):
1063+ return f"graph_api_benchmark_{ self .runtime .value } FinalizeGraph rebuildGraphEveryIter:{ self .rebuild_graph_every_iteration } graphStructure:{ self .graph_structure } "
1064+
1065+ def display_name (self ) -> str :
1066+ return f"{ self .runtime .value .upper ()} FinalizeGraph, rebuildGraphEveryIter { self .rebuild_graph_every_iteration } , graphStructure { self .graph_structure } "
1067+
1068+ def get_tags (self ):
1069+ return [
1070+ "graph" ,
1071+ runtime_to_tag_name (self .runtime ),
1072+ "micro" ,
1073+ "finalize" ,
1074+ "latency" ,
1075+ ]
1076+
1077+ def bin_args (self ) -> list [str ]:
1078+ return [
1079+ f"--iterations={ self .iterations } " ,
1080+ f"--rebuildGraphEveryIter={ self .rebuild_graph_every_iteration } " ,
1081+ f"--graphStructure={ self .graph_structure } " ,
1082+ ]
0 commit comments