I have long been fascinated by woodpeckers drumming on trees because the tree is basically an instrument. This is a good case of (1) an animal implementing an instinct and (2) the thinking required on the animal's part.
The big thing is selecting the tree. Drumming is generally considered to be the equivalent of bird song, so it proclaims a territory. So the first thing the woodpecker has to do is to pick a territory. My guess is that this is based on picking a nesting site. Given the nest site the choice of a drum tree is constrained by distance. The woodpecker cannot just go off and find a good drum tree somewhere.
A good drum tree is probably relatively rare. It is typically a standing, but still hard, dead tree with no top and little or no bark. Having rotten wood or a top or bark would all dampen the sound of the drumming. I doubt that the woodpecker tries every tree so they probably know what they are looking for by instinct, but picking the right tree is a local decision.
Thus the woodpecker is solving a two variable local optimization problem, which is not simple. That is, it has to find a good drum tree that is close enough to the nest site to do the job of territorial announcement. I imagine this involves a lot of looking and testing.
If the bird uses more than one drum tree then there is also the issue of deciding which one to use at any given time. This is a separate local decision process.
It is also interesting that woodpeckers sometimes use buildings for drumming. This means that the instinct is not confined to looking for a tree. They are looking for a way to make a certain sound, which is a relatively abstract desire.
The point is that, just as with our other cases, instinct may give the woodpecker knowledge and a desire to act but local decisions are still required. Making these decisions requires thought, as well as the use of concepts.