0Pricing
CUDA Academy · レッスン

オンデマンドのページ移行

ページフォールトによってデータが使用場所へ移動します。

「オンデマンドのページ移行」はCoddyKit上の無料CUDA Academyレッスンです。 これはレッスン2/4です。 下記で完全なレッスンを無料で読むことができます。その後、ブラウザ内の組み込みコードエディタと24時間対応のAIチューターでハンズオン演習できます。 これはCUDA Academy学習パスの一部であり、ウェブとCoddyKitアプリ全体で進捗が同期されます。 CUDA Academyコースには全4レッスンが含まれています。

このレッスンの一部はまだ翻訳されておらず、英語で表示されています。

Where Does the Data Live?

With managed memory the data has no fixed home. It quietly moves between CPU and GPU through on-demand page migration, following wherever you use it.

Memory Comes in Pages

The system tracks memory in fixed chunks called pages, often 4 KB or 64 KB. Migration happens one page at a time, not byte by byte.

A Page Fault Triggers It

When the GPU touches a page that lives on the CPU, it raises a page fault. The driver pauses, copies that page over, then lets the thread continue.

Data Follows the Access

The rule is simple: data migrates to whoever uses it. Write on the CPU and pages live there; read in a kernel and they move to the GPU.

First Touch Is the Slow One

The cost shows up on the first access from a new side. After the page arrives, later reads on that same device are fast and local.

Ping-Pong Hurts

If the CPU and GPU keep touching the same pages in turns, they bounce back and forth. This ping-pong migration can quietly wreck your throughput.

Faults Add Up

Each fault carries setup overhead, so thousands of tiny faults are costly. Migrating in bulk beats faulting one scattered page after another.

Locality Still Matters

Even with automatic migration, good access patterns win. Threads reading nearby addresses pull in whole pages efficiently instead of scattering faults.

Oversubscription Is Allowed

Migration lets you allocate more than the GPU holds. Pages flow in as needed and old ones evict, so huge datasets still run, just slower.

You Can See the Faults

Profilers like Nsight Systems show migration traffic and fault counts. Spotting heavy migration tells you exactly where to add hints next.

Convenience With a Catch

On-demand migration is wonderfully automatic, but the faults are not free. Knowing the cost is what lets you fix it with prefetch and advice.

Quick Check

Let us make sure you know what kicks off a migration.

Recap: On-Demand Migration

You saw that managed pages migrate on a fault to whoever uses them. First touch is slow, ping-pong hurts, and bulk movement wins. Onward! 🚀

よくある質問

「オンデマンドのページ移行」レッスンは無料ですか?

はい。「オンデマンドのページ移行」の完全なテキストはこのウェブで無料で読めます。インタラクティブに演習し(組み込みコードエディタと24時間対応のAIチューター)、CUDA Academyコースの残りをアンロックするには、CoddyKit PROにアップグレードしてください。 CUDA Academyコースには全4レッスンが含まれています。

「オンデマンドのページ移行」で何を学びますか?

ページフォールトによってデータが使用場所へ移動します。 ブラウザで直接実行するハンズオンコードでCUDA Academyを演習し、24時間対応のAIチューターがレッスンを進める中での質問に答えます。

CUDA Academyを始めるのに経験は必要ですか?

事前経験は必要ありません。CoddyKitのCUDA Academyは初級者から上級者向けに構成されているため、ここから始めるか最初から始めて、自分のペースで進むことができます。 これはレッスン2/4です。

「オンデマンドのページ移行」レッスンにはどのくらい時間がかかりますか?

ほとんどのCoddyKitレッスンは約5~10分かかります。各レッスンはコンパクトでインタラクティブなので、着実に進歩し、ウェブとアプリ全体で正確に前回の場所から再開できます。

このCUDA Academyレッスンでコードを書いて実行できますか?

はい。すべてのCUDA Academyレッスンに組み込みコードエディタが含まれているため、ブラウザでリアルコードを書いて実行し、即座のAIフィードバックを取得できます。ローカル設定は不要です。

このコースのすべてのレッスン

  1. 1つのポインターを両方で使う
  2. オンデマンドのページ移行
  3. cudaMemPrefetchAsyncでプリフェッチする
  4. cudaMemAdviseでヒントを与える
← CUDA Academyに戻る