-
## +24
## A New Dragon in the Den: Fast Conversion From Floating-Point Numbers
## CASSIO NERI
## 2024 September 15 - 20
WARNING:
This PDF poorly reproduces the slides shown at the talk.
You are strongly beast.
It's not rocket science.
## A New Dragon in the Den
## Fast conversion from floating-point numbers
## Cassio Neri (Independent Researcher)
CppCon 2024 - Aurora
# Statistical mechanics of Decimal fixed-point representation
## 1234
## Decimal floating-point representation
## exponent
### 10 ¹ x 2.34 mantissa
## Decimal floating-point representation
exponent
### 10 ¹ x 2.34 mantissa
0
0 码力 |
171 页 |
6.42 MB
| 1 年前 3
-
## +24
## Cross-Platform Floating-Point Determinism Out of the Box
## SHERRY IGNATCHENKO ET AL
## Authors

## All the 0c9de70c3d925/p2_4.jpg)
Guy Davidson
gd@6it.dev
Advising on C++ standard with regards to floating-point, idea about intrinsics, reviews

Mykhailo Borovyk
mbo@6it.dev
Implementing fixed-point math with floating-point fallback

Vladyslav
0 码力 |
31 页 |
3.88 MB
| 1 年前 3
-
assignment versus mutation
4.3 Stylistic Conventions
5 Integers and Floating-Point Numbers
5.1 Integers
5.2 Floating-Point Numbers
5.3 Arbitrary Precision Arithmetic
5.4 Numeric Literal Coefficients Precedence and Associativity
6.8 Numerical Conversions
7 Complex and Rational Numbers
7.1 Complex Numbers
7.2 Rational Numbers
8 Strings
8.1 Characters
8.2 String Basics
8.3 Unicode and UTF-8 53 467
35.24 Tweaks ..... 467
35.25 Performance Annotations ..... 468
35.26 Treat Subnormal Numbers as Zeros ..... 471
35.27 @code_warntype ..... 472
35.28 Performance of captured variable ...
0 码力 |
2007 页 |
6.73 MB
| 11 月前 3
-
both be mapped to 0 in the quantized domain.
Keeping all that in mind, it is easy to see that floating-point $ x_{min} $ should map to 0, and $ x_{max} $ should map to $ 2^{b}-1 $ . How do we map the precision domain.
Visually inspecting figure 2-4, can you work out the formula for mapping a given floating-point value (x) to a quantized value ( $ x_{q} $ ). Assume that you are given values of $ x_{min} [Image](/uploads/documents/5/f/8/a/5f8af6d4905642e38ad2d0bbe54cd375/p6_1.jpg)
Figure 2-4: Quantizing floating-point continuous values to discrete unsigned values. The continuous values range from $ x_{min} $
0 码力 |
33 页 |
1.96 MB
| 2 年前 3
-
Conventions 9
4 Integers and Floating-Point Numbers 11
4.1 Integers 12
Overflow behavior 14
Division errors 15
4.2 Floating-Point Numbers 15
Floating-point zero 16
Special floating-point values 17
Machine epsilon and hyperbolic functions 35
Special functions 35
6 Complex and Rational Numbers 37
6.1 Complex Numbers 37
6.2 Rational Numbers 40
7 Strings 43
7.1 Characters 44
7.2 String Basics 45
7.3 Unicode and UTF-8 Configuration 1167
80.6 References 1169
REPL 1169
TerminalMenus 1169
81 Random Numbers 1175
81.1 Random numbers module 1175
81.2 Random generation functions 1175
81.3 Subsequences, permutations and
0 码力 |
1381 页 |
4.71 MB
| 1 天前 3
-
Conventions 9
4 Integers and Floating-Point Numbers 11
4.1 Integers 12
Overflow behavior 14
Division errors 15
4.2 Floating-Point Numbers 15
Floating-point zero 16
Special floating-point values 17
Machine epsilon and hyperbolic functions 35
Special functions 35
6 Complex and Rational Numbers 37
6.1 Complex Numbers 37
6.2 Rational Numbers 40
7 Strings 43
7.1 Characters 44
7.2 String Basics 45
7.3 Unicode and UTF-8 CONTENTS
Throwing Julia Exceptions . . . . .
34.22 Performance Annotations 384
34.23 Treat Subnormal Numbers as Zeros 387
34.24 @code_warntype 388
34.25 Performance of captured variable 390
34.26 Checking for
0 码力 |
1385 页 |
4.72 MB
| 1 天前 3
-
Allowed Variable Names 7
3.2 Stylistic Conventions 8
4 Integers and Floating-Point Numbers 9
4.1 Integers 10
4.2 Floating-Point Numbers 13
4.3 Arbitrary Precision Arithmetic 18
4.4 Numeric Literal Coefficients and Associativity 28
5.8 Numerical Conversions 30
6 Complex and Rational Numbers 33
6.1 Complex Numbers 33
6.2 Rational Numbers 36
7 Strings 39
7.1 Characters 40
7.2 String Basics 41
7.3 Unicode and UTF-8 deprecation warnings 378
34.22 Tweaks 378
34.23 Performance Annotations 379
34.24 Treat Subnormal Numbers as Zeros 381
34.25 @code_warntype 383
34.26 Performance of captured variable 384
CONTENTS
35 Workflow
0 码力 |
1370 页 |
4.88 MB
| 1 天前 3
-
assignment versus mutation 16
4.3 Stylistic Conventions 17
5 Integers and Floating-Point Numbers 18
5.1 Integers 19
5.2 Floating-Point Numbers 23
5.3 Arbitrary Precision Arithmetic 28
5.4 Numeric Literal Coefficients and Associativity 40
6.8 Numerical Conversions 41
7 Complex and Rational Numbers 45
7.1 Complex Numbers 45
7.2 Rational Numbers 48
8 Strings 52
8.1 Characters 53
CONTENTS
8.2 String Basics 55
8.3 Unicode 1717
90.6 Numbered prompt 1718
90.7 TerminalMenus 1719
90.8 References 1722
91 Random Numbers 1729
91.1 Random numbers module 1730
91.2 Random generation functions 1730
CONTENTS
91.3 Subsequences, permutations
0 码力 |
2065 页 |
7.46 MB
| 2 月前 3
-
td>
R | VPNE | rd,rs1,rs2 | | | Two Optional Floating-Point Instruction Extensions: RVF & RVD |
| Category | Name | Fmt | RV32(F/D) body>
RISC-V calling convention and five optional extensions: 8 RV32M; 11 RV32A; 34 floating-point instructions each for 32- and 64-bit data (RV32F, RV32D); and 53 RV32V. Using regex notation D. RV32 $ \{F|D\} $ adds registers f0-f31, whose width matches the widest precision, and a floating-point control and status register fcsr. RV32V adds vector registers v0-v31, vector predicate registers 0 码力 |
232 页 |
5.16 MB
| 2 年前 3 -
versus mutation 12
4.3 Stylistic Conventions 14
## 5 Integers and Floating-Point Numbers 15
5.1 Integers 16
5.2 Floating-Point Numbers 20
5.3 Arbitrary Precision Arithmetic 25
5.4 Numeric Literal Coefficients Associativity 37
6.8 Numerical Conversions 38
## 7 Complex and Rational Numbers 42
7.1 Complex Numbers 42
7.2 Rational Numbers 45
## 8 Strings 49
8.1 Characters 50
8.2 String Basics 52
## CONTENTS deprecation warnings 466
35.24 Tweaks 466
35.25 Performance Annotations 467
35.26 Treat Subnormal Numbers as Zeros 470
35.27 @code_warntype 471
35.28 Performance of captured variable 473
35.29 Multithreading 0 码力 |
1985 页 |
6.67 MB
| 1 年前 3
|