<!DOCTYPE html>
<html lang="vi" data-theme="auto">
<head>

<link rel="preconnect" href="https://www.googletagmanager.com">
<script >(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
  new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
  j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
  'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
  })(window,document,'script','dataLayer','GTM-W8MVQXG');</script>
  
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="theme-color" content="#00add8">
<link rel="canonical" href="https://go.dev/src/internal/trace/tracev2/EXPERIMENTS">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Material+Icons">
<link rel="stylesheet" href="/css/styles.css">
<link rel="icon" href="/images/favicon-gopher.png" sizes="any">
<link rel="apple-touch-icon" href="/images/favicon-gopher-plain.png"/>
<link rel="icon" href="/images/favicon-gopher.svg" type="image/svg+xml">
<link rel="me" href="https://hachyderm.io/@golang">

  
  <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
  new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
  j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
  'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
  })(window,document,'script','dataLayer','GTM-W8MVQXG');</script>
  
<script src="/js/site.js"></script>
<meta name="og:url" content="https://go.dev/src/internal/trace/tracev2/EXPERIMENTS">
<meta name="og:title" content=" - The Go Programming Language">
<title> - The Go Programming Language</title>

<meta name="og:image" content="https://go.dev/doc/gopher/gopher5logo.jpg">
<meta name="twitter:image" content="https://go.dev/doc/gopher/gopherbelly300.jpg">
<meta name="twitter:card" content="summary">
<meta name="twitter:site" content="@golang">
</head>
<body class="Site">
  
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-W8MVQXG"
  height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
  


<header class="Site-header js-siteHeader">
  <div class="Header Header--dark">
    <nav class="Header-nav">
      <a href="/">
        <img
          class="js-headerLogo Header-logo"
          src="/images/go-logo-white.svg"
          alt="Go">
      </a>
      <div class="skip-navigation-wrapper">
        <a class="skip-to-content-link" aria-label="Bỏ qua để đến nội dung chính" href="#main-content"> Bỏ qua đến nội dung chính </a>
      </div>
      <div class="Header-rightContent">
        <ul class="Header-menu">
          <li class="Header-menuItem ">
            <a href="#"  class="js-desktop-menu-hover" aria-label=Tại&#32;sao&#32;Go aria-describedby="dropdown-description">
              Tại sao Go <i class="material-icons" aria-hidden="true">arrow_drop_down</i>
            </a>
            <div class="screen-reader-only" id="dropdown-description" hidden>
              Nhấn Enter để bật/tắt menu thả xuống
            </div>
              <ul class="Header-submenu js-desktop-submenu-hover" aria-label="submenu">
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/solutions/case-studies">
                          Case Studies
                          
                        </a>
                    </div>
                    <p>Các vấn đề phổ biến mà doanh nghiệp giải quyết bằng Go</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/solutions/use-cases">
                          Use Cases
                          
                        </a>
                    </div>
                    <p>Câu chuyện về cách thức và lý do các công ty sử dụng Go</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/security/">
                          Bảo mật
                          
                        </a>
                    </div>
                    <p>Go giúp bạn bảo mật theo mặc định như thế nào</p>
                  </li>
              </ul>
          </li>
          <li class="Header-menuItem ">
            <a href="/learn/"  aria-label=Học aria-describedby="dropdown-description">
              Học 
            </a>
            <div class="screen-reader-only" id="dropdown-description" hidden>
              Nhấn Enter để bật/tắt menu thả xuống
            </div>
          </li>
          <li class="Header-menuItem ">
            <a href="#"  class="js-desktop-menu-hover" aria-label=Tài&#32;liệu aria-describedby="dropdown-description">
              Tài liệu <i class="material-icons" aria-hidden="true">arrow_drop_down</i>
            </a>
            <div class="screen-reader-only" id="dropdown-description" hidden>
              Nhấn Enter để bật/tắt menu thả xuống
            </div>
              <ul class="Header-submenu js-desktop-submenu-hover" aria-label="submenu">
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/ref/spec">
                          Go Spec
                          
                        </a>
                    </div>
                    <p>Đặc tả ngôn ngữ Go chính thức</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/doc">
                          Hướng dẫn sử dụng Go
                          
                        </a>
                    </div>
                    <p>Giới thiệu đầy đủ về cách xây dựng phần mềm với Go</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="https://pkg.go.dev/std">
                          Thư viện chuẩn
                          
                        </a>
                    </div>
                    <p>Tài liệu tham chiếu cho thư viện chuẩn của Go</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/doc/devel/release">
                          Ghi chú bản phát hành
                          
                        </a>
                    </div>
                    <p>Tìm hiểu những điểm mới trong từng bản phát hành Go</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/doc/effective_go">
                          Effective Go
                          
                        </a>
                    </div>
                    <p>Mẹo viết code Go rõ ràng, hiệu quả và đúng phong cách</p>
                  </li>
              </ul>
          </li>
          <li class="Header-menuItem ">
            <a href="https://pkg.go.dev"  aria-label=Packages aria-describedby="dropdown-description">
              Packages 
            </a>
            <div class="screen-reader-only" id="dropdown-description" hidden>
              Nhấn Enter để bật/tắt menu thả xuống
            </div>
          </li>
          <li class="Header-menuItem ">
            <a href="#"  class="js-desktop-menu-hover" aria-label=Cộng&#32;đồng aria-describedby="dropdown-description">
              Cộng đồng <i class="material-icons" aria-hidden="true">arrow_drop_down</i>
            </a>
            <div class="screen-reader-only" id="dropdown-description" hidden>
              Nhấn Enter để bật/tắt menu thả xuống
            </div>
              <ul class="Header-submenu js-desktop-submenu-hover" aria-label="submenu">
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/talks/">
                          Recorded Talks
                          
                        </a>
                    </div>
                    <p>Video từ các sự kiện trước đây</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="https://www.meetup.com/pro/go">
                          Meetups
                           <i class="material-icons">open_in_new</i>
                        </a>
                    </div>
                    <p>Gặp gỡ các lập trình viên Go địa phương khác</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/wiki/Conferences">
                          Hội nghị
                           <i class="material-icons">open_in_new</i>
                        </a>
                    </div>
                    <p>Học hỏi và kết nối với các lập trình viên Go trên toàn thế giới</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/blog">
                          Go blog
                          
                        </a>
                    </div>
                    <p>Blog chính thức của dự án Go.</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        <a href="/help">
                          Dự án Go
                          
                        </a>
                    </div>
                    <p>Nhận trợ giúp và cập nhật thông tin từ Go</p>
                  </li>
                  <li class="Header-submenuItem">
                    <div>
                        Kết nối
                    </div>
                    <p></p>
                      <div class="Header-socialIcons">
                        
                        <a class="Header-socialIcon" aria-label="Kết nối qua google-groups (Mở trong cửa sổ mới)" href="https://groups.google.com/g/golang-nuts"><img src="/images/logos/social/google-groups.svg" /></a>
                        <a class="Header-socialIcon" aria-label="Kết nối qua github (Mở trong cửa sổ mới)" href="https://github.com/golang"><img src="/images/logos/social/github.svg" /></a>
                        <a class="Header-socialIcon" aria-label="Kết nối qua bluesky (Mở trong cửa sổ mới)" href="https://bsky.app/profile/golang.org"><img src="/images/logos/social/bluesky.svg" /></a>
                        <a class="Header-socialIcon" aria-label="Kết nối qua mastodon (Mở trong cửa sổ mới)" href="https://hachyderm.io/@golang"><img src="/images/logos/social/mastodon.svg" /></a>
                        <a class="Header-socialIcon" aria-label="Kết nối qua twitter (Mở trong cửa sổ mới)" href="https://twitter.com/golang"><img src="/images/logos/social/twitter.svg" /></a>
                        <a class="Header-socialIcon" aria-label="Kết nối qua reddit (Mở trong cửa sổ mới)" href="https://www.reddit.com/r/golang/"><img src="/images/logos/social/reddit.svg" /></a>
                        <a class="Header-socialIcon" aria-label="Kết nối qua slack (Mở trong cửa sổ mới)" href="https://invite.slack.golangbridge.org/"><img src="/images/logos/social/slack.svg" /></a>
                        <a class="Header-socialIcon" aria-label="Kết nối qua stack-overflow (Mở trong cửa sổ mới)" href="https://stackoverflow.com/tags/go"><img src="/images/logos/social/stack-overflow.svg" /></a>
                      </div>
                  </li>
              </ul>
          </li>
        </ul>
        <button class="Header-navOpen js-headerMenuButton Header-navOpen--white" aria-label="Mở điều hướng.">
        </button>
      </div>
    </nav>
    
  </div>
</header>
<aside class="NavigationDrawer js-header">
  <nav class="NavigationDrawer-nav">
    <div class="NavigationDrawer-header">
      <a href="/">
        <img class="NavigationDrawer-logo" src="/images/go-logo-blue.svg" alt="Go.">
      </a>
    </div>
    <ul class="NavigationDrawer-list">
        
          <li class="NavigationDrawer-listItem js-mobile-subnav-trigger  NavigationDrawer-hasSubnav">
            <a href="#"><span>Tại sao Go</span> <i class="material-icons">navigate_next</i></a>

            <div class="NavigationDrawer NavigationDrawer-submenuItem">
              <nav class="NavigationDrawer-nav">
                <div class="NavigationDrawer-header">
                  <a href="#"><i class="material-icons">navigate_before</i>Tại sao Go</a>
                </div>
                <ul class="NavigationDrawer-list">
                    <li class="NavigationDrawer-listItem">
                        <a href="/solutions/case-studies">
                          Case Studies
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="/solutions/use-cases">
                          Use Cases
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="/security/">
                          Bảo mật
                          
                        </a>
                      
                    </li>
                </ul>
              </div>
            </div>
          </li>

        
        
          <li class="NavigationDrawer-listItem ">
            <a href="/learn/">Học</a>
          </li>
        
        
          <li class="NavigationDrawer-listItem js-mobile-subnav-trigger  NavigationDrawer-hasSubnav">
            <a href="#"><span>Tài liệu</span> <i class="material-icons">navigate_next</i></a>

            <div class="NavigationDrawer NavigationDrawer-submenuItem">
              <nav class="NavigationDrawer-nav">
                <div class="NavigationDrawer-header">
                  <a href="#"><i class="material-icons">navigate_before</i>Tài liệu</a>
                </div>
                <ul class="NavigationDrawer-list">
                    <li class="NavigationDrawer-listItem">
                        <a href="/ref/spec">
                          Go Spec
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="/doc">
                          Hướng dẫn sử dụng Go
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="https://pkg.go.dev/std">
                          Thư viện chuẩn
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="/doc/devel/release">
                          Ghi chú bản phát hành
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="/doc/effective_go">
                          Effective Go
                          
                        </a>
                      
                    </li>
                </ul>
              </div>
            </div>
          </li>

        
        
          <li class="NavigationDrawer-listItem ">
            <a href="https://pkg.go.dev">Packages</a>
          </li>
        
        
          <li class="NavigationDrawer-listItem js-mobile-subnav-trigger  NavigationDrawer-hasSubnav">
            <a href="#"><span>Cộng đồng</span> <i class="material-icons">navigate_next</i></a>

            <div class="NavigationDrawer NavigationDrawer-submenuItem">
              <nav class="NavigationDrawer-nav">
                <div class="NavigationDrawer-header">
                  <a href="#"><i class="material-icons">navigate_before</i>Cộng đồng</a>
                </div>
                <ul class="NavigationDrawer-list">
                    <li class="NavigationDrawer-listItem">
                        <a href="/talks/">
                          Recorded Talks
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="https://www.meetup.com/pro/go">
                          Meetups
                           <i class="material-icons">open_in_new</i>
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="/wiki/Conferences">
                          Hội nghị
                           <i class="material-icons">open_in_new</i>
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="/blog">
                          Go blog
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <a href="/help">
                          Dự án Go
                          
                        </a>
                      
                    </li>
                    <li class="NavigationDrawer-listItem">
                        <div>Kết nối</div>
                        <div class="Header-socialIcons">
                          
                            <a class="Header-socialIcon" href="https://groups.google.com/g/golang-nuts"><img src="/images/logos/social/google-groups.svg" /></a>
                            <a class="Header-socialIcon" href="https://github.com/golang"><img src="/images/logos/social/github.svg" /></a>
                            <a class="Header-socialIcon" href="https://bsky.app/profile/golang.org"><img src="/images/logos/social/bluesky.svg" /></a>
                            <a class="Header-socialIcon" href="https://hachyderm.io/@golang"><img src="/images/logos/social/mastodon.svg" /></a>
                            <a class="Header-socialIcon" href="https://twitter.com/golang"><img src="/images/logos/social/twitter.svg" /></a>
                            <a class="Header-socialIcon" href="https://www.reddit.com/r/golang/"><img src="/images/logos/social/reddit.svg" /></a>
                            <a class="Header-socialIcon" href="https://invite.slack.golangbridge.org/"><img src="/images/logos/social/slack.svg" /></a>
                            <a class="Header-socialIcon" href="https://stackoverflow.com/tags/go"><img src="/images/logos/social/stack-overflow.svg" /></a>
                        </div>
                    </li>
                </ul>
              </div>
            </div>
          </li>

        
    </ul>
  </nav>
</aside>
<div class="NavigationDrawer-scrim js-scrim" role="presentation"></div>
<main class="SiteContent SiteContent--default" id="main-content">
  


<article class="Doc Article">










<div id="nav" class="TOC"></div>



<div class='markdown'>
<h1 id="trace-experiments">Trace experiments</h1>
<p>Execution traces allow for trialing new events on an experimental basis via
trace experiments.
This document is a guide that explains how you can define your own trace
experiments.</p>
<p>Note that if you&rsquo;re just trying to do some debugging or perform some light
instrumentation, then a trace experiment is way overkill.
Use <code>runtime/trace.Log</code> instead.
Even if you&rsquo;re just trying to create a proof-of-concept for a low-frequency
event, <code>runtime/trace.Log</code> will probably be easier overall if you can make
it work.</p>
<p>Consider a trace experiment if:</p>
<ul>
<li>The volume of new trace events will be relatively high, and so the events
would benefit from a more compact representation (creating new tables to
deduplicate data, taking advantage of the varint representation, etc.).</li>
<li>It&rsquo;s not safe to call <code>runtime/trace.Log</code> (or its runtime equivalent) in
the contexts you want to generate an event (for example, for events about
timers).</li>
</ul>
<h2 id="defining-a-new-experiment">Defining a new experiment</h2>
<p>To define a new experiment, modify <code>internal/trace/tracev2</code> to define a
new <code>Experiment</code> enum value.</p>
<p>An experiment consists of two parts: timed events and experimental batches.
Timed events are events like any other and follow the same format.
They are easier to order and require less work to make use of.
Experimental batches are essentially bags of bytes that correspond to
an entire trace generation.
What they contain and how they&rsquo;re interpreted is totally up to you, but
they&rsquo;re most often useful for tables that your other events can refer into.
For example, the AllocFree experiment uses them to store type information
that allocation events can refer to.</p>
<h3 id="defining-new-events">Defining new events</h3>
<ol>
<li>Define your new experiment event types (by convention, experimental events
types start at ID 127, so look for the <code>const</code> block defining events
starting there).</li>
<li>Describe your new events in <code>specs</code>.
Use the documentation for <code>Spec</code> to write your new specs, and check your
work by running the tests in the <code>internal/trace/tracev2</code> package.
If you wish for your event argument to be interpreted in a particular
way, follow the naming convention in
<code>src/internal/trace/tracev2/spec.go</code>.
For example, if you intend to emit a string argument, make sure the
argument name has the suffix <code>string</code>.</li>
<li>Add ordering and validation logic for your new events to
<code>src/internal/trace/order.go</code> by listing handlers for those events in
the <code>orderingDispatch</code> table.
If your events are always emitted in a regular user goroutine context,
then the handler should be trivial and just validate the scheduling
context to match userGoReqs.
If it&rsquo;s more complicated, see <code>(*ordering).advanceAllocFree</code> for a
slightly more complicated example that handles events from a larger
variety of execution environments.
If you need to encode a partial ordering, look toward the scheduler
events (names beginning with <code>Go</code>) or just ask someone for help.</li>
<li>Add your new events to the <code>tracev2Type2Kind</code> table in
<code>src/internal/trace/event.go</code>.</li>
</ol>
<h2 id="emitting-data">Emitting data</h2>
<h3 id="emitting-your-new-events">Emitting your new events</h3>
<ol>
<li>Define helper methods on <code>runtime.traceEventWriter</code> for emitting your
events.</li>
<li>Instrument the runtime with calls to these helper methods.
Make sure to call <code>traceAcquire</code> and <code>traceRelease</code> around the operation
your event represents, otherwise it will not be emitted atomically with
that operation completing, resulting in a potentially misleading trace.</li>
</ol>
<h3 id="emitting-experimental-batches">Emitting experimental batches</h3>
<p>To emit experimental batches, use the <code>runtime.unsafeTraceExpWriter</code> to
write experimental batches associated with your experiment.
Heed the warnings and make sure that while you write them, the trace
generation cannot advance.
Note that each experiment can only have one distinguishable set of
batches.</p>
<h2 id="recovering-experimental-data">Recovering experimental data</h2>
<h3 id="recovering-experimental-events-from-the-trace">Recovering experimental events from the trace</h3>
<p>Experimental events will appear in the event stream as an event with the
<code>EventExperimental</code> <code>Kind</code>.
Use the <code>Experimental</code> method to collect the raw data inserted into the
trace.
It&rsquo;s essentially up to you to interpret the event from here.
I recommend writing a thin wrapper API to present a cleaner interface if you
so desire.</p>
<h3 id="recovering-experimental-batches">Recovering experimental batches</h3>
<p>Parse out all the experimental batches from <code>Sync</code> events as they come.
These experimental batches are all for the same generation as all the
experimental events up until the next <code>Sync</code> event.</p>
</div>







</article>



</main>
<footer class="Site-footer">
  <div class="Footer">
    <div class="Container">
      <div class="Footer-links">
          <div class="Footer-linkColumn">
            <a href="/solutions/" class="Footer-link Footer-link--primary" aria-describedby="footer-description">
              Tại sao Go
            </a>
              <a href="/solutions/use-cases" class="Footer-link" aria-describedby="footer-description">
                Use Cases
              </a>
              <a href="/solutions/case-studies" class="Footer-link" aria-describedby="footer-description">
                Case Studies
              </a>
          </div>
          <div class="Footer-linkColumn">
            <a href="/learn/" class="Footer-link Footer-link--primary" aria-describedby="footer-description">
              Bắt đầu
            </a>
              <a href="/play" class="Footer-link" aria-describedby="footer-description">
                Playground
              </a>
              <a href="/tour/" class="Footer-link" aria-describedby="footer-description">
                Tour
              </a>
              <a href="https://stackoverflow.com/questions/tagged/go?tab=Newest" class="Footer-link" aria-describedby="footer-description">
                Stack Overflow
              </a>
              <a href="/help/" class="Footer-link" aria-describedby="footer-description">
                Trợ giúp
              </a>
          </div>
          <div class="Footer-linkColumn">
            <a href="https://pkg.go.dev" class="Footer-link Footer-link--primary" aria-describedby="footer-description">
              Packages
            </a>
              <a href="/pkg/" class="Footer-link" aria-describedby="footer-description">
                Thư viện chuẩn
              </a>
              <a href="https://pkg.go.dev/about" class="Footer-link" aria-describedby="footer-description">
                Giới thiệu về Go Packages
              </a>
          </div>
          <div class="Footer-linkColumn">
            <a href="/project" class="Footer-link Footer-link--primary" aria-describedby="footer-description">
              Giới thiệu
            </a>
              <a href="/dl/" class="Footer-link" aria-describedby="footer-description">
                Tải xuống
              </a>
              <a href="/blog/" class="Footer-link" aria-describedby="footer-description">
                Blog
              </a>
              <a href="https://github.com/golang/go/issues" class="Footer-link" aria-describedby="footer-description">
                Issue Tracker
              </a>
              <a href="/doc/devel/release" class="Footer-link" aria-describedby="footer-description">
                Ghi chú bản phát hành
              </a>
              <a href="/brand" class="Footer-link" aria-describedby="footer-description">
                Hướng dẫn thương hiệu
              </a>
              <a href="/conduct" class="Footer-link" aria-describedby="footer-description">
                Quy tắc ứng xử
              </a>
          </div>
          <div class="Footer-linkColumn">
            <a href="/wiki/#the-go-community" class="Footer-link Footer-link--primary" aria-describedby="footer-description">
              Kết nối
            </a>
              <a href="https://bsky.app/profile/golang.org" class="Footer-link" aria-describedby="footer-description">
                Bluesky
              </a>
              <a href="https://hachyderm.io/@golang" class="Footer-link" aria-describedby="footer-description">
                Mastodon
              </a>
              <a href="https://www.twitter.com/golang" class="Footer-link" aria-describedby="footer-description">
                Twitter
              </a>
              <a href="https://github.com/golang" class="Footer-link" aria-describedby="footer-description">
                GitHub
              </a>
              <a href="https://invite.slack.golangbridge.org/" class="Footer-link" aria-describedby="footer-description">
                Slack
              </a>
              <a href="https://reddit.com/r/golang" class="Footer-link" aria-describedby="footer-description">
                r/golang
              </a>
              <a href="https://www.meetup.com/pro/go" class="Footer-link" aria-describedby="footer-description">
                Meetup
              </a>
              <a href="https://golangweekly.com/" class="Footer-link" aria-describedby="footer-description">
                Golang Weekly
              </a>
          </div>
      </div>
    </div>
  </div>
  <div class="screen-reader-only" id="footer-description" hidden>
          Mở trong cửa sổ mới.
  </div>
  <div class="Footer">
    <div class="Container Container--fullBleed">
      <div class="Footer-bottom">
        <img class="Footer-gopher" src="/images/gophers/pilot-bust.svg" alt="Go Gopher">
        <ul class="Footer-listRow">
          <li class="Footer-listItem">
            <a href="/copyright" aria-describedby="footer-description">Bản quyền</a>
          </li>
          <li class="Footer-listItem">
            <a href="/tos" aria-describedby="footer-description">Điều khoản dịch vụ</a>
          </li>
          <li class="Footer-listItem">
            <a href="http://www.google.com/intl/en/policies/privacy/" aria-describedby="footer-description"
              target="_blank"
              rel="noopener">
              Chính sách quyền riêng tư
            </a>
            </li>
          <li class="Footer-listItem">
            <a
              href="/s/website-issue" aria-describedby="footer-description"
              target="_blank"
              rel="noopener"
              >
              Báo cáo sự cố
            </a>
          </li>
          <li class="Footer-listItem go-Footer-listItem">
            <button class="go-Button go-Button--text go-Footer-toggleTheme js-toggleTheme" aria-label="Chuyển đổi giao diện">
              <img
                data-value="auto"
                class="go-Icon go-Icon--inverted"
                height="24"
                width="24"
                src="/images/icons/brightness_6_gm_grey_24dp.svg"
                alt="Giao diện hệ thống">
              <img
                data-value="dark"
                class="go-Icon go-Icon--inverted"
                height="24"
                width="24"
                src="/images/icons/brightness_2_gm_grey_24dp.svg"
                alt="Giao diện tối">
              <img
                data-value="light"
                class="go-Icon go-Icon--inverted"
                height="24"
                width="24"
                src="/images/icons/light_mode_gm_grey_24dp.svg"
                alt="Giao diện sáng">
            </button>
          </li>
        </ul>
        <a class="Footer-googleLogo" target="_blank" href="https://google.com" rel="noopener">
          <img class="Footer-googleLogoImg" src="/images/google-white.png" alt="Logo Google">
        </a>
      </div>
    </div>
  </div>
  <script src="/js/jquery.js"></script>
  <script src="/js/carousels.js"></script>
  <script src="/js/searchBox.js"></script>
  <script src="/js/misc.js"></script>
  <script src="/js/hats.js"></script>
  <script src="/js/playground.js"></script>
  <script src="/js/godocs.js"></script>
  <script async src="/js/copypaste.js"></script>
</footer>
<section class="Cookie-notice js-cookieNotice">
  <div>go.dev sử dụng cookie của Google để cung cấp và nâng cao chất lượng dịch vụ cũng như
  phân tích lưu lượng truy cập. <a target=_blank href="https://policies.google.com/technologies/cookies">Tìm hiểu thêm.</a></div>
  <div><button class="go-Button">Đồng ý</button></div>
</section>
</body>
</html>


















