91
« on: 02 September 2022, 06:02 »
"Why someone would not to parse the merge attribute (as declared inside M. A. M. E.'s XML) of a clone's rom name?"
Let's get back in time....clrmamepro was there before merging was there....and parent/clone relationships did exist before mamedevs introduced merge attributes. And there was a time where merge attributes were completely wrong or each rom had one and so on....back then it was not so reliable as today.
So...coming back from such ancient times, there needed to be a way to see which roms were shared and which were unique within a parent/clone relationship. clrmamepro did that by hash and name compare, i.e. identical hashes with different names were still 2 unique roms. And that's exactly what happens when you disable that option (which is enabled by default by the way). So it's a just a different way of finding out which roms are and which aren't shared.
Same applies for disk merge attributes.
"Hash Collision"
There are parent/clonerelations where roms have identical names but different hashes. So if you fully merge them, one gets overwritten. Unless you put them in subfolders. MAME would load them fine in subfolders when you use 7z/zips. So to prevent data loss when using full merged sets, cmpro can create such a subfolder for you (usually the name of the set but you can change it). "Single File" means, only the file in question gets the subfolder, single clone means, all (clone) files belonging to the clone with the hashcollision get the subfolder, "all clones in relationship" means, all clone files (there can be n clones for 1 parent) get the subfolder. So this option is more a matter of taste/cosmetics, e.g. if you want all or just single files with a subfolder.
"Normal mode" means, that only the set with a hash collision gets subfolders while "Hash Collision Name" means all sets (no matter if they have a collision or not". So with the latter one, you store your fully merged sets where the parent holds its roms on root level of the archive and each clone has a subfolder on its own.
"Your example"
It is correct for split merge mode.
For full merge mode, you wouldn't have mame/hotd4a/dvp-0003a.chd since it's a clone and also for chds, you would put them to the parent...so you'd have mame/hotd4/dvp-0003a.chd and mame/hotd4/dvp-0003b.chd.
Last but not least: This storing mechanism and tricks with subfolders to prevent overwriting of hash collisions isn't defined. MAME itself doesn't care. It follows the romof and deviceRef chain to locate files and doesn't care about names when loading, it loads by hash compare (at least when we talk about archived files).