Just a minor point in case you weren't already aware of it... you said you need to sort the filenames by "time created", but you're using the mtime, which is the "last modify time". But I don't know if you can do any better than that, since AFAIK there is no way to retrieve the original creation time of a file (at least under Linux).
See perldoc -f stat for more details.