'Generates the account data portion of the sync response. Populates
`sync_result_builder` with the result.
Args:
sync_result_builder(SyncResultBuilder)
Returns:
Deferred(dict): A dictionary containing the per room account data.'

@defer.inlineCallbacks
def _generate_sync_entry_for_account_data(self, sync_result_builder):

    sync_config = sync_result_builder.sync_config
    user_id = sync_result_builder.sync_config.user.to_string()
    since_token = sync_result_builder.since_token
    if (since_token and (not sync_result_builder.full_state)):
        (account_data, account_data_by_room) = (yield self.store.get_updated_account_data_for_user(user_id, since_token.account_data_key))
        push_rules_changed = (yield self.store.have_push_rules_changed_for_user(user_id, int(since_token.push_rules_key)))
        if push_rules_changed:
            account_data['m.push_rules'] = (yield self.push_rules_for_user(sync_config.user))
    else:
        (account_data, account_data_by_room) = (yield self.store.get_account_data_for_user(sync_config.user.to_string()))
        account_data['m.push_rules'] = (yield self.push_rules_for_user(sync_config.user))
    account_data_for_user = sync_config.filter_collection.filter_account_data([{'type': account_data_type, 'content': content} for (account_data_type, content) in account_data.items()])
    sync_result_builder.account_data = account_data_for_user
    defer.returnValue(account_data_by_room)
