nest X64Function in its own block to avoid clang errors related to goto usage