Can Dragon Broodmother+Elemental Mastery be triggered to provide elemental tokens before upkeep resolves?
Yes.



When dealing with keyword abilities, it's best to start by looking up their exact definition.


  702.81a Devour is a static ability. “Devour N” means “As this object enters the battlefield, you may sacrifice any number of creatures. This permanent enters the battlefield with N +1/+1 counters on it for each creature sacrificed this way.”


Dragon Broodmother's ability is a triggered ability, which means you'll get priority before it resolves.

The choice of creatures to sacrifice is made on resolution, so they don't need to exist when the ability is added to the stack.

So, you can activate the ability granted by Elemental Mastery in response to Dragon Broodmother's ability being added to the stack (i.e. after it's been added to the stack, but before it resolves). Having been placed on the stack last, the ability granted by Elemental Mastery will resolve first.