Good questions.
I would think that there might be times when an AI wouldn't build them due to the adjustment, but not myself as a player. The AI classically favors quantity over quality as it is, quite happy to build troops in any city it can regardless of the kind of troops those cities end up producing.
As a player with my particular playstyle, I value the quality of my troops over just about every other consideration. For me, even tech and population growth will often take a backseat to xp bonuses. If I'm that hard off for troops that somehow quality means more than quantity then I'm buying them or slaving them and not waiting regardless of the cost.
A change doesn't have to necessarily affect decisions, but in some cases, just the consequences of those decisions. Many decisions in Civ are neither right nor wrong, just a judgment call and this would certainly follow suit.
I believe there would already be an inherited ability for the ai to evaluate the adjustment where the ai would consider that there is a slight delay imposed on their troop builds by building this. I would hope, without immediately reviewing the code, that they would still 'feel', as I, a human player feels, that making their troops a bit more expensive in exchange for XP benefit is more than worth it. This is to the point that if the AI doesn't take it into account and operates as normal, then that, too, is just fine.
What it SHOULD adjust a bit, and I'm thinking that it would be again an inherited consideration into the current coding, is the way it evaluates the desirability of building some units over others for particular roles. I believe it already considers the build costs of units vs their benefits no? We may need to teach it there's a benefit to troops that, as a result of this adjustment, cost a bit more to build, but since the verdict is still out on whether such troops would be 'better due to receiving double ups on xp bonuses' or 'worse due to extra vulnerabilities', especially with an adjustment of this nature (meaning the buildings adding production costs to the units) tending to weight that consideration towards 'better', than its hard to quite say yet if the ai should really have much of a weight adjustment improvement over what it already evaluates.
Without a herculean effort in coding, the AI will never consider everything to quite the depth players can. I'd say human personality would play more of a role in how this change would affect their play decisions and perhaps the same could be built into the AI decision making. In fact, this highlights the fact that many ai determinations are not made currently in light of various personality based strategies, but could eventually be made to. If the leaderheads defined themselves as a Quality Troop Priority, a Quantity Troop Priority, or a balance in between, it could be taken into consideration when looking at how to interact with xp sources and any consequences they may deliver as well.
This reminds me... I've been considering a project down the road that I'd most certainly want your help with (so we're talking WAAAAAAY down the road) that makes it possible for players to play against ai personalities that represent the various members of the mod team that have been playing long enough to be able to proceduralize their game decisions in all areas.