View Issue Details

IDProjectCategoryView StatusLast Update
0001589OpenMPTGeneralpublic2022-04-12 04:15
ReporterIcy_Guidance Assigned Tomanx  
PrioritylowSeverityminorReproducibilityalways
Status closedResolutionno change required 
Platformx64OSWindowsOS Version7
Product VersionOpenMPT 1.30.03.00 / libopenmpt 0.6.2 (upgrade first) 
Summary0001589: Long save times.
Description

Why is it, that when I save a module, it takes 12 seconds to save?

TagsNo tags attached.
Has the bug occurred in previous versions?No
Tested code revision (in case you know it)

Activities

manx

manx

2022-04-11 06:25

administrator   ~0005152

In contrast to most other software, OpenMPT actually cares to really save your data to persistent storage. By default, Windows (or other operating systems) do not write saved data immediately to disk, but instead keeps it in its internal cache for some time in order to improve performance. OpenMPT however explicitly flushes the saved file's data cache to disk before continuing.

You can disable cache flushing in OpenMPT by setting the hidden setting [Misc]FlushFileBuffersOnSave=false (see https://wiki.openmpt.org/Manual:_Hidden_Settings#.5BMisc.5D) in order to improve performance.
However, PLEASE NOTE that this will cause data loss if your system crashes some time AFTER saving (I'm not sure about the current write-back policies in Windows, but I would guess something in the ballpark of 30 seconds).

VST Plugins could also additionally contribute to longer save times.

What kind of disk/storage are you using?

manx

manx

2022-04-11 06:31

administrator   ~0005153

Last edited: 2022-04-11 06:37

Also, which version of OpenMPT did you use previously?

Cache flushing was added in 1.28.

Saga Musix

Saga Musix

2022-04-11 07:14

administrator   ~0005154

Last edited: 2022-04-11 07:14

Also, please provide the song that is taking 12 seconds to save, because without knowing how many samples or VST plugins you use, it could be entirely expected.

PS: Feel free to switch to MilkyTracker. I see you edited the bug description since you submitted it so maybe you regret your childish comment already, but empty threats like "I WILL SWITCH TO SOFTWARE X IF YOU DON'T DO Y!!!" don't help anyone and will in fact make it less likely that I will be willing to help solving your problem. Use MilkyTracker as much as you want, I don't care. I even contribute to its code occasionally.

Icy_Guidance

Icy_Guidance

2022-04-11 18:59

reporter   ~0005155

Ehh, personally, I prefer... both!

Icy_Guidance

Icy_Guidance

2022-04-11 19:02

reporter   ~0005156

I disabled cache flushing, but it still takes a little long; 10 seconds at best. Any other ways?

Saga Musix

Saga Musix

2022-04-11 19:11

administrator   ~0005157

Without providing the requested information it's hard to tell what the issue is:

1) the actual module you are trying to save and
2) what kind of storage media (hard disk, SSD, USB 2.0 flash drive, etc.) you are trying to save it to

You can mark a comment as private if you cannot share the module publicly.

Icy_Guidance

Icy_Guidance

2022-04-11 19:12

reporter   ~0005158

Update: The module had long save times because of some large "reference" samples, which I removed.

Saga Musix

Saga Musix

2022-04-11 19:16

administrator   ~0005159

That explains it then. If having those large samples is important to you and you prefer faster save times with IT/MPTM files, you can turn off sample compression by setting the two hidden settings described here to the value 0: https://forum.openmpt.org/index.php?topic=4961.0 - other formats don't have compressed samples so these settings doesn't affect them.
Sample compression can take a bit longer compared to just writing raw sample data to disk.

Alternatively if you are working with the MPTM format, you can make use of External Samples so that the sample data doesn't have to be explicitly saved to the module file every time, reducing the time it takes to save the file even further.

Issue History

Date Modified Username Field Change
2022-04-11 06:07 Icy_Guidance New Issue
2022-04-11 06:10 Icy_Guidance Severity major => block
2022-04-11 06:10 Icy_Guidance Description Updated
2022-04-11 06:25 manx Assigned To => manx
2022-04-11 06:25 manx Status new => feedback
2022-04-11 06:25 manx Note Added: 0005152
2022-04-11 06:27 manx Priority immediate => low
2022-04-11 06:27 manx Severity block => minor
2022-04-11 06:31 manx Note Added: 0005153
2022-04-11 06:37 manx Note Edited: 0005153
2022-04-11 06:57 Icy_Guidance Description Updated
2022-04-11 07:14 Saga Musix Note Added: 0005154
2022-04-11 07:14 Saga Musix Note Edited: 0005154
2022-04-11 18:59 Icy_Guidance Note Added: 0005155
2022-04-11 18:59 Icy_Guidance Status feedback => assigned
2022-04-11 19:02 Icy_Guidance Note Added: 0005156
2022-04-11 19:03 Icy_Guidance Has the bug occurred in previous versions? NO!!! => No
2022-04-11 19:11 Saga Musix Note Added: 0005157
2022-04-11 19:11 Saga Musix Status assigned => feedback
2022-04-11 19:12 Icy_Guidance Note Added: 0005158
2022-04-11 19:12 Icy_Guidance Status feedback => assigned
2022-04-11 19:16 Saga Musix Note Added: 0005159
2022-04-11 21:43 Saga Musix Status assigned => closed
2022-04-11 21:43 Saga Musix Resolution open => no change required