0005-src-gallium-drivers-nouveau-codegen-nv50_ir_ra.cpp-p.patch 2.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. From f2ce27b761eeca301a109856f20ed9a8eb06796d Mon Sep 17 00:00:00 2001
  2. From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
  3. Date: Sat, 28 Dec 2019 21:49:43 +0100
  4. Subject: [PATCH] src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp: prefix
  5. isinf with std::
  6. Prefix isinf with std:: to fix the following build failure with gcc 4.9:
  7. ../src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp: In member function 'bool nv50_ir::GCRA::simplify()':
  8. ../src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp:1350:29: error: 'isinf' was not declared in this scope
  9. if (isinf(bestScore)) {
  10. ^
  11. ../src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp:1350:29: note: suggested alternative:
  12. In file included from /data/buildroot/buildroot-test/instance-0/output/host/opt/ext-toolchain/arm-buildroot-linux-uclibcgnueabi/include/c++/4.9.4/random:38:0,
  13. from /data/buildroot/buildroot-test/instance-0/output/host/opt/ext-toolchain/arm-buildroot-linux-uclibcgnueabi/include/c++/4.9.4/bits/stl_algo.h:66,
  14. from /data/buildroot/buildroot-test/instance-0/output/host/opt/ext-toolchain/arm-buildroot-linux-uclibcgnueabi/include/c++/4.9.4/algorithm:62,
  15. from ../src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp:26:
  16. /data/buildroot/buildroot-test/instance-0/output/host/opt/ext-toolchain/arm-buildroot-linux-uclibcgnueabi/include/c++/4.9.4/cmath:621:5: note: 'std::isinf'
  17. isinf(_Tp __x)
  18. ^
  19. Fixes:
  20. - http://autobuild.buildroot.org/results/599dc3478ed65d36fbf9f5e9625691dfa813b530
  21. Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
  22. [Upstream status:
  23. https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3227]
  24. ---
  25. src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp | 2 +-
  26. 1 file changed, 1 insertion(+), 1 deletion(-)
  27. diff --git a/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp b/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp
  28. index 6df2664da22..e81fb117213 100644
  29. --- a/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp
  30. +++ b/src/gallium/drivers/nouveau/codegen/nv50_ir_ra.cpp
  31. @@ -1345,7 +1345,7 @@ GCRA::simplify()
  32. bestMaxReg = it->maxReg;
  33. }
  34. }
  35. - if (isinf(bestScore)) {
  36. + if (std::isinf(bestScore)) {
  37. ERROR("no viable spill candidates left\n");
  38. return false;
  39. }
  40. --
  41. 2.24.0