AMPI datatypes: CkDDT_Struct ignores member trueLB; negative extents from Type_create_resized can terminate the program

オープン
#4,100 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
cpp
領域
backend, hpc

調査の方向性

Start in src/libs/ck-libs/ampi/ddt.C and read the CkDDT_Struct true lower bound calculation and the scan code changed in #4085. Reproduce the nested vector case with a negative displacement, then check MPI_Type_get_true_extent and scan buffer bounds; also try a resized datatype with a negative extent and count of at least two. Done when true lower bounds include member types and the negative-extent case no longer terminates the program.

索引モデルが issue の本文から書いたものです。

説明

Split out of #4072 (from Aditya's re-review of #4085; pre-existing on recharm, not fixed). Both in src/libs/ck-libs/ampi/ddt.C.

  1. CkDDT_Struct takes trueLB from the block displacements only and ignores each member type's own trueLB: struct{(0, 1, vector(2,1,-1,MPI_INT))} reports trueLB 0 but the vector writes at offset -4. MPI_Type_get_true_extent reports the same wrong value, and the scan (which since #4085 sizes its buffers from trueLB) writes just before its buffer for such types.
  2. Negative extents from MPI_Type_create_resized can terminate the program: with count >= 2 the scan's span count * max(extent, trueExtent) can be negative, std::vector throws, and the throw happens inside a noexcept function.

Related: #4085 (scan family).

主要言語
C++
スター
241
フォーク
62
平均マージ
1日 1時間
マージ済み PR(30日)
121

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

charmplusplus/charm のほかの issue

charmplusplus/charm の issue をすべて見る

似ている issue

C++ の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。