Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Build fails with clang-cl: SVML _mm_pow_ps gated on _MSC_VER alone

オープン 初心者向け
#2,329 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

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

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
82/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
静か
技術スタック
cpp
領域
build-system

調査の方向性

FixedFunctionOpCPU.cpp から始め、_MSC_VER と OCIO_USE_AVX を使用する 2 つの SVML _mm_pow_ps プリプロセッサゲートを見つけます。clang-cl -c -arch:AVX で再現し、その後、OCIO_USE_AVX を有効にした状態で clang-cl ビルドが既存の ssePower() パスを使用して成功することを確認します。

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

説明

FixedFunctionOpCPU.cpp gates the SVML _mm_pow_ps path on _MSC_VER >= 1920 alone. clang-cl
defines _MSC_VER (1951 for clang 22.1.8) but ships no SVML, so the build breaks whenever
OCIO_USE_AVX is on.

Minimal:

#include <immintrin.h>
__m128 f(__m128 x, __m128 e) { return _mm_pow_ps(x, e); }
> clang-cl -c -arch:AVX t.cpp
t.cpp(2,39): error: use of undeclared identifier '_mm_pow_ps'

Excluding the compiler in the gate is enough, and clang-cl then takes the existing ssePower() path
like any other non-MSVC compiler:

-#if (_MSC_VER >= 1920) && (OCIO_USE_AVX)
+#if (_MSC_VER >= 1920) && (OCIO_USE_AVX) && !defined(__clang__)

main has 2 such sites; 2.5.2 has 4, the extra two being the dispatch arms in
GetFixedFunctionCPURenderer.

clang 22.1.8, x86_64-pc-windows-msvc. Reproduced against 2.5.2 and main.

主要言語
C++
スター
2.1k
フォーク
503
平均マージ
8日 3時間
マージ済み PR(30日)
10

環境構築

はじめの一歩

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

AcademySoftwareFoundation/OpenColorIO のほかの issue

AcademySoftwareFoundation/OpenColorIO の issue をすべて見る

似ている issue

C++ の issue をもっと見る

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

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