The timing belt on that vehicle should be replaced every 60,000 miles. This job is more expensive on overhead cam Subaru engines than on most other vehicles, because the water pump must be removed in order to access the timing belt. Most shops hava a flat rate manual; which lists the typical amount of time that this job should take. You should be able to find out this figure from the dealership, as well as from most local shops. The flat rate time estimate should be the same, regardless of where you get it. Once you know the flat rate estimate, you can figure the cost for the job from any shop, if you know their hourly labor rate. Just multiply the flat rate number by the hourly labor rate.
For example; if the flat rate book says that changing the timing belt on a 2001 Legacy takes 3.5 hours, and a shop's labor rate is $65 per hour; then the labor charge for the job should be (3.5 times 65) which equals $227.50. The cost of parts will be additional. Some shops will charge a low hourly labor rate, but will mark up the parts more than other shops. So it is the total price, including parts, labor, tax and any incidental fees, which is most meaningful.