Skip to content

Commit 7493b8b

Browse files
Revert "[QNN EP] Remove workaround for syntax error macro (microsoft#25923)" (microsoft#25939)
This reverts commit a3ad1f9.
1 parent 16a842a commit 7493b8b

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

onnxruntime/core/providers/qnn/builder/qnn_backend_manager.cc

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,12 @@ static const char* DlError() {
5656
#endif
5757
}
5858

59+
// Workaround for a missing comma in QNN_IR_GRAPH_CUSTOM_CONFIG_INIT.
60+
static QnnIrGraph_CustomConfig_t EmptyIrGraphConfig() {
61+
return {
62+
QNN_IR_GRAPH_CONFIG_OPTION_SERIALIZATION, {QNN_IR_GRAPH_SERIALIZATION_TYPE_FLAT_BUFFER, ""}};
63+
}
64+
5965
class QnnIrConfig : public QnnSerializerConfig {
6066
public:
6167
QnnIrConfig(std::string backend_path, std::string dlc_dir)
@@ -91,7 +97,7 @@ class QnnIrConfig : public QnnSerializerConfig {
9197

9298
private:
9399
static QnnConfigsBuilder<QnnGraph_Config_t, QnnIrGraph_CustomConfig_t> MakeConfigsBuilder() {
94-
return QnnConfigsBuilder<QnnGraph_Config_t, QnnIrGraph_CustomConfig_t>(QNN_GRAPH_CONFIG_INIT, QNN_IR_GRAPH_CUSTOM_CONFIG_INIT);
100+
return QnnConfigsBuilder<QnnGraph_Config_t, QnnIrGraph_CustomConfig_t>(QNN_GRAPH_CONFIG_INIT, EmptyIrGraphConfig());
95101
}
96102

97103
std::filesystem::path dlc_dir_;

0 commit comments

Comments
 (0)