From: Giacomo Travaglini Date: Tue, 3 Mar 2020 13:26:12 +0000 (+0000) Subject: arch-x86: Fix imports for Python 3 compatibility X-Git-Tag: v20.0.0.0~339 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=663495f3b1bcd225470abce4d7f4131a5918fa2a;p=gem5.git arch-x86: Fix imports for Python 3 compatibility Change-Id: I7e486a6f3d38af54ac1eff431ca40a5af29e3ca7 Signed-off-by: Giacomo Travaglini Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/26256 Tested-by: kokoro Reviewed-by: Jason Lowe-Power Maintainer: Jason Lowe-Power --- diff --git a/src/arch/x86/isa/insts/__init__.py b/src/arch/x86/isa/insts/__init__.py index 4840e2366..918951c95 100644 --- a/src/arch/x86/isa/insts/__init__.py +++ b/src/arch/x86/isa/insts/__init__.py @@ -44,5 +44,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/__init__.py b/src/arch/x86/isa/insts/general_purpose/__init__.py index 9542dcac0..95d55a782 100644 --- a/src/arch/x86/isa/insts/general_purpose/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/__init__.py @@ -54,5 +54,5 @@ microcode = ''' # Microcode for general purpose instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/arithmetic/__init__.py b/src/arch/x86/isa/insts/general_purpose/arithmetic/__init__.py index cc016651d..27d3807a2 100644 --- a/src/arch/x86/isa/insts/general_purpose/arithmetic/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/arithmetic/__init__.py @@ -39,6 +39,6 @@ categories = ["add_and_subtract", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/compare_and_test/__init__.py b/src/arch/x86/isa/insts/general_purpose/compare_and_test/__init__.py index 385db5cb9..48cc1c2fb 100644 --- a/src/arch/x86/isa/insts/general_purpose/compare_and_test/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/compare_and_test/__init__.py @@ -42,5 +42,5 @@ categories = ["bit_scan", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/control_transfer/__init__.py b/src/arch/x86/isa/insts/general_purpose/control_transfer/__init__.py index 470f72dfa..38ca33628 100644 --- a/src/arch/x86/isa/insts/general_purpose/control_transfer/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/control_transfer/__init__.py @@ -42,5 +42,5 @@ categories = ["call", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/data_conversion/__init__.py b/src/arch/x86/isa/insts/general_purpose/data_conversion/__init__.py index 5495a62e4..d90e30242 100644 --- a/src/arch/x86/isa/insts/general_purpose/data_conversion/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/data_conversion/__init__.py @@ -42,5 +42,5 @@ categories = ["ascii_adjust", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/data_transfer/__init__.py b/src/arch/x86/isa/insts/general_purpose/data_transfer/__init__.py index 5c32f1997..1cdccec48 100644 --- a/src/arch/x86/isa/insts/general_purpose/data_transfer/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/data_transfer/__init__.py @@ -40,5 +40,5 @@ categories = ["conditional_move", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/flags/__init__.py b/src/arch/x86/isa/insts/general_purpose/flags/__init__.py index 68d922d66..673f167bd 100644 --- a/src/arch/x86/isa/insts/general_purpose/flags/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/flags/__init__.py @@ -39,5 +39,5 @@ categories = ["load_and_store", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/input_output/__init__.py b/src/arch/x86/isa/insts/general_purpose/input_output/__init__.py index 1f1c87822..a5c5a57df 100644 --- a/src/arch/x86/isa/insts/general_purpose/input_output/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/input_output/__init__.py @@ -38,5 +38,5 @@ categories = ["general_io", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/rotate_and_shift/__init__.py b/src/arch/x86/isa/insts/general_purpose/rotate_and_shift/__init__.py index e0f10e14c..b72512184 100644 --- a/src/arch/x86/isa/insts/general_purpose/rotate_and_shift/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/rotate_and_shift/__init__.py @@ -38,5 +38,5 @@ categories = ["rotate", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/general_purpose/string/__init__.py b/src/arch/x86/isa/insts/general_purpose/string/__init__.py index a30f362ae..2bf155270 100644 --- a/src/arch/x86/isa/insts/general_purpose/string/__init__.py +++ b/src/arch/x86/isa/insts/general_purpose/string/__init__.py @@ -41,5 +41,5 @@ categories = ["compare_strings", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/__init__.py b/src/arch/x86/isa/insts/simd128/__init__.py index 465305dd9..8a3fbafe7 100644 --- a/src/arch/x86/isa/insts/simd128/__init__.py +++ b/src/arch/x86/isa/insts/simd128/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # SSE instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/floating_point/__init__.py b/src/arch/x86/isa/insts/simd128/floating_point/__init__.py index cc2928e0a..bffb9b9af 100644 --- a/src/arch/x86/isa/insts/simd128/floating_point/__init__.py +++ b/src/arch/x86/isa/insts/simd128/floating_point/__init__.py @@ -44,5 +44,5 @@ microcode = ''' # SSE instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/floating_point/arithmetic/__init__.py b/src/arch/x86/isa/insts/simd128/floating_point/arithmetic/__init__.py index 13e72a96b..f3119f385 100644 --- a/src/arch/x86/isa/insts/simd128/floating_point/arithmetic/__init__.py +++ b/src/arch/x86/isa/insts/simd128/floating_point/arithmetic/__init__.py @@ -48,5 +48,5 @@ microcode = ''' # SSE instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/floating_point/compare/__init__.py b/src/arch/x86/isa/insts/simd128/floating_point/compare/__init__.py index 125053a3a..85b1c9fae 100644 --- a/src/arch/x86/isa/insts/simd128/floating_point/compare/__init__.py +++ b/src/arch/x86/isa/insts/simd128/floating_point/compare/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # SSE instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/floating_point/data_conversion/__init__.py b/src/arch/x86/isa/insts/simd128/floating_point/data_conversion/__init__.py index 211e2d85a..42afc9a7f 100644 --- a/src/arch/x86/isa/insts/simd128/floating_point/data_conversion/__init__.py +++ b/src/arch/x86/isa/insts/simd128/floating_point/data_conversion/__init__.py @@ -42,5 +42,5 @@ microcode = ''' # SSE instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/floating_point/data_reordering/__init__.py b/src/arch/x86/isa/insts/simd128/floating_point/data_reordering/__init__.py index 84c682ffb..78c6e941b 100644 --- a/src/arch/x86/isa/insts/simd128/floating_point/data_reordering/__init__.py +++ b/src/arch/x86/isa/insts/simd128/floating_point/data_reordering/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # SSE instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/floating_point/data_transfer/__init__.py b/src/arch/x86/isa/insts/simd128/floating_point/data_transfer/__init__.py index 8821996b5..b9845a9f7 100644 --- a/src/arch/x86/isa/insts/simd128/floating_point/data_transfer/__init__.py +++ b/src/arch/x86/isa/insts/simd128/floating_point/data_transfer/__init__.py @@ -42,5 +42,5 @@ microcode = ''' # SSE instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/floating_point/logical/__init__.py b/src/arch/x86/isa/insts/simd128/floating_point/logical/__init__.py index 409546776..6fc94c286 100644 --- a/src/arch/x86/isa/insts/simd128/floating_point/logical/__init__.py +++ b/src/arch/x86/isa/insts/simd128/floating_point/logical/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # SSE instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/__init__.py b/src/arch/x86/isa/insts/simd128/integer/__init__.py index cc463539f..ecf20086c 100644 --- a/src/arch/x86/isa/insts/simd128/integer/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/__init__.py @@ -46,5 +46,5 @@ microcode = ''' # 128 bit multimedia and scientific instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/arithmetic/__init__.py b/src/arch/x86/isa/insts/simd128/integer/arithmetic/__init__.py index fdc3fac57..8b4681180 100644 --- a/src/arch/x86/isa/insts/simd128/integer/arithmetic/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/arithmetic/__init__.py @@ -44,5 +44,5 @@ microcode = ''' # 128 bit multimedia and scientific instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/compare/__init__.py b/src/arch/x86/isa/insts/simd128/integer/compare/__init__.py index e6744e0b9..08c0e8632 100644 --- a/src/arch/x86/isa/insts/simd128/integer/compare/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/compare/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # 128 bit multimedia and scientific instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/data_conversion/__init__.py b/src/arch/x86/isa/insts/simd128/integer/data_conversion/__init__.py index c1d60fe02..8beaf881c 100644 --- a/src/arch/x86/isa/insts/simd128/integer/data_conversion/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/data_conversion/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # 128 bit multimedia and scientific conversion instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/data_reordering/__init__.py b/src/arch/x86/isa/insts/simd128/integer/data_reordering/__init__.py index cc74cd466..ceb6e45ba 100644 --- a/src/arch/x86/isa/insts/simd128/integer/data_reordering/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/data_reordering/__init__.py @@ -42,5 +42,5 @@ microcode = ''' # 128 bit multimedia and scientific instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/data_transfer/__init__.py b/src/arch/x86/isa/insts/simd128/integer/data_transfer/__init__.py index bdc9865d5..1231aa178 100644 --- a/src/arch/x86/isa/insts/simd128/integer/data_transfer/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/data_transfer/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # 128 bit multimedia and scientific data transfer instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/logical/__init__.py b/src/arch/x86/isa/insts/simd128/integer/logical/__init__.py index 941da2310..b1da9719a 100644 --- a/src/arch/x86/isa/insts/simd128/integer/logical/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/logical/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # 128 bit multimedia and scientific instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/save_and_restore_state/__init__.py b/src/arch/x86/isa/insts/simd128/integer/save_and_restore_state/__init__.py index f19105bcf..53d481907 100644 --- a/src/arch/x86/isa/insts/simd128/integer/save_and_restore_state/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/save_and_restore_state/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # 128 bit multimedia and scientific instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd128/integer/shift/__init__.py b/src/arch/x86/isa/insts/simd128/integer/shift/__init__.py index 3d7a166ef..a4a6d44f5 100644 --- a/src/arch/x86/isa/insts/simd128/integer/shift/__init__.py +++ b/src/arch/x86/isa/insts/simd128/integer/shift/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # 128 bit multimedia and scientific instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/__init__.py b/src/arch/x86/isa/insts/simd64/__init__.py index 587426211..461a2ff90 100644 --- a/src/arch/x86/isa/insts/simd64/__init__.py +++ b/src/arch/x86/isa/insts/simd64/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/floating_point/__init__.py b/src/arch/x86/isa/insts/simd64/floating_point/__init__.py index 182fccd16..dcdb8690d 100644 --- a/src/arch/x86/isa/insts/simd64/floating_point/__init__.py +++ b/src/arch/x86/isa/insts/simd64/floating_point/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/floating_point/arithmetic/__init__.py b/src/arch/x86/isa/insts/simd64/floating_point/arithmetic/__init__.py index 9ee34f68a..553946778 100644 --- a/src/arch/x86/isa/insts/simd64/floating_point/arithmetic/__init__.py +++ b/src/arch/x86/isa/insts/simd64/floating_point/arithmetic/__init__.py @@ -44,5 +44,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/floating_point/compare/__init__.py b/src/arch/x86/isa/insts/simd64/floating_point/compare/__init__.py index f67a43ba7..2f7365b34 100644 --- a/src/arch/x86/isa/insts/simd64/floating_point/compare/__init__.py +++ b/src/arch/x86/isa/insts/simd64/floating_point/compare/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/integer/__init__.py b/src/arch/x86/isa/insts/simd64/integer/__init__.py index 785802807..4c71d0dc6 100644 --- a/src/arch/x86/isa/insts/simd64/integer/__init__.py +++ b/src/arch/x86/isa/insts/simd64/integer/__init__.py @@ -47,5 +47,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/integer/arithmetic/__init__.py b/src/arch/x86/isa/insts/simd64/integer/arithmetic/__init__.py index 80aa11ed9..0e60ebad5 100644 --- a/src/arch/x86/isa/insts/simd64/integer/arithmetic/__init__.py +++ b/src/arch/x86/isa/insts/simd64/integer/arithmetic/__init__.py @@ -44,5 +44,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/integer/compare/__init__.py b/src/arch/x86/isa/insts/simd64/integer/compare/__init__.py index f67a43ba7..2f7365b34 100644 --- a/src/arch/x86/isa/insts/simd64/integer/compare/__init__.py +++ b/src/arch/x86/isa/insts/simd64/integer/compare/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/integer/data_reordering/__init__.py b/src/arch/x86/isa/insts/simd64/integer/data_reordering/__init__.py index 455433a5d..ce2a85918 100644 --- a/src/arch/x86/isa/insts/simd64/integer/data_reordering/__init__.py +++ b/src/arch/x86/isa/insts/simd64/integer/data_reordering/__init__.py @@ -42,5 +42,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/integer/data_transfer/__init__.py b/src/arch/x86/isa/insts/simd64/integer/data_transfer/__init__.py index b3cfc203b..5c12feb82 100644 --- a/src/arch/x86/isa/insts/simd64/integer/data_transfer/__init__.py +++ b/src/arch/x86/isa/insts/simd64/integer/data_transfer/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/integer/logical/__init__.py b/src/arch/x86/isa/insts/simd64/integer/logical/__init__.py index 1a7f20325..a77545ddb 100644 --- a/src/arch/x86/isa/insts/simd64/integer/logical/__init__.py +++ b/src/arch/x86/isa/insts/simd64/integer/logical/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/simd64/integer/shift/__init__.py b/src/arch/x86/isa/insts/simd64/integer/shift/__init__.py index 2aaca3989..bad162960 100644 --- a/src/arch/x86/isa/insts/simd64/integer/shift/__init__.py +++ b/src/arch/x86/isa/insts/simd64/integer/shift/__init__.py @@ -41,5 +41,5 @@ microcode = ''' # 64 bit multimedia instructions ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/system/__init__.py b/src/arch/x86/isa/insts/system/__init__.py index ec55081bd..af1f1992b 100644 --- a/src/arch/x86/isa/insts/system/__init__.py +++ b/src/arch/x86/isa/insts/system/__init__.py @@ -45,6 +45,6 @@ categories = ["control_registers", microcode = "" for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/x87/__init__.py b/src/arch/x86/isa/insts/x87/__init__.py index e745bd9f1..95fd3be19 100644 --- a/src/arch/x86/isa/insts/x87/__init__.py +++ b/src/arch/x86/isa/insts/x87/__init__.py @@ -46,5 +46,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/x87/arithmetic/__init__.py b/src/arch/x86/isa/insts/x87/arithmetic/__init__.py index 74000a708..62fca5e07 100644 --- a/src/arch/x86/isa/insts/x87/arithmetic/__init__.py +++ b/src/arch/x86/isa/insts/x87/arithmetic/__init__.py @@ -46,5 +46,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/x87/compare_and_test/__init__.py b/src/arch/x86/isa/insts/x87/compare_and_test/__init__.py index f640eaf7c..cdef0380b 100644 --- a/src/arch/x86/isa/insts/x87/compare_and_test/__init__.py +++ b/src/arch/x86/isa/insts/x87/compare_and_test/__init__.py @@ -43,5 +43,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/x87/control/__init__.py b/src/arch/x86/isa/insts/x87/control/__init__.py index ad45ecd91..01a1e68ba 100644 --- a/src/arch/x86/isa/insts/x87/control/__init__.py +++ b/src/arch/x86/isa/insts/x87/control/__init__.py @@ -44,5 +44,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/x87/data_transfer_and_conversion/__init__.py b/src/arch/x86/isa/insts/x87/data_transfer_and_conversion/__init__.py index 467b2d500..5f1d4cce4 100644 --- a/src/arch/x86/isa/insts/x87/data_transfer_and_conversion/__init__.py +++ b/src/arch/x86/isa/insts/x87/data_transfer_and_conversion/__init__.py @@ -44,5 +44,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/x87/load_constants/__init__.py b/src/arch/x86/isa/insts/x87/load_constants/__init__.py index 5c14524a1..bf57ce6b7 100644 --- a/src/arch/x86/isa/insts/x87/load_constants/__init__.py +++ b/src/arch/x86/isa/insts/x87/load_constants/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/x87/stack_management/__init__.py b/src/arch/x86/isa/insts/x87/stack_management/__init__.py index 3cf935a76..8135a9230 100644 --- a/src/arch/x86/isa/insts/x87/stack_management/__init__.py +++ b/src/arch/x86/isa/insts/x87/stack_management/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode diff --git a/src/arch/x86/isa/insts/x87/transcendental_functions/__init__.py b/src/arch/x86/isa/insts/x87/transcendental_functions/__init__.py index 86d0d9913..ac8dae256 100644 --- a/src/arch/x86/isa/insts/x87/transcendental_functions/__init__.py +++ b/src/arch/x86/isa/insts/x87/transcendental_functions/__init__.py @@ -40,5 +40,5 @@ microcode = ''' # X86 microcode ''' for category in categories: - exec("import %s as cat" % category) + exec("from . import %s as cat" % category) microcode += cat.microcode