search for: const0

Displaying 3 results from an estimated 3 matches for "const0".

Did you mean: const
2016 Sep 29
2
IR canonicalization: select or bool math?
My gut tells me that Hal is right, and we should prefer zexts as long as the select boils down to one instruction, but let me go against my intuition and try to list two reasons why we should prefer selects: * Folding operations into selects: it is trivial to transform f(select X, Const0, Const1) to select X, f(Const0), f(Const1), while doing that can be difficult for zexts. define i32 @sel_1_or_0(i1 %a) { %b = select i1 %a, i32 1, i32 0 %k = add i32 %b, 50 ret i32 %k } ==> define i32 @sel_1_or_0(i1 %a) { %b = select i1 %a, i32 51,...
2016 Sep 28
4
IR canonicalization: select or bool math?
I have another round of questions about IR select canonicalizations. For the purity of this quiz, please disregard prior knowledge of how this is handled by instcombine or how this is lowered by your favorite target...of course we'll fix it. :) Some answers in the links below if you do want to know. Which, if any, of these is canonical? 1. Is a zext simpler than a select? a. define i32
2012 Jul 16
3
[LLVMdev] RFC: LLVM incubation, or requirements for committing new backends
...stant memory. > + LOCAL_ADDRESS = 3, // Address space for local memory. > + REGION_ADDRESS = 4, // Address space for region memory. > + ADDRESS_NONE = 5, // Address space for unknown memory. > + PARAM_D_ADDRESS = 6, // Address space for direct addressible parameter memory (CONST0) > + PARAM_I_ADDRESS = 7, // Address space for indirect addressible parameter memory (VTX1) > + USER_SGPR_ADDRESS = 8, // Address space for USER_SGPRS on SI > + LAST_ADDRESS = 9 > +}; > + > +// This union/struct combination is an easy way to read out the > +// exact bit...