[Python-Dev] How to keep Signaling NaN unchanged when convert hex to single-precision float ?

2021-04-26 Thread Huang, Yang
Hi, Code snippet 1 and 2 convert an hex to float, but the SNaN is changed to QNaN automatically. It follows IEEE 754 behavior. While Code snippet 3 converts an hex to double, and the SNaN keeps. Is there any solution to keep SNaN float unchanged in Code snippet 1 and 2? 1. >>> i = int('7f80

[Python-Dev] How to customize CPython to a minimal set

2020-07-20 Thread Huang, Yang
Hi, all There is a request to run python in a Linux-based embedded resource constrained system with sqlite3 support. So many features are not required, like posixmodule, signalmodule, hashtable ... But seems there are some dependencies among the Modules/Parser/Python/Objects/Programs... Is t

[Python-Dev] Re: How to customize CPython to a minimal set

2020-07-21 Thread Huang, Yang
10:45 PM To: Huang, Yang Cc: python-dev@python.org Subject: Re: [Python-Dev] How to customize CPython to a minimal set Have you considered starting with micropython? It’s made for embedded systems and fully supports Python 3 syntax. Adding sqlite3 support to it will be less work than stripping

[Python-Dev] Re: How to customize CPython to a minimal set

2020-07-22 Thread Huang, Yang
: Tuesday, July 21, 2020 10:57 PM To: Huang, Yang Cc: python-dev@python.org Subject: Re: [Python-Dev] How to customize CPython to a minimal set I expect it will be unfeasible to strip CPython. If you disagree, try it. ;-) On Mon, Jul 20, 2020 at 22:35 Huang, Yang mailto:yang.hu...@intel.com>>