@@ -1823,6 +1823,10 @@ msgid ""
1823
1823
"Valur Jónsson in :issue:`16475`, with additional speedups by Antoine Pitrou "
1824
1824
"in :issue:`19219`.)"
1825
1825
msgstr ""
1826
+ "默认的 :mod:`marshal` 版本已被提升至 3。 新版本的代码实现恢复了 Python2 "
1827
+ "行为即只记录内联字符串的一份副本并在反序列化时保留内联状态,并将此“一份副本”功能扩展到任何对象类型(包括处理递归引用)。 这既减少了 ``.pyc``"
1828
+ " 文件的大小也减少了模块从 ``.pyc`` (或``.pyo``) 文件加载时占用的内存量。 (由 Kristján Valur Jónsson 在 "
1829
+ ":issue:`16475` 中贡献,并由 Antoine Pitrou 在 :issue:`19219` 中提供进一步的加速。)"
1826
1830
1827
1831
#: ../../whatsnew/3.4.rst:1114
1828
1832
msgid "mmap"
@@ -1850,6 +1854,13 @@ msgid ""
1850
1854
" the current start method, and :func:`~multiprocessing.set_start_method` "
1851
1855
"sets the start method. (Contributed by Richard Oudkerk in :issue:`8713`.)"
1852
1856
msgstr ""
1857
+ "在 Unix 上新增了两个 :ref:`启动方法 <multiprocessing-start-methods>` ``spawn`` 和 "
1858
+ "``forkserver`` 可使用 :mod:`multiprocessing` 来启动进程。 这两个方法使得进程和线程的混合更为健壮,并且 "
1859
+ "``spawn`` 方法可以匹配 multiprocessing 在 Windows 上一直使用的语法。 新增的函数 "
1860
+ ":func:`~multiprocessing.get_all_start_methods` "
1861
+ "可报告平台上可用的所有启动方法,:func:`~multiprocessing.get_start_method` 可报告当前的启动方法,而 "
1862
+ ":func:`~multiprocessing.set_start_method` 可设置启动方法。 (由 Richard Oudkerk 在 "
1863
+ ":issue:`8713` 中贡献。)"
1853
1864
1854
1865
#: ../../whatsnew/3.4.rst:1135
1855
1866
msgid ""
@@ -1863,6 +1874,12 @@ msgid ""
1863
1874
"use multiprocessing without interfering with each other. (Contributed by "
1864
1875
"Richard Oudkerk in :issue:`18999`.)"
1865
1876
msgstr ""
1877
+ "现在 :mod:`multiprocessing` 还具有 ``上下文`` 的概念,它决定了子进程的创建方式。 新增的函数 "
1878
+ ":func:`~multiprocessing.get_context` 可返回一个使用指定启动方法的上下文。 它具有与 "
1879
+ ":mod:`multiprocessing` 模块本身一致的 API,因此你可以使用它来创建 "
1880
+ ":class:`~multiprocessing.pool.Pool` 和其他在上下文中执行操作的对象。 "
1881
+ "这允许一个框架和某个应用程序或相同应用程序的不同部分使用多进程而不会彼此干扰。 (由 Richard Oudkerk 在 :issue:`18999` "
1882
+ "中贡献。)"
1866
1883
1867
1884
#: ../../whatsnew/3.4.rst:1145
1868
1885
msgid ""
0 commit comments