IC power pin connection for noise immunity and decoupling

There's been much talk on other Q&A threads on how to connect decoupling capacitors to an IC, resulting in two completely opposite approaches to the problem:

  • (a) Place decoupling capacitors as close as possible to the IC power pins.
  • (b) Connect the IC power pins as close as possible to the power planes, then place the decoupling capacitors as close as possible, but respecting the vias.