Skip to content

Fix narrowing conversion error on riscv64#1924

Merged
doug-walker merged 2 commits into
AcademySoftwareFoundation:mainfrom
phanen:fix-narrowing
Jan 22, 2024
Merged

Fix narrowing conversion error on riscv64#1924
doug-walker merged 2 commits into
AcademySoftwareFoundation:mainfrom
phanen:fix-narrowing

Conversation

@phanen
Copy link
Copy Markdown
Contributor

@phanen phanen commented Dec 27, 2023

Fix a narrowing conversion error on RISCV64 build. (#1888)

[6/477] Building CXX object tests/utils/CMakeFiles/test_utils_exec.dir/StringUtils_tests.cpp.o
FAILED: tests/utils/CMakeFiles/test_utils_exec.dir/StringUtils_tests.cpp.o 
/usr/bin/c++  -I/build/opencolorio/src/OpenColorIO-2.3.1/tests/testutils/.. -isystem /build/opencolorio/src/OpenColorIO-2.3.1/src/utils/.. -march=rv64gc -mabi=lp64d -O2 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security         -fstack-clash-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/opencolorio/src=/usr/src/debug/opencolorio -flto=auto -ffat-lto-objects -O3 -DNDEBUG -std=c++14 -fvisibility=hidden -fvisibility-inlines-hidden -DUSE_GCC -Wall -Wextra -Wswitch-enum -MD -MT tests/utils/CMakeFiles/test_utils_exec.dir/StringUtils_tests.cpp.o -MF tests/utils/CMakeFiles/test_utils_exec.dir/StringUtils_tests.cpp.o.d -o tests/utils/CMakeFiles/test_utils_exec.dir/StringUtils_tests.cpp.o -c /build/opencolorio/src/OpenColorIO-2.3.1/tests/utils/StringUtils_tests.cpp
/build/opencolorio/src/OpenColorIO-2.3.1/tests/utils/StringUtils_tests.cpp: In function ‘void ociotest_StringUtils_trim()’:
/build/opencolorio/src/OpenColorIO-2.3.1/tests/utils/StringUtils_tests.cpp:56:32: error: narrowing conversion of ‘-1’ from ‘int’ to ‘char’ [-Wnarrowing]
   56 |         constexpr char ref2[]{ -1, -2, -3, '\0' };
      |                                ^~
/build/opencolorio/src/OpenColorIO-2.3.1/tests/utils/StringUtils_tests.cpp:56:36: error: narrowing conversion of ‘-2’ from ‘int’ to ‘char’ [-Wnarrowing]
   56 |         constexpr char ref2[]{ -1, -2, -3, '\0' };
      |                                    ^~
/build/opencolorio/src/OpenColorIO-2.3.1/tests/utils/StringUtils_tests.cpp:56:40: error: narrowing conversion of ‘-3’ from ‘int’ to ‘char’ [-Wnarrowing]
   56 |         constexpr char ref2[]{ -1, -2, -3, '\0' };

@linux-foundation-easycla
Copy link
Copy Markdown

linux-foundation-easycla Bot commented Dec 27, 2023

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: phanen / name: phanium (d8a60c0)
  • ✅ login: doug-walker / name: Doug Walker (f4fee85)

@remia
Copy link
Copy Markdown
Collaborator

remia commented Jan 14, 2024

Thank you @phanen, it looks like your commit was not signed off, would you mind fixing that?

@phanen
Copy link
Copy Markdown
Contributor Author

phanen commented Jan 14, 2024

Sorry, fixed now.

Signed-off-by: phancb <nxhsdu@qq.com>
@doug-walker doug-walker merged commit a95febc into AcademySoftwareFoundation:main Jan 22, 2024
doug-walker added a commit to autodesk-forks/OpenColorIO that referenced this pull request Jan 29, 2024
…1924)

Signed-off-by: phancb <nxhsdu@qq.com>
Co-authored-by: Doug Walker <doug.walker@autodesk.com>
(cherry picked from commit a95febc)
Signed-off-by: Doug Walker <doug.walker@autodesk.com>
doug-walker added a commit that referenced this pull request Jan 30, 2024
* Fix ssse3 detection typo (#1929)

Signed-off-by: Mark Reid <mindmark@gmail.com>
(cherry picked from commit 003b6a1)
Signed-off-by: Doug Walker <doug.walker@autodesk.com>

* fix: use system `include pystring.h` for `ConfigUtils.cpp` (#1921)

Signed-off-by: Rui Chen <rui@chenrui.dev>
Co-authored-by: Doug Walker <doug.walker@autodesk.com>
(cherry picked from commit e747e9c)
Signed-off-by: Doug Walker <doug.walker@autodesk.com>

* Fix narrowing conversion error on riscv64 (#1924)

Signed-off-by: phancb <nxhsdu@qq.com>
Co-authored-by: Doug Walker <doug.walker@autodesk.com>
(cherry picked from commit a95febc)
Signed-off-by: Doug Walker <doug.walker@autodesk.com>

* Add manylinux_2_28 Python wheels (#1933)

Signed-off-by: Rémi Achard <remiachard@gmail.com>
Co-authored-by: Michael Dolan <michdolan@gmail.com>
Co-authored-by: Doug Walker <doug.walker@autodesk.com>
(cherry picked from commit f925099)
Signed-off-by: Doug Walker <doug.walker@autodesk.com>

* Enhance ociochecklut to print the output after each step in a multi-t… (#1925)

* Enhance ociochecklut to print the output after each step in a multi-transform LUT

Signed-off-by: pylee <penne.y.lee@intel.com>

* Review feedback to enable printe of transforms list when using -s flag.

Signed-off-by: pylee <penne.y.lee@intel.com>

* Print transform description for each step instead.

Signed-off-by: pylee <penne.y.lee@intel.com>

---------

Signed-off-by: pylee <penne.y.lee@intel.com>
Co-authored-by: Doug Walker <doug.walker@autodesk.com>
(cherry picked from commit aadf595)
Signed-off-by: Doug Walker <doug.walker@autodesk.com>

* Fix AVX instructions used on CPUs that don't support them (#1935)

* Fix AVX instructions used on CPUs that don't support them

It's supposed to check all bits are enabled, not just one of them.
This causes a crash using OpenColorIO on older CPUs.

Thanks to Ray Molenkamp for help tracking this down.

Signed-off-by: Brecht Van Lommel <brecht@blender.org>

* Fix another case pointed out in review

Signed-off-by: Brecht Van Lommel <brecht@blender.org>

---------

Signed-off-by: Brecht Van Lommel <brecht@blender.org>
(cherry picked from commit 0c90ded)
Signed-off-by: Doug Walker <doug.walker@autodesk.com>

* Increment library version to 2.3.2

Signed-off-by: Doug Walker <doug.walker@autodesk.com>

---------

Signed-off-by: Mark Reid <mindmark@gmail.com>
Signed-off-by: Doug Walker <doug.walker@autodesk.com>
Signed-off-by: Rui Chen <rui@chenrui.dev>
Signed-off-by: phancb <nxhsdu@qq.com>
Signed-off-by: Rémi Achard <remiachard@gmail.com>
Signed-off-by: pylee <penne.y.lee@intel.com>
Signed-off-by: Brecht Van Lommel <brecht@blender.org>
Co-authored-by: Mark Reid <mindmark@gmail.com>
Co-authored-by: Rui Chen <rui@chenrui.dev>
Co-authored-by: phanium <91544758+phanen@users.noreply.github.com>
Co-authored-by: Rémi Achard <remiachard@gmail.com>
Co-authored-by: Michael Dolan <michdolan@gmail.com>
Co-authored-by: PenneLee <penne.y.lee@intel.com>
Co-authored-by: Brecht Van Lommel <brecht@blender.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants