Add regex-matching support for labels.

Change-Id: I510a83f761198e80946146770ebb64e4abc3bb96