[PATCH] D122081: Add DXILPrepare CodeGen pass
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Mar 19 14:08:52 PDT 2022
nikic added inline comments.
================
Comment at: llvm/lib/Target/DirectX/DXILPrepare.cpp:64
+ }
+#include "llvm/IR/Attributes.inc"
+ for (auto &BB : F) {
----------------
Do you really need Attributes.inc here? You should be able to loop over all attributes using Attribute::None and Attribute::EndAttrKind.
================
Comment at: llvm/lib/Target/DirectX/DXILPrepare.cpp:75
+ Value *In = I->getOperand(0);
+ Value *Zero = ConstantFP::get(In->getType(), 0.0);
+ I->replaceAllUsesWith(Builder.CreateFSub(Zero, In));
----------------
Shouldn't this be negative zero?
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D122081/new/
https://reviews.llvm.org/D122081
More information about the llvm-commits
mailing list