> -----Original Message-----
> From: Damjan Marion <dmar...@me.com>
> Subject: Re: [vpp-dev] clang-9
> 
> 
> Dear Lijian,
> 
> I don’t see how this matters if neither gcc 9.2+ or clang-10 are available in
> ubuntu 18.04.
> For custom builds users can simply say make CC=whatever-compiler-they-
> want …
Not sure how 'CMAKE_C_COMPILER_NAMES' takes effect, but experiments show "make 
CC=gcc" can override "set(CMAKE_C_COMPILER_NAMES clang-10 clang-9 gcc-9 cc)" in 
CMakeLists.txt. It's a good way for custom builds with non-default compiler.

> 
> Also there is no N1 available in CSIT, so we cannot really judge about
> performance impact on the large number of different features.
> 
> —
> Damjan
> 
> > On 28 May 2020, at 09:50, Lijian Zhang <lijian.zh...@arm.com> wrote:
> >
> > Hi Damjan,
> > I got some feedback regarding switching default compiler from gcc to clang
> in VPP, from compiler team.
> >
> > " Neither LLVM nor GCC tune much for Neoverse N1, I think the difference is
> that GCC has better vectorization and a better optimized AArch64 backend.
> GCC10 has just been released and will likely do even better (it is now ~20%
> ahead of LLVM on SPEC)."
> >
> > " I was looking at the roadmap for LLVM (which is the backend for clang). I
> see plans for tuning for Zeus and Perseus, but just support for N1. I think 
> they
> fixed some alignment issues and replaced some intrinsics, but no specific N1
> tuning. LLVM is behind gcc in performance, by a decent amount."
> >
> > I did some benchmarking on L2/L3 single flow throughput btw gcc-9.2.0 (-
> march=armv8.2-a+crc+crypto -mtune=neoverse-n1) and clang-10 (-
> mcpu=neoverse-n1). From the results below, gcc-9.2.0 gives better throughput
> number (about 4%) than clang-10.
> >
> > clang-10:
> > L3: 11.04Mpps/10.99Mpps/11.02Mpps
> > L2: 11.55Mpps/11.56Mpps
> >
> > gcc-9.2.0
> > L3: 11.61Mpps/11.55Mpps/11.59Mpps
> > L2: 12.15Mpps/12.16Mpps
> >
> > Is it possible to restore gcc as the default compiler for vpp, or for vpp
> compiling on Arm CPU?
> > Is it possible to remove clang-9 dependency in Makefile, or make it applied
> for x86 only?
> > This dependency forces vpp compiling to use clang-9 always.
> >
> > diff --git a/Makefile b/Makefile
> > ifeq ($(OS_VERSION_ID),18.04)
> >        DEB_DEPENDS += python-dev python-all python-pip python-virtualenv
> >        DEB_DEPENDS += libssl-dev
> > -       DEB_DEPENDS += clang-9
> > diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
> > -set(CMAKE_C_COMPILER_NAMES clang-10 clang-9 gcc-9 cc)
> > +set(CMAKE_C_COMPILER_NAMES gcc-9 cc)
> >
> > Thanks.

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#16596): https://lists.fd.io/g/vpp-dev/message/16596
Mute This Topic: https://lists.fd.io/mt/73327785/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to