Boost logo

Boost-Build :

Subject: [Boost-build] Cannot build boost 1.63 with Windows Intel compiler because cpu_relax
From: Blower, Melanie (melanie.blower_at_[hidden])
Date: 2017-03-09 19:17:03


Hello,
I'm trying to build the boost 1.63 library with the Intel 17.0 compiler (latest update) in the vs2015 environment. Several targets fail to build because the definition of the cpu_relax macro isn't correct.

This change corrects the problem and allows the build to complete successfully. Is this the right way to correct the problem?

diff _unchanged/boost_1_63_0/boost/fiber/detail/cpu_relax.hpp boost_1_63_0/boost/fiber/detail/cpu_relax.hpp
17c17
< #if BOOST_COMP_MSVC
---
> # if BOOST_COMP_MSVC || BOOST_COMP_MSVC_EMULATED
40c40
< # if BOOST_COMP_MSVC
---
> # if BOOST_COMP_MSVC || BOOST_COMP_MSVC_EMULATED
 
Without this change I get a message like this:

./boost/fiber/detail/spinlock_ttas.hpp(66): error: invalid constant in assembly language instruction
                      asm volatile ("pause" ::: "memory");;
                                    ^

This change allows the macro to compile to YieldProcessor()

I work for Intel, on the Intel C++ compiler.

Thanks and regards, Melanie Blower


Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk