MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / TEST_F

Function TEST_F

dnn/test/fallback/gi.cpp:61–90  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

59}
60
61TEST_F(FALLBACK, GiGetSimdType) {
62 auto t = GiGetSimdType();
63 auto should_type = GI_UNKNOWN;
64#if defined(GI_AVX_INTRINSICS) || defined(GI_AVX2_INTRINSICS) || \
65 defined(GI_FMA_INTRINSICS)
66 should_type = GI_AVX;
67#elif defined(GI_NEON_INTRINSICS)
68 should_type = GI_NEON;
69#elif defined(GI_SSE2_INTRINSICS) || defined(GI_SSE42_INTRINSICS)
70
71#if defined(GI_SSE42_INTRINSICS)
72 should_type = GI_SSE42;
73#elif defined(GI_SSE2_INTRINSICS)
74 should_type = GI_SSE2;
75#else
76 should_type = GI_UNKNOWN;
77#error "code issue happened!!"
78#endif
79
80#elif defined(GI_RVV_INTRINSICS)
81 should_type = GI_RVV;
82
83#else
84 should_type = GI_NAIVE;
85#endif
86
87 printf("test GiGetSimdType: %d, should_type: %d\n", t, should_type);
88
89 ASSERT_EQ(t, should_type);
90}
91
92TEST_F(FALLBACK, GiReinterpretInt8AsInt32) {
93 GI_INT32_t ret;

Callers

nothing calls this directly

Calls 15

GiGetSimdTypeFunction · 0.85
force_memset_retFunction · 0.85
assert_eqFunction · 0.85
maxFunction · 0.85
GiBroadcastInt8Function · 0.85
GiSt1Float32Function · 0.85
GiStoreFloat32Function · 0.85
GiStoreFloat16Function · 0.85
GiStoreFloat32V2Function · 0.85
assert_ltFunction · 0.85
assert_eq_and_nanFunction · 0.85
GiReduceAddFloat32Function · 0.85

Tested by

no test coverage detected