Hello Andrew,
They are perfect synonyms when they are both adjectives and mean "complete, total" as learner mentioned before.
However they have some specific definitions and expression modes where they couldn't be interchangeable such as:
Entire:
- "entire" could mean * not broken or damaged ,intact* .In that sense it is not a synonym of "whole".
- "entire" means also an animal or any being that is not castrated and sexually competent as in "an entire horse" ,that couldn't be substituted for "whole horse".
- "entire" could be an adjective as well as a noun ,but as a noun it is a less common word for "entirety" as in " an entire" which refers to an uncastrated adult male horse.
Whole:
- When you say "whole number" it means having no fractional or decimal part; integral. You can't say "entire number" instead.
- It could also mean of, relating to, or designating a relationship established by descent from the same parents; full as in "whole brothers" ,they are not called "entire brothers".
- "whole" could be an adjective as well as an adverb or a noun as in
the expression " as a whole" , here it is not interchangeable with "entire".
- "whole " refers as well to being restored to vigorous good health ("Whole in mind and body").