Researchers Pete Warden and Alasdair Allan have discovered a file on the iPhone and 3G-enabled iPads that contain the “latitude and longitude of the phone’s recorded coordinates along with a timestamp.” This file is also copied to the owner’s computer when synced. There appears to be no current use for the data and Apple doesn’t seem to be transferring the data to itself. See the full article here.
Warden and Alasdair have created a webpage with more information and a downloadable application to check what data your iPhone or iPad has retained.