A New Dragon in the Den: Fast Conversion From Floating-Point Numbers
It's not a seven-headed beast. It's not rocket science.Cassio Neri Fast conversion from floating-point numbers CppCon 2024 - Aurora (Independent Researcher)MeMe O Neri's equationMe O Neri's equation fixed-point representation 23. 410 x 23. 4 1 Decimal floating-point representation (a) mantissa biased exponent10 x 23. 4 1 Decimal floating-point representation (a) mantissa 0 0 0 0 0 0 2 3 4 0 0 biased exponent10 x 23. 4 1 Decimal floating-point representation (a) mantissa 0 0 0 0 0 0 2 3 4 0 0 0 . , , , biased exponent10 x 23. 4 1 Decimal floating-point representation (a) exponent 0 mantissa's0 码力 | 171 页 | 6.42 MB | 5 月前3Cross-Platform Floating-Point Determinism Out of the Box
refactoring, reviews Dmytro Ivanchykhin 🇺🇦 di@6it.dev Implementing fixed- point math with floating-point fallback Mykhailo Borovyk 🇺🇦 mbo@6it.dev Implementing support for RISC-V, including Algorithm Correctness_/30 8 ❌ On Algorithm Correctness_/30 9 ❌ Mathematically 1 Fixed-Point 2 Floating-Point 3 ✅ ✅ ❌ There are algorithms, which are: Can be usually made solid - but only within compiler flags 4 Making 3rd-party libs deterministic is a MAJOR effortP3375: Reproducible floating-point results Spearheaded by Guy Davidson 1 Our C++ Standard/WG21 Proposal_ Proposed: std::strict_float0 码力 | 31 页 | 3.88 MB | 5 月前3The RISC-V Reader: An Open Architecture AtlasFirst Edition, 1.0.0 - 2021
Function args 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 and FADD.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 11, RVF 6, RVD 6, and RVV 0. AMOMINU.D rd,rs1,rs2 AMOMAXU.D rd,rs1,rs2 Two Optional Floating-Point Instruction Extensions: RVF & RVD +RV64{F|D} Calling Convention REMUW rd,rs1,rs20 码力 | 232 页 | 5.16 MB | 1 年前3The Swift Programming Language
fruitSummary = "I have \(apples + oranges) pieces of fruit." E X P E R I M E N T Use \() to include a floating-point calculation in a string and to include someone’s name in a greeting. Create arrays and dictionaries "Square": [1, 4, 9, 16, 25], 5 ] 6 var largest = 0 7 for (kind, numbers) in interestingNumbers { 8 for number in numbers { 9 if number > largest { 10 largest = number 11 number of arguments, collecting them into an array. 1 func sumOf(numbers: Int...) -> Int { 2 var sum = 0 3 for number in numbers { 4 sum += number 5 } 6 return sum 7 } 8 sumOf()0 码力 | 525 页 | 4.68 MB | 1 年前3Julia v1.6.6 Documentation
8 4 Integers and Floating-Point Numbers 9 4.1 Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 4.2 Floating-Point Numbers . . . . . . . . . . . . 29 6 Complex and Rational Numbers 33 6.1 Complex Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 6.2 Rational Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373 34.23Treat Subnormal Numbers as Zeros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376 34.24@code_warntype0 码力 | 1324 页 | 4.54 MB | 1 年前3Julia 1.6.5 Documentation
8 4 Integers and Floating-Point Numbers 9 4.1 Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 4.2 Floating-Point Numbers . . . . . . . . . . . . 29 6 Complex and Rational Numbers 33 6.1 Complex Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 6.2 Rational Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373 34.23Treat Subnormal Numbers as Zeros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376 34.24@code_warntype0 码力 | 1325 页 | 4.54 MB | 1 年前3Julia 1.6.7 Documentation
8 4 Integers and Floating-Point Numbers 9 4.1 Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 4.2 Floating-Point Numbers . . . . . . . . . . . . 29 6 Complex and Rational Numbers 33 6.1 Complex Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 6.2 Rational Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373 34.23Treat Subnormal Numbers as Zeros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376 34.24@code_warntype0 码力 | 1324 页 | 4.54 MB | 1 年前3Julia 1.6.4 Documentation
8 4 Integers and Floating-Point Numbers 9 4.1 Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 4.2 Floating-Point Numbers . . . . . . . . . . . . 29 6 Complex and Rational Numbers 33 6.1 Complex Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 6.2 Rational Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373 34.23Treat Subnormal Numbers as Zeros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376 34.24@code_warntype0 码力 | 1324 页 | 4.54 MB | 1 年前3Julia 1.6.2 Documentation
8 4 Integers and Floating-Point Numbers 9 4.1 Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 4.2 Floating-Point Numbers . . . . . . . . . . . . 29 6 Complex and Rational Numbers 33 6.1 Complex Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 6.2 Rational Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373 34.23Treat Subnormal Numbers as Zeros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376 34.24@code_warntype0 码力 | 1324 页 | 4.54 MB | 1 年前3Julia 1.6.3 Documentation
8 4 Integers and Floating-Point Numbers 9 4.1 Integers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 4.2 Floating-Point Numbers . . . . . . . . . . . . 29 6 Complex and Rational Numbers 33 6.1 Complex Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 6.2 Rational Numbers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373 34.23Treat Subnormal Numbers as Zeros . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376 34.24@code_warntype0 码力 | 1325 页 | 4.54 MB | 1 年前3
共 1000 条
- 1
- 2
- 3
- 4
- 5
- 6
- 100