이 문서에서는 BigQuery 고급 런타임을 사용 설정 및 중지하는 방법과 고급 런타임이 쿼리 성능에 미치는 영향을 평가하는 방법을 설명합니다.
역할 및 권한
구성 설정을 지정하는 데 필요한 권한을 얻으려면 관리자에게 프로젝트 또는 조직에 대한 BigQuery 관리자(roles/bigquery.admin) IAM 역할을 부여해 달라고 요청하세요.
역할 부여에 대한 자세한 내용은 프로젝트, 폴더, 조직에 대한 액세스 관리를 참조하세요.
BigQuery 프로젝트에서 고급 런타임을 사용 설정하면 추가 비용 없이 쿼리 지연 시간과 슬롯 소비를 줄이는 쿼리 프로세서의 기능이 사용 설정됩니다.
향상된 벡터화
벡터화된 실행은 CPU 캐시 크기에 맞춰 정렬된 블록의 데이터 열에서 작동하고 단일 명령, 다중 데이터(SIMD) 명령어를 사용하는 쿼리 처리 모델입니다. 향상된 벡터화는 BigQuery의 벡터화된 쿼리 실행을 쿼리 처리의 다음 측면으로 확장합니다.
Capacitor 스토리지 형식 내에서 특수 데이터 인코딩을 활용하면 인코딩된 데이터에서 필터 평가 작업을 실행할 수 있습니다.
특수 인코딩은 쿼리 계획을 통해 전파되므로 인코딩된 상태에서 더 많은 데이터를 처리할 수 있습니다.
결정론적 함수와 상수 표현식을 평가하기 위해 표현식 폴딩을 구현하면 BigQuery에서 복잡한 조건자를 상수 값으로 단순화할 수 있습니다.
짧은 쿼리 최적화
BigQuery는 일반적으로 셔플 중간 레이어를 사용하여 분산 환경에서 쿼리를 실행합니다. 짧은 쿼리 최적화는 단일 단계로 실행할 수 있는 쿼리를 동적으로 식별하여 지연 시간과 슬롯 소비를 줄입니다. 쿼리가 단일 단계로 실행될 때 전문화된 인코딩을 더 효과적으로 사용할 수 있습니다.
이러한 최적화는 작업 시작, 유지보수, 결과 검색 지연 시간을 최소화하는 선택적 작업 생성 모드와 함께 사용할 때 가장 효과적입니다.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["필요한 정보가 없음","missingTheInformationINeed","thumb-down"],["너무 복잡함/단계 수가 너무 많음","tooComplicatedTooManySteps","thumb-down"],["오래됨","outOfDate","thumb-down"],["번역 문제","translationIssue","thumb-down"],["샘플/코드 문제","samplesCodeIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-08-26(UTC)"],[],[],null,["# Use the BigQuery advanced runtime\n=================================\n\n|\n| **Preview**\n|\n|\n| This feature is subject to the \"Pre-GA Offerings Terms\" in the General Service Terms section\n| of the [Service Specific Terms](/terms/service-terms#1).\n|\n| Pre-GA features are available \"as is\" and might have limited support.\n|\n| For more information, see the\n| [launch stage descriptions](/products#product-launch-stages).\n| **Note:** To provide feedback or request support for this feature, send email to [bqarfeedback@google.com](mailto:bqarfeedback@google.com).\n\nThis document describes how to enable and disable the BigQuery\nadvanced runtime, and how to evaluate the advanced runtime's effects on your\nquery performance.\n\nRoles and permissions\n---------------------\n\n\nTo get the permissions that\nyou need to specify a configuration setting,\n\nask your administrator to grant you the\n\n\n[BigQuery Admin](/iam/docs/roles-permissions/bigquery#bigquery.admin) (`roles/bigquery.admin`)\nIAM role on your project or organization.\n\n\nFor more information about granting roles, see [Manage access to projects, folders, and organizations](/iam/docs/granting-changing-revoking-access).\n\n\nYou might also be able to get\nthe required permissions through [custom\nroles](/iam/docs/creating-custom-roles) or other [predefined\nroles](/iam/docs/roles-overview#predefined).\n\nFeatures\n--------\n\nEnabling the advanced runtime on a BigQuery project turns on\nfeatures in the query processor that reduce query latency and slot consumption\nat no additional cost.\n\n### Enhanced vectorization\n\nVectorized execution is a query processing model that operates on columns of\ndata in blocks that align with CPU cache size and uses\nsingle instruction, multiple data (SIMD) instructions. Enhanced vectorization\nextends the vectorized query execution in BigQuery to\nthe following aspects of query processing:\n\n- By leveraging specialized data encodings within the Capacitor storage format, filter evaluation operations can be executed on the encoded data.\n- Specialized encodings are propagated through the query plan, which allows more data to be processed while it's still encoded.\n- By implementing expression folding to evaluate deterministic functions and constant expressions, BigQuery can simplify complex predicates into constant values.\n\n### Short query optimizations\n\nBigQuery typically executes queries in a distributed environment\nusing a shuffle intermediate layer. Short query optimizations\ndynamically identify queries that can be run as a\nsingle stage, reducing latency and slot consumption. Specialized encodings can\nbe used more effectively when a query is run in a single stage.\nThese optimizations are most effective when used with\n[optional job creation mode](/bigquery/docs/running-queries#optional-job-creation),\nwhich minimizes job startup, maintenance, and result retrieval latency.\n\nEligibility for short query optimization is dynamic and influenced by\nthe following factors:\n\n- The predicted size of the data scan.\n- The amount of data movement required.\n- The selectivity of query filters.\n- The type and physical layout of the data in storage.\n- The overall query structure.\n- The [historical statistics](/bigquery/docs/history-based-optimizations) of past query executions.\n\nEnable the advanced runtime\n---------------------------\n\nTo enable the advanced runtime for your project or organization, use the\n[`ALTER PROJECT`](/bigquery/docs/reference/standard-sql/data-definition-language#alter_project_set_options_statement)\nor\n[`ALTER ORGANIZATION`](/bigquery/docs/reference/standard-sql/data-definition-language#alter_organization_set_options_statement)\nstatement to change the\n[default configuration](/bigquery/docs/default-configuration). In the\nstatement, set the `query_runtime` argument to `'advanced'`. For example: \n\n ALTER PROJECT \u003cvar translate=\"no\"\u003e\u003cspan class=\"devsite-syntax-n\"\u003ePROJECT_NAME\u003c/span\u003e\u003c/var\u003e\n SET OPTIONS (\n `region-\u003cvar translate=\"no\"\u003eLOCATION\u003c/var\u003e.query_runtime` = 'advanced'\n );\n\nReplace the following:\n\n- \u003cvar translate=\"no\"\u003ePROJECT_NAME\u003c/var\u003e: the name of the project\n- \u003cvar translate=\"no\"\u003eLOCATION\u003c/var\u003e: the location of the project\n\nIt can take several minutes for the change to take effect.\n\nOnce you've enabled the advanced runtime, qualifying queries in the project or organization\nuse the advanced runtime regardless of which user created the\nquery job.\n\nDisable the advanced runtime\n----------------------------\n\nTo disable the advanced runtime for your project or organization, use the\n`ALTER PROJECT` or `ALTER ORGANIZATION` statement to change the\n[default configuration](/bigquery/docs/default-configuration). In the\nstatement, set the `query_runtime` argument to `NULL`. For example: \n\n ALTER PROJECT \u003cvar translate=\"no\"\u003e\u003cspan class=\"devsite-syntax-n\"\u003ePROJECT_NAME\u003c/span\u003e\u003c/var\u003e\n SET OPTIONS (\n `region-\u003cvar translate=\"no\"\u003eLOCATION\u003c/var\u003e.query_runtime` = NULL\n );\n\nReplace the following:\n\n- \u003cvar translate=\"no\"\u003ePROJECT_NAME\u003c/var\u003e: the name of the project\n- \u003cvar translate=\"no\"\u003eLOCATION\u003c/var\u003e: the location of the project\n\nIt can take several minutes for the change to take effect.\n\nEvaluate query performance\n--------------------------\n\nYou can use the\n[administrative job explorer](/bigquery/docs/admin-jobs-explorer) and\n[`INFORMATION_SCHEMA` views](/bigquery/docs/information-schema-intro) to\nevaluate the effect of the advanced runtime on query execution time and slot\nusage.\n\nFollow these steps to evaluate query performance with and without the\nadvanced runtime enabled:\n\n1. In the Google Cloud console, go to the **BigQuery** page.\n\n [Go to BigQuery](https://console.cloud.google.com/bigquery)\n2. Open a new tab in the query editor.\n\n3. [Disable the use of cached query results](/bigquery/docs/cached-results#disabling_retrieval_of_cached_results)\n for that query tab.\n\n4. Type or copy your test queries into the query tab.\n\n5. Run your test queries a few times to establish baseline performance.\n After each run, determine the query performance metrics as follows:\n\n 1. [View the query execution details](/bigquery/docs/admin-jobs-explorer#view_query_execution_details) in the administrative job explorer.\n 2. Retrieve job performance data from the\n [`INFORMATION_SCHEMA.JOBS_BY_USER` view](/bigquery/docs/information-schema-jobs-by-user)\n by running the following query in a new query tab:\n\n SELECT\n job_id,\n end_time - start_time AS duration,\n total_slot_ms,\n query\n FROM\n `region-us`.INFORMATION_SCHEMA.JOBS_BY_USER\n WHERE\n creation_time \u003e TIMESTAMP_SUB(CURRENT_TIMESTAMP(), INTERVAL 7 DAY)\n AND job_type='QUERY'\n AND total_slot_ms IS NOT NULL\n ORDER BY\n creation_time DESC,\n query ASC\n LIMIT 1000;\n\n6. [Enable the advanced runtime](#enable-advanced-runtime).\n\n7. Repeat Step 5.\n\n8. Compare the query latency and slot usage metrics for the test queries\n from before and after you enabled the advanced runtime."]]