reference, declaration → definition definition → references, declarations, derived classes, virtual overrides reference to multiple definitions → definitions unreferenced |
143 EXPECT_EQ(126u, s128.countLeadingZeros()); 144 EXPECT_EQ(0u, s128.countLeadingOnes()); 145 EXPECT_EQ(2u, s128.getActiveBits()); 146 EXPECT_EQ(1u, s128.countTrailingZeros()); 147 EXPECT_EQ(0u, s128.countTrailingOnes()); 148 EXPECT_EQ(1u, s128.countPopulation()); 149 EXPECT_EQ(2, s128.getSExtValue()); 150 EXPECT_EQ(2u, s128.getZExtValue()); 153 s128.setBits(42, 42); 154 EXPECT_EQ(126u, s128.countLeadingZeros()); 155 EXPECT_EQ(0u, s128.countLeadingOnes()); 156 EXPECT_EQ(2u, s128.getActiveBits()); 157 EXPECT_EQ(1u, s128.countTrailingZeros()); 158 EXPECT_EQ(0u, s128.countTrailingOnes()); 159 EXPECT_EQ(1u, s128.countPopulation()); 160 EXPECT_EQ(2, s128.getSExtValue()); 161 EXPECT_EQ(2u, s128.getZExtValue()); 163 s128.setBits(3, 32); 164 EXPECT_EQ(96u, s128.countLeadingZeros()); 165 EXPECT_EQ(0u, s128.countLeadingOnes()); 166 EXPECT_EQ(32u, s128.getActiveBits()); 167 EXPECT_EQ(33u, s128.getMinSignedBits()); 168 EXPECT_EQ(1u, s128.countTrailingZeros()); 169 EXPECT_EQ(0u, s128.countTrailingOnes()); 170 EXPECT_EQ(30u, s128.countPopulation()); 171 EXPECT_EQ(static_cast<uint32_t>((~0u << 3) | 2), s128.getZExtValue()); 173 s128.setBits(62, 128); 174 EXPECT_EQ(0u, s128.countLeadingZeros()); 175 EXPECT_EQ(66u, s128.countLeadingOnes()); 176 EXPECT_EQ(128u, s128.getActiveBits()); 177 EXPECT_EQ(63u, s128.getMinSignedBits()); 178 EXPECT_EQ(1u, s128.countTrailingZeros()); 179 EXPECT_EQ(0u, s128.countTrailingOnes()); 180 EXPECT_EQ(96u, s128.countPopulation()); 183 s128.getSExtValue());