dotnet / runtime

.NET is a cross-platform runtime for cloud, mobile, desktop, and IoT apps.
https://docs.microsoft.com/dotnet/core/
MIT License
15.37k stars 4.75k forks source link

superpmi collection "mcs -strip" data corruption #107521

Open BruceForstall opened 2 months ago

BruceForstall commented 2 months ago

I was looking at the "SuperPMI collect realworld run linux x64 checked" job in superpmi collection https://dev.azure.com/dnceng/internal/_build/results?buildId=2533665&view=results

Several of the jobs show errors processing the MCH file, indicating memory corruption:

Partition6:

Running: /datadisks/disk1/work/B19A097C/p/superpmi/mcs -strip /datadisks/disk1/work/B19A097C/w/CE230A69/u/performance/methods_to_strip.mcl /datadisks/disk1/work/B19A097C/w/CE230A69/uploads/realworld.run..linux.x64.checked.mch_all.mch /datadisks/disk1/work/B19A097C/w/CE230A69/uploads/realworld.run..linux.x64.checked.mch
corrupted size vs. prev_size

-strip failed. Copying /datadisks/disk1/work/B19A097C/w/CE230A69/uploads/realworld.run..linux.x64.checked.mch_all.mch to /datadisks/disk1/work/B19A097C/w/CE230A69/uploads/realworld.run..linux.x64.checked.mch.

Apparently if the "strip" operation fails, we use the full (un-de-duplicated) file, which is non-fatal, but sub-optimal.

Partition3:

Running: /datadisks/disk1/work/B19A097C/p/superpmi/mcs -strip /datadisks/disk1/work/B19A097C/w/9BDF08C2/u/performance/methods_to_strip.mcl /datadisks/disk1/work/B19A097C/w/9BDF08C2/uploads/realworld.run..linux.x64.checked.mch_all.mch /datadisks/disk1/work/B19A097C/w/9BDF08C2/uploads/realworld.run..linux.x64.checked.mch
mcs: malloc.c:2617: sysmalloc: Assertion `(old_top == initial_top (av) && old_size == 0) || ((unsigned long) (old_size) >= MINSIZE && prev_inuse (old_top) && ((unsigned long) old_end & (pagesize - 1)) == 0)' failed.

-strip failed. Copying /datadisks/disk1/work/B19A097C/w/9BDF08C2/uploads/realworld.run..linux.x64.checked.mch_all.mch to /datadisks/disk1/work/B19A097C/w/9BDF08C2/uploads/realworld.run..linux.x64.checked.mch.

Looks like another symptom of memory corruption.

Partition0:

Running: /datadisks/disk1/work/B19A097C/p/superpmi/mcs -strip /datadisks/disk1/work/B19A097C/w/9BE40868/u/performance/methods_to_strip.mcl /datadisks/disk1/work/B19A097C/w/9BE40868/uploads/realworld.run..linux.x64.checked.mch_all.mch /datadisks/disk1/work/B19A097C/w/9BE40868/uploads/realworld.run..linux.x64.checked.mch
corrupted size vs. prev_size

-strip failed. Copying /datadisks/disk1/work/B19A097C/w/9BE40868/uploads/realworld.run..linux.x64.checked.mch_all.mch to /datadisks/disk1/work/B19A097C/w/9BE40868/uploads/realworld.run..linux.x64.checked.mch.

Also, nit: why do these filenames have two consecutive periods in them?

dotnet-policy-service[bot] commented 2 months ago

Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch See info in area-owners.md if you want to be subscribed.