forked from microsoft/onnxruntime
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathonnxruntime_framework.natvis
47 lines (45 loc) · 2.82 KB
/
onnxruntime_framework.natvis
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<?xml version="1.0" encoding="utf-8"?>
<AutoVisualizer xmlns="http://schemas.microsoft.com/vstudio/debugger/natvis/2010">
<Type Name="onnxruntime::MLFloat16">
<Intrinsic Name="_negative" Expression="(val & 0x8000) == 1"/>
<Intrinsic Name="_strip_sign" Expression="(val & ~0x8000)"/>
<Intrinsic Name="_is_nan" Expression="(_strip_sign() > 0x7C00)"/>
<Intrinsic Name="_is_finite" Expression="(_strip_sign() < 0x7C00)"/>
<Intrinsic Name="_is_normal" Expression="(_is_finite() && (val != 0)) && ((val & 0x7C00) != 0)"/>
<Intrinsic Name="_biased_exponent" Expression="(val >> 10) & (0x7C00 >> 10)"/>
<Intrinsic Name="_exponent" Expression="(int16_t)(_biased_exponent() - 15)"/>
<Intrinsic Name="_significand" Expression="(val & 0x03FF)"/>
<DisplayString>{{val={ val }}}</DisplayString>
<Expand>
<Item Name="[Negative]" ExcludeView="simple">_negative()</Item>
<Item Name="[IsNan]" ExcludeView="simple" Condition="_is_nan()">true</Item>
<Item Name="[IsFinite]" ExcludeView="simple">_is_finite()</Item>
<Item Name="[IsNormal]" ExcludeView="simple">_is_normal()</Item>
<Item Name="[uint16_t]" ExcludeView="simple">val</Item>
<Item Name="[Exponent]" ExcludeView="simple">_exponent()</Item>
<Item Name="[Biased Exponent]" ExcludeView="simple">_biased_exponent()</Item>
<Item Name="[Significand]" ExcludeView="simple">_significand()</Item>
</Expand>
</Type>
<Type Name="onnxruntime::BFloat16">
<Intrinsic Name="_negative" Expression="(val & 0x8000) == 1"/>
<Intrinsic Name="_strip_sign" Expression="(val & ~0x8000)"/>
<Intrinsic Name="_is_nan" Expression="(_strip_sign() > 0x7F80)"/>
<Intrinsic Name="_is_finite" Expression="(_strip_sign() < 0x7F80)"/>
<Intrinsic Name="_is_normal" Expression="(_is_finite() && (val != 0)) && ((val & 0x7F80) != 0)"/>
<Intrinsic Name="_biased_exponent" Expression="(val >> 7) & (0x7F80 >> 7)"/>
<Intrinsic Name="_exponent" Expression="(int16_t)(_biased_exponent() - 127)"/>
<Intrinsic Name="_significand" Expression="(val & 0x007F)"/>
<DisplayString>{{val={ val }}}</DisplayString>
<Expand>
<Item Name="[Negative]" ExcludeView="simple">_negative()</Item>
<Item Name="[IsNormal]" ExcludeView="simple">_is_normal()</Item>
<Item Name="[IsNan]" ExcludeView="simple" Condition="_is_nan()">true</Item>
<Item Name="[IsFinite]" ExcludeView="simple">_is_finite()</Item>
<Item Name="[uint16_t]" ExcludeView="simple">val</Item>
<Item Name="[Exponent]" ExcludeView="simple">_exponent()</Item>
<Item Name="[Biased Exponent]" ExcludeView="simple">_biased_exponent()</Item>
<Item Name="[Significand]" ExcludeView="simple">_significand()</Item>
</Expand>
</Type>
</AutoVisualizer>