Skip to content

Commit cb9cd38

Browse files
asraacopybara-github
authored andcommitted
openfhe: use default value for evalAddCount / keySwitchCount when not specified in params
Fixes #1656 PiperOrigin-RevId: 743971798
1 parent c7af528 commit cb9cd38

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

lib/Dialect/Openfhe/Transforms/ConfigureCryptoContext.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -302,6 +302,8 @@ struct ConfigureCryptoContext
302302
}
303303

304304
// get evalAddCount/KeySwitchCount from func attribute, if present
305+
config.evalAddCount = 0;
306+
config.keySwitchCount = 0;
305307
if (auto openfheParamsAttr = op->getAttrOfType<mgmt::OpenfheParamsAttr>(
306308
mgmt::MgmtDialect::kArgOpenfheParamsAttrName)) {
307309
config.evalAddCount = openfheParamsAttr.getEvalAddCount();

0 commit comments

Comments
 (0)