Ibuprofen works quite well before surgery, because it is primarily an anti-inflammatory drug. It reduces inflammation and, in doing so, reduces pain. However, after surgery, there usually isn't much inflammation and the pain-killing power of Ibuprofen is nowhere near as great as that of Tylenol. In fact, as a straight pain killer, it's not very good.
In addition, like all non-steroidal anti-inflammatory drugs (NSAIDs) Ibuprofen affects your platelet function, causing a tendency to bleed. It has been known to cause catastrophic bleeding from the stomach, may cause kidney damage, pre-dispose to heart disease and can slow down bone healing. It isn't the harmless little wonder drug it is advertised to be.
I have a minor bleeding disorder, due to a deficiency of one of the enzymes in my platelets, and I must never take any NSAID, including Aspirin.