March 2018

PVS-Studio is now available on macOS: 64 weaknesses in the Apple's XNU Kernel

A new version of the PVS-Studio analyzer 6.23 is working under macOS, which allows you to check the projects written in C and C++. Our team decided to perform a XNU Kernel check to coincide it with this event.

PVS-Studio is now available on macOS: 64 weaknesses in the Apple's XNU Kernel

by Andrey Karpov

From the article:

Although the XNU Kernel is relatively small, it's a challenge to study the analyzer warnings alone, which takes much time. False positives make the check more complicated, since I haven't performed the preliminary analyzer configuration. I just quickly looked through the warnings, writing out code fragments that, in my opinion, represent interest. This is more than enough for writing a quite large article. PVS-Studio analyzer easily finds a large number of interesting bugs.

Emulating templated generic lambda expressions -- Krzysztof Ostrowski

Embedding and recovering the type information in generic lambda expressions.

Emulating templated generic lambda expressions

by Krzysztof Ostrowski

From the article:

One of the greatest advantages of lambda expressions is their locality. It is really comfortable to reason about the code if the most of its parts are in the "near" scope, and the inversion of control is limited. On the other hand, optimiser's life is much easier with lambdas (they are just syntactic sugar, thus their actual structure is defined by the compiler). Moreover, lambdas' opaque mangled names can drastically reduce compile times. Parametrically polymorphic (generic) lambda expressions introduce additional flexibility in algorithm implementation and minimise maintenance work.

Paradoxically, generic lambda expressions in C++17 are somewhat too generic. That characteristic announces itself in inability to fix the lambda parameters in advance. Unlike in function templates, we cannot specify the parameter types explicitly to effectively disable template argument deduction from the passed function arguments.

Some steps towards templated generic lambdas are going to be taken in C++20. For the time being, a simple technique that emulates templated generic lambdas proposed in this article may be reused.

HPX V1.1 released -- STE||AR Group

The STE||AR Group has released V1.0 of HPX -- A C++ Standard library for parallelism and concurrency.

HPX V1.1 Released

The newest version of HPX (V1.1) is now available for download! Please see here for the release notes.

HPX exposes an API fully conforming to the concurrency related parts of the C++11/C++14/C++17 standards, extended and applied to distributed and heterogeneous computing, and aligned with the ongoing standardization discussions.

    HPX is a general purpose parallel C++ runtime system for applications of any scale. It implements all of the related facilities as defined by the C++ Standard. As of this writing, HPX provides the only widely available open-source implementation of the new C++17 parallel algorithms. Additionally, HPX implements functionalities proposed as part of the ongoing C++ standardization process, such as large parts of the C++ Concurrency TS, task blocks, data-parallel algorithms, executors, index-based parallel for loops, and many more. It also extends the existing C++ Standard APIs to the distributed case (e.g. compute clusters) and for heterogeneous systems (e.g. GPUs).
    HPX seamlessly enables a new asynchronous C++ Standard Programming Model which tends to improve the parallel efficiency of our applications and helps reduce complexities usually associated with concurrency

CppCast Episode 142: Jacksonville Trip Report with Patrice Roy

Episode 142 of CppCast the only podcast for C++ developers by C++ developers. In this episode Rob and Jason are joined by Patrice Roy to discuss the Jacksonville C++ Committee meeting and the state of features that may make it into C++20, new Study Groups and much more.

CppCast Episode 142: Jacksonville Trip Report with Patrice Roy

by Rob Irving and Jason Turner

About the interviewee:

Patrice Roy has been playing with C++, either professionally, for pleasure or (most of the time) both for over 20 years. After a few years doing R&D and working on military flight simulators, he moved on to academics and has been teaching computer science since 1998. Since 2005, he’s been involved more specifically in helping graduate students and professionals from the fields of real-time systems and game programming develop the skills they need to face today’s challenges. The rapid evolution of C++ in recent years has made his job even more enjoyable.

He’s been a participating member in the ISO C++ Standards Committee since late 2014 and has been involved with the ISO Programming Language Vulnerabilities since late 2015. He has five kids, and his wife ensures their house is home to a continuously changing number of cats, dogs and other animals.

Visual Studio 2017 Version 15.7 Preview 2--Christine Ruana

Today Microsoft released the second preview of the next update: Visual Studio 2017 version 15.7:

Visual Studio 2017 Version 15.7 Preview 2

by Christine Ruana

C++ Standards Conformance Highlights (detailed C++ release notes here):

Implemented Template argument deduction for class templates:

​pair p{2, 2.5};

Full implementation of Expression SFINAE

Expand the using declaration to support pack expansion semantics for variadic base class members

Implemented parallel algorithms conforming to the ISO C++17 standard


Dependency Management For C++ -- Hans Klabbers

Dependency management is a missing piece in the C++ eco system.

Dependency Management For C++

by Hans Klabbers

About the article

The writer took part in the developer survey and followed up on the outcome. Depenendency management is seen as a missing piece in the C++ standard. The article is written as a response on a tweet by Bryce Lelbach and an article on medium by Corentin. It describes the author's ideas for dependency management. 

trip report: first ISO C++ meeting experience -- Vittorio Romeo

This trip report covers the author's first ISO C++ meeting experience. Vittorio talks about the most interesting interactions and papers discussed in Jacksonville, while also sharing some of his thoughts regarding controversial topics such as modules and 2D graphics.

trip report: first ISO C++ meeting experience

By Vittorio Romeo

From the article:

I'm back in London from Jacksonville, where I attended my first ISO C++ meeting. Apart from the long flights and long working hours, it has been a very enjoyable experience for multiple reasons: [...]

[...] almost every interaction when debating a paper was very well motivated, and I found myself thinking "that's a very good point" very often, even when two conflicting opinions were being stated one right after the other [...]

Guy Davidson's Jacksonville Trip Report

Having landed safely in Britain and recovered somewhat from his mystery illness, Guy has prepared a trip report, paying particular attention to the drama of the 2D Graphics paper and the unexpected interruption to the closing plenary.

Oh, lock-free circular buffers, yay! Hey, no 2D graphics? Jacksonville trip report

by Guy Davidson

From the article:

Right now, both library groups are processing fewer papers than they receive. There are 19 sessions of about two hours during each meeting, and LWG spent the first five sessions on P0214, Data-Parallel Vector Types & Operations (for the Parallelism TS), which defines some SIMD types. I was delighted to be in on this, and even offered to scribe but found it impossibly hard, unlike my stint in LEWG at Toronto. However, it was during the fourth of these sessions that I started to feel distinctly unwell.

Text Formatting at the ISO C++ standards meeting in Jacksonville--Victor Zverovich

A good library fro formatting in the standard, soon?

Text Formatting at the ISO C++ standards meeting in Jacksonville

by Victor Zverovich

From the article:

This week I attended the ISO C++ standards committee meeting to present the second revision of my paper P0645R1 Text Formatting, based on the {fmt} formatting library. The first revision was reviewed by Library Evolution Working Group (LEWG) in June 2017 in Toronto and there was a lot of feedback, particularly I’ve been asked to

  • investigate compile-time format string processing,
  • look at using or explain why not to use an output iterator,
  • use string_view,
  • allow pre-computation of output size,
  • add benchmarks.

It took me a while to address all the feedback, especially the first two items which required substantial API and implementation changes, so I had to skip the meeting in Albuquerque. However, this ultimately resulted in a much better API so I’m grateful to LEWG for the helpful guidance. Despite all the negative press covfefe “design by committee” sometimes works surprisingly well...

emBO++ 2018 Trip Report--Simon Brand

Were you there?

emBO++ 2018 Trip Report

by Simon Brand

From the article:

emBO++ is a conference focused on C++ on embedded systems in Bochum, Germany. This was it’s second year of operation, but the first that I’ve been along to. It was a great conference, so I’m writing a short report to hopefully convince more of you to attend next year!