What is MAINFUN.EXE? It is hogging cpu as of yesterday 7th June 2012, but an avast scan raises no flag. I assume it is malware.
Download Malwarebytes’ Anti-Malware Downloads updates to it than run a Scan if you think the file is Malware. After the Scan is over use the Attachments feature on the Forums to post the logs Malwarebytes’ makes http://download.cnet.com/Malwarebytes-Anti-Malware/3000-8022_4-10804572.html?part=dl-10804572&subj=dl&tag=button
Edit: If it think it is malware than follow what this topic says http://forum.avast.com/index.php?topic=53253.0
Why should I have to download more software? Shouldn’t Avast be able to handle this? Incidentally, the problem is on another computer running XP. Is there any reason why I shouldn’t just delete the files - six of them, in two places? I find that they were installed in August 2011 and May 2012, but only modified (activated?) on 7th June, which was when I first noticed the problem of hogging CPU time. I am not a computer expert, and cannot undertake complicated procedures unaided.
Whilst I can find no specific hit for mainfun.exe it may not be a virus but adware, etc. that is why the choice of using a specific anti-malware tool to see what it thinks. Your choice to download or not.
You could also check the offending/suspect file at: VirusTotal - Multi engine on-line virus scanner and report the findings here, post the URL in the Address bar of the VT results page.
I would personally follow the advice you have already been offered - but another possibility might be to run an avast scan with PUP scanning turned on and see what that throws up?