Support more than one bundles in a single .kernel section
When compiling with Early Finalization enabled in HCC,
the resulting .kernel section of the host object now may
contain more than one device code bundles. This is to
teach the HIP runtime to correctly extract all the
bundles from the .kernel section.
[ROCm/hip commit: 30ce25e627]
Cette révision appartient à :
@@ -209,10 +209,16 @@ const unordered_map<hsa_isa_t, vector<vector<char>>>& code_object_blobs(bool reb
|
||||
nullptr);
|
||||
|
||||
for (auto&& blob : blobs) {
|
||||
Bundled_code_header tmp{blob};
|
||||
if (valid(tmp)) {
|
||||
for (auto&& bundle : bundles(tmp)) {
|
||||
r[triple_to_hsa_isa(bundle.triple)].push_back(bundle.blob);
|
||||
for (auto sub_blob = blob.begin(); sub_blob != blob.end(); ) {
|
||||
Bundled_code_header tmp(sub_blob, blob.end());
|
||||
if (valid(tmp)) {
|
||||
for (auto&& bundle : bundles(tmp)) {
|
||||
r[triple_to_hsa_isa(bundle.triple)].push_back(bundle.blob);
|
||||
}
|
||||
sub_blob+=tmp.bundled_code_size;
|
||||
}
|
||||
else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Référencer dans un nouveau ticket
Bloquer un utilisateur