Page MenuHomePhabricator

Please use GitHub pull requests for new patches. Phabricator shutdown timeline

orex (Kirill Okhotnikov)
User

Projects

User does not belong to any projects.

User Details

User Since
Jun 4 2022, 3:39 AM (68 w, 4 d)

Recent Activity

Nov 4 2022

orex added inline comments to D137453: [libc] Add add_with_carry to builtin wrapper..
Nov 4 2022, 1:28 PM · Restricted Project, Restricted Project
orex accepted D137453: [libc] Add add_with_carry to builtin wrapper..

Another question to you is how the functions will work with implicit conversion. What I would do is to force input be the same with is_same of enable_if, if they are available.

Nov 4 2022, 12:11 PM · Restricted Project, Restricted Project

Oct 28 2022

orex added inline comments to D136799: [libc] Implement a high-precision floating point class..
Oct 28 2022, 12:38 AM · Restricted Project, Restricted Project

Oct 27 2022

orex added inline comments to D136799: [libc] Implement a high-precision floating point class..
Oct 27 2022, 11:08 AM · Restricted Project, Restricted Project

Sep 17 2022

orex accepted D134104: [libc][math] Implement exp10f function correctly rounded to all rounding modes..
Sep 17 2022, 9:18 AM · Restricted Project, Restricted Project

Sep 16 2022

orex accepted D134002: [libc][math] Improve tanhf performance..
Sep 16 2022, 4:30 AM · Restricted Project, Restricted Project

Sep 15 2022

orex accepted D133913: [libc][math] Improve sinhf and coshf performance..
Sep 15 2022, 1:42 AM · Restricted Project, Restricted Project

Sep 14 2022

orex accepted D133870: [libc][math] Improve exp2f performance..
Sep 14 2022, 11:22 AM · Restricted Project, Restricted Project

Sep 9 2022

orex accepted D133550: [libc][math] Implement acosf function correctly rounded for all rounding modes..
Sep 9 2022, 1:49 AM · Restricted Project, Restricted Project

Sep 7 2022

orex accepted D133400: [libc][math] Implement asinf function correctly rounded for all rounding modes..

Good job, Tue!

I have an optional suggestion. You can use formula
asin(x)=1/2*acos(1-2*x^2)
and, of course,
acos(x)=pi/2-asin(x)
for cases where |x|>=0.5 Probably it can be much faster than sqrt.

Thanks @orex for the suggestion! Unfortunately the formula asin(x) = pi/4 - 1/2 * asin(1 - 2*x^2) only works
well when |1 - 2*x^2| <= 0.5, i.e. 0.5 <= |x| <= sqrt(3)/2.

For sqrt(3)/2 < |x| <= 1, we still need some sort of range reduction involving square root.

Nonetheless, I've tried adding another branch for 0.5 <= |x| <= sqrt(3)/2 using the formula
asin(x) = pi/4 - 1/2 * asin(1 - 2*x^2) and it actually makes both the throughput and the latency
slightly worse than 2 branches.

Sep 7 2022, 12:25 PM · Restricted Project, Restricted Project
orex added a comment to D133400: [libc][math] Implement asinf function correctly rounded for all rounding modes..

Good job, Tue!

Sep 7 2022, 4:03 AM · Restricted Project, Restricted Project

Aug 30 2022

orex committed rG8c9d685fa80e: [libc][math] Fix broken atan function. (authored by orex).
[libc][math] Fix broken atan function.
Aug 30 2022, 2:04 PM · Restricted Project, Restricted Project
orex committed rG6c75240da0d9: [libc][math] Fix broken tests. (authored by orex).
[libc][math] Fix broken tests.
Aug 30 2022, 2:00 PM · Restricted Project, Restricted Project
orex committed rG77e1d9beedec: [libc][math] Added atanf function. (authored by orex).
[libc][math] Added atanf function.
Aug 30 2022, 1:41 PM · Restricted Project, Restricted Project
orex committed rG6c1fc7e43033: [libc][math] Added atanhf function. (authored by orex).
[libc][math] Added atanhf function.
Aug 30 2022, 1:41 PM · Restricted Project, Restricted Project
orex committed rG89ed5b7c50cd: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf. (authored by orex).
[libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf.
Aug 30 2022, 1:41 PM · Restricted Project, Restricted Project
orex closed D132842: [libc][math] Added atanf function..
Aug 30 2022, 1:40 PM · Restricted Project, Restricted Project
orex closed D132811: [libc][math] Added atanhf function..
Aug 30 2022, 1:40 PM · Restricted Project, Restricted Project
orex closed D132809: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf..
Aug 30 2022, 1:40 PM · Restricted Project, Restricted Project
orex updated the diff for D132842: [libc][math] Added atanf function..

Review fixes.

Aug 30 2022, 12:31 PM · Restricted Project, Restricted Project
orex updated the diff for D132811: [libc][math] Added atanhf function..

Review fixes.

Aug 30 2022, 12:29 PM · Restricted Project, Restricted Project
orex added a comment to D132809: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf..

The aux functions are split into two files according @lntue suggestion.

Aug 30 2022, 12:27 PM · Restricted Project, Restricted Project
orex updated the diff for D132809: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf..

Review fixes.

Aug 30 2022, 12:26 PM · Restricted Project, Restricted Project

Aug 29 2022

orex updated the diff for D132811: [libc][math] Added atanhf function..

Fixed entrypoint.

Aug 29 2022, 2:26 PM · Restricted Project, Restricted Project
orex updated the diff for D132811: [libc][math] Added atanhf function..

Fixed comments.

Aug 29 2022, 2:24 PM · Restricted Project, Restricted Project
orex added inline comments to D132809: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf..
Aug 29 2022, 2:18 PM · Restricted Project, Restricted Project
orex updated the diff for D132809: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf..

Fix wrong upload.

Aug 29 2022, 2:17 PM · Restricted Project, Restricted Project
orex updated the diff for D132809: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf..

Constants description added.

Aug 29 2022, 2:13 PM · Restricted Project, Restricted Project
orex updated the summary of D132842: [libc][math] Added atanf function..
Aug 29 2022, 3:37 AM · Restricted Project, Restricted Project
orex requested review of D132842: [libc][math] Added atanf function..
Aug 29 2022, 3:36 AM · Restricted Project, Restricted Project
orex added a comment to D132811: [libc][math] Added atanhf function..

Thank you, Paul! I'll land the revision after Tue review.

Aug 29 2022, 2:22 AM · Restricted Project, Restricted Project

Aug 28 2022

orex requested review of D132811: [libc][math] Added atanhf function..
Aug 28 2022, 11:06 AM · Restricted Project, Restricted Project
orex requested review of D132809: [libc][math] Added auxiliary function log2_eval for asinhf/acoshf/atanhf..
Aug 28 2022, 10:14 AM · Restricted Project, Restricted Project
orex added inline comments to D132638: [NFC][libc] Move Uint implementation to parent directory.
Aug 28 2022, 7:01 AM · Restricted Project, Restricted Project

Aug 12 2022

orex accepted D131715: [libc] Implement tanf function correctly rounded for all rounding modes..
Aug 12 2022, 1:39 AM · Restricted Project, Restricted Project

Aug 11 2022

orex accepted D131652: [libc] Change sinf/cosf range reduction to mod pi/32 to be shared with tanf..
Aug 11 2022, 1:39 AM · Restricted Project, Restricted Project

Aug 4 2022

orex accepted D131196: [libc] Add subtraction for UInt<N> class..
Aug 4 2022, 3:57 PM · Restricted Project, Restricted Project
orex added a comment to D131095: [libc] Prevent overflow from intermediate results when adding UInt<N> values..

Did you consider using builtins with overflow checking:
https://gcc.gnu.org/onlinedocs/gcc/Integer-Overflow-Builtins.html
It is platform independent and leaves some optimisations opportunities to the compiler.

Aug 4 2022, 7:52 AM · Restricted Project, Restricted Project
orex added inline comments to D131095: [libc] Prevent overflow from intermediate results when adding UInt<N> values..
Aug 4 2022, 7:37 AM · Restricted Project, Restricted Project
orex added inline comments to D131095: [libc] Prevent overflow from intermediate results when adding UInt<N> values..
Aug 4 2022, 1:14 AM · Restricted Project, Restricted Project

Aug 3 2022

orex accepted D131095: [libc] Prevent overflow from intermediate results when adding UInt<N> values..
Aug 3 2022, 2:51 PM · Restricted Project, Restricted Project

Aug 1 2022

orex accepted D130901: [libc] Implement sincosf function correctly rounded to all rounding modes..
Aug 1 2022, 3:45 PM · Restricted Project, Restricted Project
orex committed rG2a558b6bff5a: [libc][math] Build fail fix: obsolete header. (authored by orex).
[libc][math] Build fail fix: obsolete header.
Aug 1 2022, 1:55 PM · Restricted Project, Restricted Project
orex committed rG5ef987c9852c: [libc][math] Added tanhf function. (authored by orex).
[libc][math] Added tanhf function.
Aug 1 2022, 1:43 PM · Restricted Project, Restricted Project
orex closed D130780: [libc][math] Added tanhf function..
Aug 1 2022, 1:43 PM · Restricted Project, Restricted Project

Jul 29 2022

orex added a comment to D127951: [libc][math] New algorithm for expf/expm1f/exp2f and for new functions sinhf/coshf..

Paul (@zimmermann6) and Tue (@lntue),

Jul 29 2022, 9:00 AM · Restricted Project, Restricted Project
orex added a reviewer for D127951: [libc][math] New algorithm for expf/expm1f/exp2f and for new functions sinhf/coshf.: zimmermann6.
Jul 29 2022, 8:56 AM · Restricted Project, Restricted Project
orex updated the diff for D127951: [libc][math] New algorithm for expf/expm1f/exp2f and for new functions sinhf/coshf..

Rebased to latest main.

Jul 29 2022, 8:51 AM · Restricted Project, Restricted Project
orex committed rGa7f55f08051f: [libc][math] Added sinhf function. (authored by orex).
[libc][math] Added sinhf function.
Jul 29 2022, 8:24 AM · Restricted Project, Restricted Project
orex closed D129278: [libc][math] Added sinhf function..
Jul 29 2022, 8:24 AM · Restricted Project, Restricted Project
orex committed rGfcb9d7e2cf17: [libc][math] Added coshf function. (authored by orex).
[libc][math] Added coshf function.
Jul 29 2022, 7:57 AM · Restricted Project, Restricted Project
orex closed D129275: [libc][math] Added coshf function..
Jul 29 2022, 7:57 AM · Restricted Project, Restricted Project
orex requested review of D130780: [libc][math] Added tanhf function..
Jul 29 2022, 7:51 AM · Restricted Project, Restricted Project
orex added a comment to D129275: [libc][math] Added coshf function..

Thank you Paul for sharing the results.
The results I got using the same compiler (llvm 11) as Paul (@zimmermann6):

CORE_MATH_PERF_MODE=rdtsc PERF_ARGS='' ./perf.sh coshf
GNU libc version: 2.31
GNU libc release: stable
18.534
13.019
17.590
CORE_MATH_PERF_MODE=rdtsc PERF_ARGS='--latency' ./perf.sh coshf
GNU libc version: 2.31
GNU libc release: stable
49.670
38.334
50.461

As you can see llvm 12 significantly improve throughput of this version of coshf over version 11. Partially this problem can be explained by this difference. Another source of the difference is Intel vs AMD. We observe such difference with (@lntue).
Paul, can you confirm, that the precision is OK? I think that we can push the changes even though the solution is not the fastest for all platforms/compilers? Tue?

Jul 29 2022, 3:42 AM · Restricted Project, Restricted Project

Jul 28 2022

orex updated the diff for D129278: [libc][math] Added sinhf function..

Review fixes.

Jul 28 2022, 6:48 AM · Restricted Project, Restricted Project
orex updated the diff for D129275: [libc][math] Added coshf function..

Review fixes.

Jul 28 2022, 6:38 AM · Restricted Project, Restricted Project
orex added inline comments to D129278: [libc][math] Added sinhf function..
Jul 28 2022, 6:09 AM · Restricted Project, Restricted Project
orex updated the diff for D129278: [libc][math] Added sinhf function..

Review fixes. More verbose comments.

Jul 28 2022, 6:08 AM · Restricted Project, Restricted Project
orex updated the diff for D129275: [libc][math] Added coshf function..

Review fixes.

Jul 28 2022, 4:57 AM · Restricted Project, Restricted Project
orex updated the summary of D129278: [libc][math] Added sinhf function..
Jul 28 2022, 4:00 AM · Restricted Project, Restricted Project
orex updated the summary of D129275: [libc][math] Added coshf function..
Jul 28 2022, 3:56 AM · Restricted Project, Restricted Project
orex updated the diff for D129278: [libc][math] Added sinhf function..

Rebasing on main with small fixes.

Jul 28 2022, 3:50 AM · Restricted Project, Restricted Project
orex updated the diff for D129275: [libc][math] Added coshf function..

Rebasing on main with small fixes.

Jul 28 2022, 3:49 AM · Restricted Project, Restricted Project
orex committed rG4b41e7b43691: [libc][math] Universal exp function for cosh/sinh calculation. (authored by orex).
[libc][math] Universal exp function for cosh/sinh calculation.
Jul 28 2022, 2:25 AM · Restricted Project, Restricted Project
orex closed D129215: [libc][math] Universal exp function for cosh/sinh calculation..
Jul 28 2022, 2:24 AM · Restricted Project, Restricted Project
orex committed rGc78144e1c74b: [libc][math] Improved performance of exp2f function. (authored by orex).
[libc][math] Improved performance of exp2f function.
Jul 28 2022, 1:58 AM · Restricted Project, Restricted Project
orex closed D129005: [libc][math] Improved performance of exp2f function..
Jul 28 2022, 1:58 AM · Restricted Project, Restricted Project
orex updated the diff for D129005: [libc][math] Improved performance of exp2f function..

Merged to last main, some cosmetic changes.

Jul 28 2022, 1:21 AM · Restricted Project, Restricted Project

Jul 27 2022

orex accepted D130644: [libc] Implement cosf function that is correctly rounded to all rounding modes..
Jul 27 2022, 1:03 PM · Restricted Project, Restricted Project
orex updated subscribers of D129215: [libc][math] Universal exp function for cosh/sinh calculation..
Jul 27 2022, 12:53 PM · Restricted Project, Restricted Project
orex updated the diff for D129215: [libc][math] Universal exp function for cosh/sinh calculation..

Small fixes in test.

Jul 27 2022, 12:53 PM · Restricted Project, Restricted Project
orex updated the summary of D129215: [libc][math] Universal exp function for cosh/sinh calculation..
Jul 27 2022, 12:30 PM · Restricted Project, Restricted Project
orex updated the summary of D129215: [libc][math] Universal exp function for cosh/sinh calculation..
Jul 27 2022, 12:29 PM · Restricted Project, Restricted Project
orex added inline comments to D129215: [libc][math] Universal exp function for cosh/sinh calculation..
Jul 27 2022, 12:28 PM · Restricted Project, Restricted Project
orex updated the diff for D129215: [libc][math] Universal exp function for cosh/sinh calculation..

Small fixes.

Jul 27 2022, 12:27 PM · Restricted Project, Restricted Project
orex added a comment to D129005: [libc][math] Improved performance of exp2f function..

OK. Thanks! let's wait.

Jul 27 2022, 12:07 PM · Restricted Project, Restricted Project
orex updated the diff for D129005: [libc][math] Improved performance of exp2f function..

Added explicit dependencies.

Jul 27 2022, 12:06 PM · Restricted Project, Restricted Project
orex added inline comments to D130629: [libc] Change sinf range reduction to mod pi/16 to be shared with cosf..
Jul 27 2022, 11:03 AM · Restricted Project, Restricted Project
orex added inline comments to D130629: [libc] Change sinf range reduction to mod pi/16 to be shared with cosf..
Jul 27 2022, 10:26 AM · Restricted Project, Restricted Project
orex added inline comments to D130629: [libc] Change sinf range reduction to mod pi/16 to be shared with cosf..
Jul 27 2022, 9:29 AM · Restricted Project, Restricted Project
orex added inline comments to D130629: [libc] Change sinf range reduction to mod pi/16 to be shared with cosf..
Jul 27 2022, 8:38 AM · Restricted Project, Restricted Project
orex updated the summary of D129005: [libc][math] Improved performance of exp2f function..
Jul 27 2022, 8:31 AM · Restricted Project, Restricted Project
orex updated the diff for D129005: [libc][math] Improved performance of exp2f function..

Improved performance by fputil::nearest_integer function.

Jul 27 2022, 8:29 AM · Restricted Project, Restricted Project

Jul 12 2022

orex added a comment to D129278: [libc][math] Added sinhf function..

The easiest way, from my point of view, will be to apply it on top of working coshf branch, which you made and test.

Jul 12 2022, 6:46 AM · Restricted Project, Restricted Project
orex added a comment to D129275: [libc][math] Added coshf function..

Can you try to put all the chain on top of the revision 60d6be5dd3f411cfe1b5392cbb... for now. I'll rebase the revisions to the last main tonight.

Jul 12 2022, 5:52 AM · Restricted Project, Restricted Project
orex added a comment to D129275: [libc][math] Added coshf function..

Yes. You should first apply D129005, after D129215 and after that one. The initial revision were cut to several ones to improve review process and new function deployment.

Jul 12 2022, 4:58 AM · Restricted Project, Restricted Project

Jul 7 2022

orex requested review of D129278: [libc][math] Added sinhf function..
Jul 7 2022, 4:49 AM · Restricted Project, Restricted Project
orex requested review of D129275: [libc][math] Added coshf function..
Jul 7 2022, 4:14 AM · Restricted Project, Restricted Project

Jul 6 2022

orex requested review of D129215: [libc][math] Universal exp function for cosh/sinh calculation..
Jul 6 2022, 9:15 AM · Restricted Project, Restricted Project

Jul 1 2022

orex requested review of D129005: [libc][math] Improved performance of exp2f function..
Jul 1 2022, 10:04 AM · Restricted Project, Restricted Project
orex committed rGfdf1fda5a8c8: [libc][math] Improved ExhaustiveTest performance. (authored by orex).
[libc][math] Improved ExhaustiveTest performance.
Jul 1 2022, 9:33 AM · Restricted Project, Restricted Project
orex closed D128995: [libc][math] Improved ExhaustiveTest performance..
Jul 1 2022, 9:33 AM · Restricted Project, Restricted Project
orex added inline comments to D128995: [libc][math] Improved ExhaustiveTest performance..
Jul 1 2022, 9:23 AM · Restricted Project, Restricted Project
orex updated the diff for D128995: [libc][math] Improved ExhaustiveTest performance..

Fix some reviewer comments.

Jul 1 2022, 9:06 AM · Restricted Project, Restricted Project
orex added inline comments to D128995: [libc][math] Improved ExhaustiveTest performance..
Jul 1 2022, 8:23 AM · Restricted Project, Restricted Project
orex requested review of D128995: [libc][math] Improved ExhaustiveTest performance..
Jul 1 2022, 7:44 AM · Restricted Project, Restricted Project

Jun 30 2022

orex updated the diff for D127951: [libc][math] New algorithm for expf/expm1f/exp2f and for new functions sinhf/coshf..

Fix build problem.

Jun 30 2022, 1:39 AM · Restricted Project, Restricted Project

Jun 29 2022

orex retitled D127951: [libc][math] New algorithm for expf/expm1f/exp2f and for new functions sinhf/coshf. from [libc][math] New common algorithm for expf/expm1f/exp2f. to [libc][math] New algorithm for expf/expm1f/exp2f and for new functions sinhf/coshf..
Jun 29 2022, 10:00 AM · Restricted Project, Restricted Project
orex updated the diff for D127951: [libc][math] New algorithm for expf/expm1f/exp2f and for new functions sinhf/coshf..

Added sinhf/coshf

Jun 29 2022, 8:34 AM · Restricted Project, Restricted Project

Jun 27 2022

orex committed rG535845708949: [libc][docs] Added fmod performance results. (authored by orex).
[libc][docs] Added fmod performance results.
Jun 27 2022, 10:32 AM · Restricted Project, Restricted Project