aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVinson Lee <[email protected]>2020-06-05 00:46:10 -0700
committerVinson Lee <[email protected]>2020-06-05 23:42:54 -0700
commitfaa339e666b4d0c4f88f2588cd84176e2b19ec0f (patch)
treeeb3ebfc24f987f5ea040594d401d0c8db9e11143
parenta61532e4dbdf4fbbf5822daeb5907efaf584a375 (diff)
Switch from cElementTree to ElementTree.
The xml.etree.cElementTree module will be removed in Python 3.9. Since Python 3.3 the xml.etree.cElementTree module has been deprecated, the xml.etree.ElementTree module uses a fast implementation whenever available. Builds using Python 2.7 can still work but with the slower implementation. Signed-off-by: Vinson Lee <[email protected]> Acked-by: Eric Engestrom <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5349>
-rw-r--r--src/amd/vulkan/radv_entrypoints_gen.py2
-rw-r--r--src/freedreno/vulkan/tu_entrypoints_gen.py2
-rwxr-xr-xsrc/intel/genxml/gen_sort_tags.py2
-rw-r--r--src/intel/genxml/gen_zipped_file.py2
-rw-r--r--src/intel/perf/gen_perf.py2
-rw-r--r--src/intel/vulkan/anv_entrypoints_gen.py2
-rw-r--r--src/mapi/new/genCommon.py2
-rwxr-xr-xsrc/mapi/new/gen_gldispatch_mapi.py2
-rw-r--r--src/vulkan/util/gen_enum_to_str.py2
-rw-r--r--src/vulkan/util/vk_extensions.py2
-rw-r--r--src/vulkan/util/vk_extensions_gen.py2
11 files changed, 11 insertions, 11 deletions
diff --git a/src/amd/vulkan/radv_entrypoints_gen.py b/src/amd/vulkan/radv_entrypoints_gen.py
index 8b03b823e6c..842f56d78af 100644
--- a/src/amd/vulkan/radv_entrypoints_gen.py
+++ b/src/amd/vulkan/radv_entrypoints_gen.py
@@ -26,7 +26,7 @@ import argparse
import functools
import math
import os
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
from collections import OrderedDict, namedtuple
from mako.template import Template
diff --git a/src/freedreno/vulkan/tu_entrypoints_gen.py b/src/freedreno/vulkan/tu_entrypoints_gen.py
index 263ef6f05f4..85e620b5729 100644
--- a/src/freedreno/vulkan/tu_entrypoints_gen.py
+++ b/src/freedreno/vulkan/tu_entrypoints_gen.py
@@ -27,7 +27,7 @@ import copy
import functools
import math
import os
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
from collections import OrderedDict, namedtuple
from mako.template import Template
diff --git a/src/intel/genxml/gen_sort_tags.py b/src/intel/genxml/gen_sort_tags.py
index 953c0fe55b8..f87bb2bfe6e 100755
--- a/src/intel/genxml/gen_sort_tags.py
+++ b/src/intel/genxml/gen_sort_tags.py
@@ -28,7 +28,7 @@ from collections import OrderedDict
import os
import pathlib
import re
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
def get_filename(element):
return element.attrib['filename']
diff --git a/src/intel/genxml/gen_zipped_file.py b/src/intel/genxml/gen_zipped_file.py
index 199f550419e..fd91f175b16 100644
--- a/src/intel/genxml/gen_zipped_file.py
+++ b/src/intel/genxml/gen_zipped_file.py
@@ -25,7 +25,7 @@
from __future__ import print_function
import sys
import zlib
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
def main():
if len(sys.argv) < 2:
diff --git a/src/intel/perf/gen_perf.py b/src/intel/perf/gen_perf.py
index dfe8e4dd25f..a5b47ea56e8 100644
--- a/src/intel/perf/gen_perf.py
+++ b/src/intel/perf/gen_perf.py
@@ -24,7 +24,7 @@ import os
import sys
import textwrap
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
hashed_funcs = {}
diff --git a/src/intel/vulkan/anv_entrypoints_gen.py b/src/intel/vulkan/anv_entrypoints_gen.py
index b524897a0f6..fc2ee097961 100644
--- a/src/intel/vulkan/anv_entrypoints_gen.py
+++ b/src/intel/vulkan/anv_entrypoints_gen.py
@@ -25,7 +25,7 @@
import argparse
import math
import os
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
from collections import OrderedDict, namedtuple
from mako.template import Template
diff --git a/src/mapi/new/genCommon.py b/src/mapi/new/genCommon.py
index bf71de14891..ec8e9e75019 100644
--- a/src/mapi/new/genCommon.py
+++ b/src/mapi/new/genCommon.py
@@ -28,7 +28,7 @@
import collections
import re
import sys
-import xml.etree.cElementTree as etree
+import xml.etree.ElementTree as etree
import os
GLAPI = os.path.join(os.path.dirname(__file__), "..", "glapi", "gen")
diff --git a/src/mapi/new/gen_gldispatch_mapi.py b/src/mapi/new/gen_gldispatch_mapi.py
index 86958de3007..85596792e13 100755
--- a/src/mapi/new/gen_gldispatch_mapi.py
+++ b/src/mapi/new/gen_gldispatch_mapi.py
@@ -33,7 +33,7 @@ Generates the glapi_mapi_tmp.h header file from Khronos's XML file.
"""
import sys
-import xml.etree.cElementTree as etree
+import xml.etree.ElementTree as etree
import genCommon
diff --git a/src/vulkan/util/gen_enum_to_str.py b/src/vulkan/util/gen_enum_to_str.py
index 035aa02a172..ebaf2a1a0cc 100644
--- a/src/vulkan/util/gen_enum_to_str.py
+++ b/src/vulkan/util/gen_enum_to_str.py
@@ -25,7 +25,7 @@ from __future__ import print_function
import argparse
import os
import textwrap
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
from mako.template import Template
diff --git a/src/vulkan/util/vk_extensions.py b/src/vulkan/util/vk_extensions.py
index 2f8b1a78462..d01a43fd850 100644
--- a/src/vulkan/util/vk_extensions.py
+++ b/src/vulkan/util/vk_extensions.py
@@ -1,7 +1,7 @@
import argparse
import copy
import re
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
def _bool_to_c_expr(b):
if b is True:
diff --git a/src/vulkan/util/vk_extensions_gen.py b/src/vulkan/util/vk_extensions_gen.py
index e340761a678..bbfb60b3d81 100644
--- a/src/vulkan/util/vk_extensions_gen.py
+++ b/src/vulkan/util/vk_extensions_gen.py
@@ -24,7 +24,7 @@ COPYRIGHT = """\
*/
"""
-import xml.etree.cElementTree as et
+import xml.etree.ElementTree as et
from mako.template import Template