Revert "Merge pull request #17247 from igas/fix-deprecations"

This reverts commit 997f1575f78bf6a2d12b8665a55807d51fe964df, reversing
changes made to f919d5f5ea75f0e56a57643e5a0472367a98625f.

See https://github.com/rails/rails/pull/17247#issuecomment-58895078
Document the propose of tools/profile
Do not use deprecated `exists?` method