[all-commits] [llvm/llvm-project] 935570: [ConstExpr] Don't create div/rem expressions
Nikita Popov via All-commits
all-commits at lists.llvm.org
Tue Jul 5 06:55:11 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 935570b2ad808035a1fd9bf6fa894657babc8694
https://github.com/llvm/llvm-project/commit/935570b2ad808035a1fd9bf6fa894657babc8694
Author: Nikita Popov <npopov at redhat.com>
Date: 2022-07-05 (Tue, 05 Jul 2022)
Changed paths:
M clang/test/CodeGenCUDA/managed-var.cu
M clang/test/OpenMP/target_data_codegen.cpp
M clang/test/OpenMP/target_enter_data_codegen.cpp
M clang/test/OpenMP/target_enter_data_depend_codegen.cpp
M clang/test/OpenMP/target_exit_data_codegen.cpp
M clang/test/OpenMP/target_exit_data_depend_codegen.cpp
M clang/test/OpenMP/target_update_codegen.cpp
M clang/test/OpenMP/target_update_depend_codegen.cpp
M llvm/include/llvm/Analysis/TargetFolder.h
M llvm/include/llvm/IR/ConstantFolder.h
M llvm/include/llvm/IR/Constants.h
M llvm/lib/Analysis/ConstantFolding.cpp
M llvm/lib/Analysis/ScalarEvolution.cpp
M llvm/lib/IR/ConstantFold.cpp
M llvm/lib/IR/Constants.cpp
M llvm/lib/Transforms/InstCombine/InstCombineCalls.cpp
M llvm/test/Analysis/ScalarEvolution/ptrtoint-constantexpr-loop.ll
M llvm/test/Transforms/InstCombine/not-add.ll
Log Message:
-----------
[ConstExpr] Don't create div/rem expressions
This removes creation of udiv/sdiv/urem/srem constant expressions,
in preparation for their removal. I've added a
ConstantExpr::isDesirableBinOp() predicate to determine whether
an expression should be created for a certain operator.
With this patch, div/rem expressions can still be created through
explicit IR/bitcode, forbidding them entirely will be the next step.
Differential Revision: https://reviews.llvm.org/D128820
More information about the All-commits
mailing list