Page MenuHomePhabricator

[ADT] APIntOps::ScaleBitMask(): introduce 'BitMergingApproach' switch
Needs ReviewPublic

Authored by lebedev.ri on Sep 17 2021, 9:05 AM.

Details

Reviewers
RKSimon
Summary

Not always do we want to greedily merge the bits

Diff Detail

Unit TestsFailed

TimeTest
1,300 msx64 debian > libomp.lock::omp_init_lock.c
Script: -- : 'RUN: at line 1'; /var/lib/buildkite-agent/builds/llvm-project/build/./bin/clang -fopenmp -pthread -fno-experimental-isel -I /var/lib/buildkite-agent/builds/llvm-project/build/projects/openmp/runtime/src -I /var/lib/buildkite-agent/builds/llvm-project/openmp/runtime/test -L /var/lib/buildkite-agent/builds/llvm-project/build/lib -I /var/lib/buildkite-agent/builds/llvm-project/openmp/runtime/test/ompt /var/lib/buildkite-agent/builds/llvm-project/openmp/runtime/test/lock/omp_init_lock.c -o /var/lib/buildkite-agent/builds/llvm-project/build/projects/openmp/runtime/test/lock/Output/omp_init_lock.c.tmp -lm -latomic && /var/lib/buildkite-agent/builds/llvm-project/build/projects/openmp/runtime/test/lock/Output/omp_init_lock.c.tmp

Event Timeline

lebedev.ri created this revision.Sep 17 2021, 9:05 AM

TBH I think you'd be better off splitting ScaleBitMask into 2 methods rather than using an enum - unless you have a strong use case for needing to select between the 2 at runtime