已合并
fix(machine): Stop raising stitch_function_max_num with unroll in non-memory-driven mode #5434
songyangyang18创建于 8月13日
fix(machine): Stop raising stitch_function_max_num with unroll in non-memory-driven mode #5434
已合并
共 1 个文件变更+2-1
| @@ -112,9 +112,10 @@ void CalcWorkspacePlatform(WorkspaceDesc& wsDesc) | |||
| 112 | RuntimeWorkspaceConfig LoadRuntimeWorkspaceConfig(uint32_t maxUnrollTimes) | 112 | RuntimeWorkspaceConfig LoadRuntimeWorkspaceConfig(uint32_t maxUnrollTimes) |
| 113 | { | 113 | { |
| 114 | RuntimeWorkspaceConfig cfg; | 114 | RuntimeWorkspaceConfig cfg; |
| 115 | - cfg.stitchNumMax = EffectiveStitchNumMax(maxUnrollTimes); | ||
| 116 | cfg.parallelism = config::GetRuntimeOption<uint32_t>(DEVICE_SCHED_PARALLELISM); | 115 | cfg.parallelism = config::GetRuntimeOption<uint32_t>(DEVICE_SCHED_PARALLELISM); |
| 117 | cfg.maxWorkspaceBytes = GetMaxWorkspaceBytes(); | 116 | cfg.maxWorkspaceBytes = GetMaxWorkspaceBytes(); |
| 117 | + cfg.stitchNumMax = (cfg.maxWorkspaceBytes == 0) ? ConfiguredStitchFunctionMaxNum() : | ||
| 118 | + EffectiveStitchNumMax(maxUnrollTimes); | ||
| 118 | return cfg; | 119 | return cfg; |
| 119 | } | 120 | } |
| 120 | 121 | ||