MCPcopy Create free account
hub / github.com/FastLED/FastLED / test_sub_sat_u8_16

Function test_sub_sat_u8_16

examples/AutoResearch/AutoResearchSimd.h:152–159  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

150}
151
152inline bool test_sub_sat_u8_16() {
153 uint8_t a[16] = {100,50,200,10, 100,50,200,10, 100,50,200,10, 100,50,200,10};
154 uint8_t b[16] = {50,100,50,100, 50,100,50,100, 50,100,50,100, 50,100,50,100};
155 uint8_t expected[16] = {50,0,150,0, 50,0,150,0, 50,0,150,0, 50,0,150,0};
156 uint8_t output[16] = {0};
157 store_u8_16(output, sub_sat_u8_16(load_u8_16(a), load_u8_16(b)));
158 return compare_u8(expected, output, 16);
159}
160
161inline bool test_sub_sat_u8_16_full_clamp() {
162 // 0 - 255 = 0 (clamped), 255 - 0 = 255, equal values = 0

Callers

nothing calls this directly

Calls 1

compare_u8Function · 0.85

Tested by

no test coverage detected