[libcxx-commits] [pstl] r368285 - [pstl] Error out when the backend is left unspecified

Eric Fiselier via libcxx-commits libcxx-commits at lists.llvm.org
Fri Aug 9 01:13:44 PDT 2019


If I understand this correctly, the headers now require CMake build and
configuration steps before
they've valid?

Code should be valid at rest -- without any intervention, configuration,
setup, or build steps.

/Eric



On Thu, Aug 8, 2019 at 8:42 AM Louis Dionne via libcxx-commits <
libcxx-commits at lists.llvm.org> wrote:

> Author: ldionne
> Date: Thu Aug  8 05:43:13 2019
> New Revision: 368285
>
> URL: http://llvm.org/viewvc/llvm-project?rev=368285&view=rev
> Log:
> [pstl] Error out when the backend is left unspecified
>
> Instead of silently falling back to the serial backend, it's better if
> we fail loudly when the parallel backend is left unspecified. Since we
> have a __pstl_config_site header, a backend should always be specified.
>
> Modified:
>     pstl/trunk/include/pstl/internal/pstl_config.h
>
> Modified: pstl/trunk/include/pstl/internal/pstl_config.h
> URL:
> http://llvm.org/viewvc/llvm-project/pstl/trunk/include/pstl/internal/pstl_config.h?rev=368285&r1=368284&r2=368285&view=diff
>
> ==============================================================================
> --- pstl/trunk/include/pstl/internal/pstl_config.h (original)
> +++ pstl/trunk/include/pstl/internal/pstl_config.h Thu Aug  8 05:43:13 2019
> @@ -19,9 +19,7 @@
>  #define _PSTL_VERSION_PATCH (_PSTL_VERSION % 10)
>
>  #if !defined(_PSTL_PAR_BACKEND_SERIAL) && !defined(_PSTL_PAR_BACKEND_TBB)
> -// TODO: In the future, we need to handle this setting using a
> configure-time
> -//       option and something like a __config_site header.
> -#    define _PSTL_PAR_BACKEND_SERIAL
> +#    error "A parallel backend must be specified"
>  #endif
>
>  // Check the user-defined macro for warnings
>
>
> _______________________________________________
> libcxx-commits mailing list
> libcxx-commits at lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/libcxx-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20190809/788259fb/attachment.html>


More information about the libcxx-commits mailing list