def _get_architecture_or_default(environment):
    """Returns the current target architecture or the default architecture if none
    has been explicitly set.

    @param  environment  Environment the target architecture will be looked up from
    @returns The name of the target architecture from the environment or a default"""

    architecture = environment['TARGET_ARCH']
    if architecture is None:
        return 'x64'
    else:
        return architecture