llvm / llvm/llvm-project

[libc++] update fetch min/max apis to use builtins in compilers that have them

Open
#187,869 0 comments 0 reactions 0 assignees View on GitHub
libc++
Dominant language
LLVM
Stars
40.5k
Forks
18.7k
PR merge metrics
PR metrics pending

Description

#186694 implements P0493 min/max APIs in libc++.
This initial implementation uses compare-exchange loops since these are properly supported by all targets.
This issue tracks optimizing this implementation to use builtins in compilers that have them available and correctly implemented.

Contributor guide

Open the contributing guide

Research direction

Start with #186694 and locate the libc++ implementation of the P0493 min/max APIs. Compare the existing compare-exchange loops with compiler builtins available on supported targets, then verify that supported compilers use the builtins while other targets retain the portable behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.