Some small tweaks to date_has_time and date_has_date to speed things up a bit.
Basically, return early when granularity isn't an array.
Second, use isset instead of array_intersect with count and a typecast.
I've included an XHProf showing the performance difference for date_has_time. A similar savings is gained from date_has_date.