Bug 102847 - swr fail to build with llvm-5.0.0
Summary: swr fail to build with llvm-5.0.0
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/Gallium/swr (show other bugs)
Version: 17.2
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: mesa-dev
QA Contact: mesa-dev
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-09-19 06:08 UTC by Laurent carlier
Modified: 2017-10-02 17:06 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Laurent carlier 2017-09-19 06:08:34 UTC
Log output:

  CXX      libmesaswr_la-swr_clear.lo
  CXX      libmesaswr_la-swr_context.lo
  CXX      libmesaswr_la-swr_draw.lo
  CXX      libmesaswr_la-swr_screen.lo
  CXX      libmesaswr_la-swr_state.lo
  CXX      libmesaswr_la-swr_tex_sample.lo
  CXX      libmesaswr_la-swr_scratch.lo
  CXX      libmesaswr_la-swr_shader.lo
  CXX      libmesaswr_la-swr_fence.lo
  CXX      libmesaswr_la-swr_fence_work.lo
  CXX      libmesaswr_la-swr_query.lo
  CXX      rasterizer/common/libmesaswr_la-formats.lo
  CXX      rasterizer/common/libmesaswr_la-os.lo
In file included from ./rasterizer/jitter/builder.h:74:0,
                 from swr_shader.cpp:34:
./rasterizer/jitter/gen_builder.hpp:504:43: error: ‘SynchronizationScope’ has not been declared
 FenceInst* FENCE(AtomicOrdering Ordering, SynchronizationScope SynchScope = CrossThread, const Twine &Name = "")
                                           ^~~~~~~~~~~~~~~~~~~~
./rasterizer/jitter/gen_builder.hpp:509:136: error: ‘SynchronizationScope’ has not been declared
 AtomicCmpXchgInst* ATOMIC_CMP_XCHG(Value *Ptr, Value *Cmp, Value *New, AtomicOrdering SuccessOrdering, AtomicOrdering FailureOrdering, SynchronizationScope SynchScope = CrossThread)
                                                                                                                                        ^~~~~~~~~~~~~~~~~~~~
./rasterizer/jitter/gen_builder.hpp:514:101: error: ‘SynchronizationScope’ has not been declared
 AtomicRMWInst* ATOMIC_RMW(AtomicRMWInst::BinOp Op, Value *Ptr, Value *Val, AtomicOrdering Ordering, SynchronizationScope SynchScope = CrossThread)
                                                                                                     ^~~~~~~~~~~~~~~~~~~~
./rasterizer/jitter/gen_builder.hpp:504:77: error: ‘CrossThread’ was not declared in this scope
 FenceInst* FENCE(AtomicOrdering Ordering, SynchronizationScope SynchScope = CrossThread, const Twine &Name = "")
                                                                             ^~~~~~~~~~~
./rasterizer/jitter/gen_builder.hpp:509:170: error: ‘CrossThread’ was not declared in this scope
 AtomicCmpXchgInst* ATOMIC_CMP_XCHG(Value *Ptr, Value *Cmp, Value *New, AtomicOrdering SuccessOrdering, AtomicOrdering FailureOrdering, SynchronizationScope SynchScope = CrossThread)
                                                                                                                                                                          ^~~~~~~~~~~
./rasterizer/jitter/gen_builder.hpp:514:135: error: ‘CrossThread’ was not declared in this scope
 AtomicRMWInst* ATOMIC_RMW(AtomicRMWInst::BinOp Op, Value *Ptr, Value *Val, AtomicOrdering Ordering, SynchronizationScope SynchScope = CrossThread)
                                                                                                                                       ^~~~~~~~~~~
  CXX      rasterizer/common/libmesaswr_la-rdtsc_buckets.lo
  CXX      rasterizer/common/libmesaswr_la-swr_assert.lo
  CXX      rasterizer/codegen/libmesaswr_la-gen_knobs.lo
  CXX      libmesaswr_la-swr_loader.lo
make[5]: *** [Makefile:2441: libmesaswr_la-swr_shader.lo] Error 1
make[5]: *** Waiting for unfinished jobs....
make[5]: Leaving directory '/build/mesa/src/mesa-17.2.1/src/gallium/drivers/swr'
make[4]: *** [Makefile:1503: all] Error 2
make[4]: Leaving directory '/build/mesa/src/mesa-17.2.1/src/gallium/drivers/swr'
make[3]: *** [Makefile:601: all-recursive] Error 1
make[3]: Leaving directory '/build/mesa/src/mesa-17.2.1/src/gallium'
make[2]: *** [Makefile:853: all-recursive] Error 1
make[2]: Leaving directory '/build/mesa/src/mesa-17.2.1/src'
make[1]: *** [Makefile:644: all] Error 2
make[1]: Leaving directory '/build/mesa/src/mesa-17.2.1/src'
make: *** [Makefile:649: all-recursive] Error 1
Comment 1 Eric Engestrom 2017-09-19 10:24:36 UTC
Confirmed, hitting the same issue on git.
Bisecting now.
Comment 2 Eric Engestrom 2017-09-19 10:41:09 UTC
(In reply to Eric Engestrom from comment #1)
> Confirmed, hitting the same issue on git.
> Bisecting now.

Hmm... bisecting failed, the build is always passing now? It might have just needed a clean build.

I'm assuming you were building the arch pkgbuild in a clean chroot?
If not, can you try that?
Comment 3 Eric Engestrom 2017-09-19 12:51:11 UTC
(In reply to Eric Engestrom from comment #2)
> I'm assuming you were building the arch pkgbuild in a clean chroot?
> If not, can you try that?

Just tested a clean build with the current PKGBUILD (1234495e9d2ed5ff07b5, 4h ago) with swr added to the gallium drivers, and it fails...

My best guess right now is that there's been a bug that's been fixed, but if you built before the fix it needs a clean build, and the fix hasn't made its way on the 17.2 branch.

I don't have time to look more into this though. Good luck :)
Comment 4 Juan A. Suarez 2017-10-02 15:23:12 UTC
Patch https://patchwork.freedesktop.org/patch/177834/ has been landed upstream.

Does it fix this issue?
Comment 5 Laurent carlier 2017-10-02 17:06:05 UTC
(In reply to Juan A. Suarez from comment #4)
> Patch https://patchwork.freedesktop.org/patch/177834/ has been landed
> upstream.
> 
> Does it fix this issue?

yes, it's fixed


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.